RFR: 8271121: ZGC: stack overflow (segv) when -Xlog:gc+start=debug
Per Liden
pliden at openjdk.java.net
Wed Aug 4 09:28:41 UTC 2021
When an allocation stall happens we're trying to access oops (the thread and thread name) while logging. We shouldn't do that since it can lead to a recursive allocation stall situation, which eventually will cause a stack overflow. I suggest we simply don't log anything in ZStatCriticalPhase::register_start(). The useful part of the logging happens in ZStatCriticalPhase::register_end() anyway, where it's safe to access oops.
-------------
Commit messages:
- 8271121: ZGC: stack overflow (segv) when -Xlog:gc+start=debug
Changes: https://git.openjdk.java.net/jdk/pull/4990/files
Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=4990&range=00
Issue: https://bugs.openjdk.java.net/browse/JDK-8271121
Stats: 4 lines in 1 file changed: 2 ins; 0 del; 2 mod
Patch: https://git.openjdk.java.net/jdk/pull/4990.diff
Fetch: git fetch https://git.openjdk.java.net/jdk pull/4990/head:pull/4990
PR: https://git.openjdk.java.net/jdk/pull/4990
More information about the hotspot-gc-dev
mailing list