RFR: 8274910: Compile in G1 evacuation failure injection code based on define

Thomas Schatzl tschatzl at openjdk.java.net
Thu Oct 7 17:05:22 UTC 2021


Hi all,

  can I have reviews for this change that simplifies performance work with evacuation failure handling a little? In particular, it adds a define called `EVAC_FAILURE_INJECTOR` (on by default in non-product builds) that allows to compile in/out the relevant injector code also in product mode (if manually enabled).

Actually, this PR suggests two variants for this: one that also automatically enables flags when `EVAC_FAILURE_INJECTOR` is selected (beaa6c3), and one that requires the developer also change the options from develop/notproduct to product to be available (9f07ffd).

The first is maybe makes the change a bit too hacky in `g1_globals.hpp` (unless there are ways to do that better, i.e. I could move the `GC_G1_EVACUATION_FAILURE_FLAGS` somewhere, or there is a much better preprocessor trick here, so I would like to have you decide.

Testing: gha, manual checking that in product mode by default no evacuation failure handling is in, but with the flag, and otherwise the same as before, tier1-5

Thanks,
  Thomas

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

Commit messages:
 - Automatically enable flags
 - some additional comments
 - First version, a bit underwhelming

Changes: https://git.openjdk.java.net/jdk/pull/5851/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=5851&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8274910
  Stats: 118 lines in 6 files changed: 73 ins; 29 del; 16 mod
  Patch: https://git.openjdk.java.net/jdk/pull/5851.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/5851/head:pull/5851

PR: https://git.openjdk.java.net/jdk/pull/5851



More information about the hotspot-gc-dev mailing list