RFR: JDK-8330565 - C2: Multiple crashes with CTW after JDK-8316991 [v2]
Cesar Soares Lucas
cslucas at openjdk.org
Mon May 6 22:19:26 UTC 2024
> Please consider this patch for fixing issues described in JDK-8330565 with a little overlap with issue JDK-8330795.
>
> The `# assert(false) failed: Bad graph detected in build_loop_late` failure was caused because a string concatenation optimization using [this method](https://github.com/openjdk/jdk/blob/819f3d6fc70ff6fe54ac5f9033c17c3dd4326aa5/src/hotspot/share/opto/graphKit.cpp#L4115) adds AddP and LoadN nodes to IR graph as NotNull _and_ because RAM was not "nullyfing" phis merging nullable pointers. I was only able to reproduce this problem using a classfile/jar compiled using an "old" version of JDK.. because newer version use InvokeDynamic to do string concatenation.
>
> The `assert((uint)type <= T_CONFLICT && _zero_type[type] != nullptr) failed: bad type` failure was caused by the fact that we didn't have a "zero value" for the type T_METADATA. The RAM patch uses that data when it creates a Phi node merging Klass loads and UseCompressedClassPointers is disabled.
>
>
>
>
> Tested with JTREG tier1-4 on Linux x86_64 & ARM64.
Cesar Soares Lucas has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains seven additional commits since the last revision:
- Updating branch
Merge branch 'fix_bad_bad_graph' of https://github.com/JohnTortugo/jdk into fix_bad_bad_graph
- Fix bad type when UseCompressedPointers is disabled.
- Phi merging nullable inputs needs to be nullable.
- SR allocate needs to be of exact type.
- Fix bad type when UseCompressedPointers is disabled.
- Phi merging nullable inputs needs to be nullable.
- SR allocate needs to be of exact type.
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/19111/files
- new: https://git.openjdk.org/jdk/pull/19111/files/31829d60..c8ce1502
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=19111&range=01
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=19111&range=00-01
Stats: 48711 lines in 1737 files changed: 22525 ins; 21107 del; 5079 mod
Patch: https://git.openjdk.org/jdk/pull/19111.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/19111/head:pull/19111
PR: https://git.openjdk.org/jdk/pull/19111
More information about the hotspot-compiler-dev
mailing list