RFR: 8020282: Generated code quality: redundant LEAs in the chained dereferences [v4]

Manuel Hässig mhaessig at openjdk.org
Tue Jun 17 11:15:49 UTC 2025


On Fri, 13 Jun 2025 09:38:17 GMT, Roberto Castañeda Lozano <rcastanedalo at openjdk.org> wrote:

>>> Is this scenario exercised by any of the new tests? If not, would it be possible to construct an additional test where we verify that the peephole is not applied in this case?
>> 
>> It is not. I was only able to find such a case once with all VM intrinsics disabled some time ago, but was not able to reproduce one since. I'll have another try to find one.
>
>> > Is this scenario exercised by any of the new tests? If not, would it be possible to construct an additional test where we verify that the peephole is not applied in this case?
>> 
>> It is not. I was only able to find such a case once with all VM intrinsics disabled some time ago, but was not able to reproduce one since. I'll have another try to find one.
> 
> OK, that would be great! If you do not find one, I think the PR is still OK because it is easy to see how the peephole would handle the scenario. But it would be of course better to confirm it with an actual test case.

@robcasloz, I integrated all your suggestions and simplified the IR-tests. But I was unfortunately not able to create a test that reliably safepoints.

I kicked off testing again:
 - [ ] [Github Actions](https://github.com/mhaessig/jdk/actions/runs/15705629166)
 - [ ] tier1 - tier5 on x64

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

PR Comment: https://git.openjdk.org/jdk/pull/25471#issuecomment-2979945850


More information about the hotspot-compiler-dev mailing list