Skip to content

Commit 44f5dfe

Browse files
author
Boris Ulasevich
committed
8358183: [JVMCI] crash accessing nmethod::jvmci_name in CodeCache::aggregate
Reviewed-by: thartmann Backport-of: 74822ce12acaf9816aa49b75ab5817ced3710776
1 parent 9adc480 commit 44f5dfe

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

src/hotspot/share/code/codeBlob.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,8 @@ void CodeBlob::purge() {
210210
if (_mutable_data != blob_end()) {
211211
os::free(_mutable_data);
212212
_mutable_data = blob_end(); // Valid not null address
213+
_mutable_data_size = 0;
214+
_relocation_size = 0;
213215
}
214216
if (_oop_maps != nullptr) {
215217
delete _oop_maps;

src/hotspot/share/code/nmethod.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2166,6 +2166,7 @@ void nmethod::purge(bool unregister_nmethod) {
21662166
}
21672167
CodeCache::unregister_old_nmethod(this);
21682168

2169+
JVMCI_ONLY( _metadata_size = 0; )
21692170
CodeBlob::purge();
21702171
}
21712172

0 commit comments

Comments
 (0)