mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-21 03:24:38 +02:00
8009539: JVM crash when run lambda testng tests
Ensure class pointer is non-null before dereferencing it to check if it is loaded. Reviewed-by: kvn
This commit is contained in:
parent
6c55facb77
commit
6132db352d
1 changed files with 3 additions and 1 deletions
|
@ -104,7 +104,8 @@ Node* Parse::array_addressing(BasicType type, int vals, const Type* *result2) {
|
||||||
if (C->log() != NULL) C->log()->elem("observe that='!need_range_check'");
|
if (C->log() != NULL) C->log()->elem("observe that='!need_range_check'");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!arytype->klass()->is_loaded()) {
|
ciKlass * arytype_klass = arytype->klass();
|
||||||
|
if ((arytype_klass != NULL) && (!arytype_klass->is_loaded())) {
|
||||||
// Only fails for some -Xcomp runs
|
// Only fails for some -Xcomp runs
|
||||||
// The class is unloaded. We have to run this bytecode in the interpreter.
|
// The class is unloaded. We have to run this bytecode in the interpreter.
|
||||||
uncommon_trap(Deoptimization::Reason_unloaded,
|
uncommon_trap(Deoptimization::Reason_unloaded,
|
||||||
|
@ -1385,6 +1386,7 @@ void Parse::do_one_bytecode() {
|
||||||
if (TraceOptoParse) {
|
if (TraceOptoParse) {
|
||||||
tty->print(" @");
|
tty->print(" @");
|
||||||
dump_bci(bci());
|
dump_bci(bci());
|
||||||
|
tty->cr();
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue