[jdk17] RFR: 8269641: assert(tmp == _callprojs.fallthrough_catchproj) failed: allocation control projection
Vladimir Kozlov
kvn at openjdk.java.net
Thu Jul 1 16:44:00 UTC 2021
On Thu, 1 Jul 2021 11:04:59 GMT, Nils Eliasson <neliasso at openjdk.org> wrote:
> When I investigated this bug I found out it was already fixed by JDK-8268405, or at least - it didn't happen any more. Since I had a good reproducer I took a look at why it happened and found two issues.
>
> The noteable thing about the test case is that there are still allocations that isn't used. The initalizeNode lead to HaltNodes. This looks like a temporary state while the graph is simplified.
>
> 1) In macro.cpp - process_users_of_allocation - there was an assert that was wrong. We must assert before the replace_node - otherwise tmp will always be NULL and fail. Why this hasn't happened before is a mystery.
>
> 2) memnode.cpp - MemBarNode::remove - returns without doing anything if there are not exactly 2 outs. In this case there is a InitalizeNode that leads to a HaltNode. The memory uses has been removed - so the memory projection from the InitalizeNode is already removed.
>
> If you want to check if this patch fixes the issue - you need to sync to jdk-17+26 - or before the fix for JDK-8268405.
>
> Please review,
> Nils Eliasson
I suggest to create new **open** bug and close current as dup.
I also don't get why your change in macro.cpp fixed the issue. `fallthrough_catchproj` is local cached value - it should not be updated with call to `replace_node()`.
Can you tell more what happened here?
-------------
Changes requested by kvn (Reviewer).
PR: https://git.openjdk.java.net/jdk17/pull/193
More information about the hotspot-compiler-dev
mailing list