8254723: add diagnostic command to write Linux perf map file

Reviewed-by: ysuenaga, sspitsyn
This commit is contained in:
Nick Gasson 2020-11-03 01:37:57 +00:00
parent f97ec359ec
commit 50357d136a
8 changed files with 170 additions and 2 deletions

View file

@ -4635,6 +4635,12 @@ jint os::init_2(void) {
set_coredump_filter(FILE_BACKED_SHARED_BIT);
}
if (DumpPerfMapAtExit && FLAG_IS_DEFAULT(UseCodeCacheFlushing)) {
// Disable code cache flushing to ensure the map file written at
// exit contains all nmethods generated during execution.
FLAG_SET_DEFAULT(UseCodeCacheFlushing, false);
}
return JNI_OK;
}