[code-reflection] RFR: Exception regions fix [v7]

Adam Sotona asotona at openjdk.org
Fri Feb 2 08:33:13 UTC 2024


On Fri, 2 Feb 2024 08:10:32 GMT, Adam Sotona <asotona at openjdk.org> wrote:

>> BytecodeGenerator::computeExceptionRegionMembership now collects all necessary info into BitSets and directly declares the regions with CodeBuilder.
>> All tests are now passing.
>> 
>> Please review.
>> 
>> Thanks,
>> Adam
>
> Adam Sotona has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Apply suggestions from code review
>   
>   Co-authored-by: Paul Sandoz <paul.d.sandoz at googlemail.com>

Unfortunately I found some problematic cases of unwinding conditional branches in BranchCompactor.
@PaulSandoz you are right, this kind of compaction should be done in the ClassFile API, more specifically in the CodeBuilder::ifThen and CodeBuilder::ifThenElse.

I'll rollback BranchCompactor to its simple and safe version skipping only unconditional branches to immediately following targets.

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

PR Comment: https://git.openjdk.org/babylon/pull/12#issuecomment-1923318807


More information about the babylon-dev mailing list