RFR: 8333334: C2: Make result of `Node::dominates` more precise to enhance scalar replacement [v3]

MaxXing duke at openjdk.org
Fri Jun 14 10:21:17 UTC 2024


On Fri, 14 Jun 2024 09:57:44 GMT, Tobias Hartmann <thartmann at openjdk.org> wrote:

> Great! Please have a look at the failure that I reported above.

I noticed that the IR test log shows there is only one Allocate node in IR, while I can not reproduce this with my JDK clone, even after rebasing to the latest commit and using the same VM options.

The IR test that I added asserts there are two allocations after boxing inlining, one for `Iter`, one for the `Integer` inside it. But in the IR dump, there's only one `Iter` allocation left, and all the LoadN/LoadI nodes of `Integer` come out from that allocation. I don't know which optimization performs this.

Am I missing something? Sorry for not familiar with the IR testing framework, maybe providing an option to match allocations at exact locations would help to build this test.

I'm still trying to get the test to work. BTW, could you observe the performance improvement in `ConcurrentHashMap` iteration after applying this patch to your JDK?

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

PR Comment: https://git.openjdk.org/jdk/pull/19496#issuecomment-2167715783


More information about the hotspot-compiler-dev mailing list