RFR: 8326715: ZGC: RunThese24H fails with ExitCode 139 during shutdown [v3]

Markus Grönlund mgronlun at openjdk.org
Tue Jun 11 15:27:52 UTC 2024


> Objects with static storage duration will implicitly add their destructors to the std::atexit callbacks list. During process shutdown, the C routine __ run_exit_handlers() invokes the destructors on the std::atexit callback list.
> 
> The RefCountHandle has static storage and a destructor that decrements a reference counted pointer and, if necessary, deletes the pointee's contents. In this case, this pointee includes yet another embedded RefCountHandle.
> 
> When the destructor is invoked, it causes a cascade of handles to be destroyed, so many that it causes a stack overflow. The list contains about 87000 entries. These reference-counted pointees are blobs saving metadata-related information about class unloading.
> 
> The DeprecationManager subsystem lacks a filtering mechanism, similar to the ObjectSampler subsystem, to decide what to save concerning class unloading blobs.
> 
> One solution is to consolidate the preservation of type set blobs for both the DeprecatedManager and the ObjectSampler subsystems. Additionally, filtering will prevent the storage of redundant data. This, coupled with more frequent scavenging of the list, will effectively avert a stack overflow.
> 
> Testing: jdk_jfr, stress testing
> 
> Thanks
> Markus

Markus Grönlund has updated the pull request incrementally with one additional commit since the last revision:

  rename JfrTypeSetBlobManager to JfrReferenceCountedStorage

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/19510/files
  - new: https://git.openjdk.org/jdk/pull/19510/files/0bc00484..bd0051b2

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=19510&range=02
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=19510&range=01-02

  Stats: 307 lines in 8 files changed: 151 ins; 151 del; 5 mod
  Patch: https://git.openjdk.org/jdk/pull/19510.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/19510/head:pull/19510

PR: https://git.openjdk.org/jdk/pull/19510


More information about the hotspot-jfr-dev mailing list