However, for Truffle, upcalls are unavoidable if Truffle partial evaluation occurs as part of JIT compilation inlining. This occurs when the inliner produces/sees a constant Truffle AST which allows a Truffle-specific inlining extension to perform Truffle partial evaluation on the constant. Such PE involves upcalls to the Truffle runtime (running in Java).
What's needed is an escape hatch such that Truffle specific logic can put a compiler thread into "allow Java upcall" mode during the scope of the Truffle logic.
- relates to
-
JDK-8318694 [JVMCI] disable can_call_java in most contexts for libjvmci compiler threads
-
- Closed
-
- links to
-
Commit(master) openjdk/jdk/751a914b
-
Review(master) openjdk/jdk/21171
-
Review(master) openjdk/jdk/21285