mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 22:34:27 +02:00
8226690: SIGSEGV in MetadataOnStackClosure::do_metadata
Dont create nmethod if classes have been redefined since compilation start. Reviewed-by: sspitsyn, dlong, eosterlund, gdub
This commit is contained in:
parent
848614a01c
commit
6e1aa9065c
9 changed files with 43 additions and 7 deletions
|
@ -2192,6 +2192,17 @@ public:
|
|||
virtual void do_oop(narrowOop* p) { ShouldNotReachHere(); }
|
||||
};
|
||||
|
||||
class VerifyMetadataClosure: public MetadataClosure {
|
||||
public:
|
||||
void do_metadata(Metadata* md) {
|
||||
if (md->is_method()) {
|
||||
Method* method = (Method*)md;
|
||||
assert(!method->is_old(), "Should not be installing old methods");
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
void nmethod::verify() {
|
||||
|
||||
// Hmm. OSR methods can be deopted but not marked as zombie or not_entrant
|
||||
|
@ -2255,6 +2266,10 @@ void nmethod::verify() {
|
|||
Universe::heap()->verify_nmethod(this);
|
||||
|
||||
verify_scopes();
|
||||
|
||||
CompiledICLocker nm_verify(this);
|
||||
VerifyMetadataClosure vmc;
|
||||
metadata_do(&vmc);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue