RFR: 8267186: Add string deduplication support to ZGC [v4]

Per Liden pliden at openjdk.java.net
Wed Aug 11 08:26:56 UTC 2021


> This change adds support for string deduplication to ZGC. It's a pretty straight forward change, but to make reviewing even easier it is broken up into two commits:
> 
> __ZGC: Introduce ZMarkContext__
> This commit just moves the `ZMarkCache` into the new `ZMarkContext` class, and we now pass a `ZMarkContext*` around instead of a `ZMarkCache*`. The `ZMarkContext` class is a more general container for worker-local data, which in the next commit will be extended to also include the `StringDedup::Requests` queue.
> 
> __8267186: Add string deduplication support to ZGC__
> This commits adds the actual string dedup functionality and enables relevant tests. We use the `deduplication_requested` bit in the `String` object to filter out `Strings` we've already attempted to deduplicate.
> 
> Testing:
> - Passes all string dedup tests.
> - Passes Tier1-7 with ZGC on Linux/x86_64 (with -XX:+UseStringDeduplication enabled by default to get better exposure).

Per Liden has updated the pull request incrementally with one additional commit since the last revision:

  Review comments from StefanK

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

Changes:
  - all: https://git.openjdk.java.net/jdk/pull/5029/files
  - new: https://git.openjdk.java.net/jdk/pull/5029/files/c164f2c9..ea61a000

Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=jdk&pr=5029&range=03
 - incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=5029&range=02-03

  Stats: 60 lines in 3 files changed: 28 ins; 27 del; 5 mod
  Patch: https://git.openjdk.java.net/jdk/pull/5029.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/5029/head:pull/5029

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



More information about the hotspot-gc-dev mailing list