RFR: 8231659: [JVMCI] Could not work PrintAssembly for JVMCI installed code
Tom Rodriguez
tom.rodriguez at oracle.com
Fri Oct 4 19:23:57 UTC 2019
Yasumasa Suenaga wrote on 10/1/19 1:57 AM:
> Hi all,
>
> Please review this change.
>
> JBS: https://bugs.openjdk.java.net/browse/JDK-8231659
> webrev: https://cr.openjdk.java.net/~ysuenaga/JDK-8231659/webrev.00/
>
> PrintAssembly would work in twice for JVMCI installed code before, so I
> fixed it in JDK-8180601.
> However PrintAseembly would not work for them in JDK 13 or later. It
> seems due to JDK-8220623.
>
> JDK-8220623 lacks print_nmethod() call. Thus I revert JDK-8180601 to
> work PrintAssembly.
I'd noticed this but forgot to go back and investigate. I think it
would be nicer to make that code look like the code that was
accidentally removed from JVMCIEnv.cpp:
diff -r 647e896479ff src/hotspot/share/jvmci/jvmciCodeInstaller.cpp
--- a/src/hotspot/share/jvmci/jvmciCodeInstaller.cpp
+++ b/src/hotspot/share/jvmci/jvmciCodeInstaller.cpp
@@ -642,11 +642,9 @@
failed_speculations,
speculations, speculations_len);
cb = nm->as_codeblob_or_null();
if (nm != NULL && compile_state == NULL) {
+ // This compile didn't come through the CompileBroker so perform
the printing here
DirectiveSet* directive =
DirectivesStack::getMatchingDirective(method, compiler);
- bool printnmethods = directive->PrintAssemblyOption ||
directive->PrintNMethodsOption;
- if (!printnmethods && (PrintDebugInfo || PrintRelocations ||
PrintDependencies || PrintExceptionHandlers)) {
- nm->print_nmethod(printnmethods);
- }
+ nm->maybe_print_nmethod(directive);
DirectivesStack::release(directive);
}
}
No point in duplicating that logic.
tom
More information about the hotspot-compiler-dev
mailing list