[code-reflection] RFR: BytecodeGenerator, BytecodeLift and TestBytecode improvements

Paul Sandoz psandoz at openjdk.org
Wed Mar 27 16:47:38 UTC 2024


On Fri, 22 Mar 2024 14:06:43 GMT, Adam Sotona <asotona at openjdk.org> wrote:

> BytecodeGenerator, BytecodeLift and TestBytecode improvements

Marked as reviewed by psandoz (Lead).

I am guessing you will circle back at some point with regards to code models in pure SSA (where some liveness analysis will be needed to scope out locals and reuse of). The lifting code got simpler, i can now understand it more easily :-) (i don't know if that was helped by not generating bytecode from code models in pure SSA.)

Overall this looks good, and a great approach to shaking out the problems given the complexity. I suspect it may be a short hop to support accessible instance methods for top-level classes.

On the `Interpreter` changes, i presume it is because when lifting we don't currently attempt to un-erase values and variables. Perhaps this is an additional transformation once we lift? For now I think it better to place that conversion in the test code, which IIUC would associated only with `TestBytecode::testLift`?

Relatedly i am curious about your thoughts on #40, since there is some connection between that and your testing approach.

-------------

PR Review: https://git.openjdk.org/babylon/pull/44#pullrequestreview-1963904722
PR Comment: https://git.openjdk.org/babylon/pull/44#issuecomment-2023260504
PR Comment: https://git.openjdk.org/babylon/pull/44#issuecomment-2023269928


More information about the babylon-dev mailing list