RFR: 8301136: Improve unlink() and unlink_all() of ResourceHashtableBase [v3]
Xin Liu
xliu at openjdk.org
Fri Jan 27 07:02:30 UTC 2023
> 1. Apply the same idea of JDK-8300184 to unlink().
> 2. Because ResourceHashtableBase doesn't support copy constructor and copy assignment, client of it has to purge all elements first. We would like provide a specialized version called 'unlink_all()'.
> We don't need to update each node's _next in this case. We only nullify all buckets. We also use unlink_all() in destructor. Despite this isn't the optimal code for a destructor, we reduce maintenance cost.
Xin Liu has updated the pull request incrementally with one additional commit since the last revision:
Add a template for unlink(), unlink_all() and dtor.
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/12213/files
- new: https://git.openjdk.org/jdk/pull/12213/files/749ee745..2fa173c4
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=12213&range=02
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=12213&range=01-02
Stats: 82 lines in 1 file changed: 38 ins; 32 del; 12 mod
Patch: https://git.openjdk.org/jdk/pull/12213.diff
Fetch: git fetch https://git.openjdk.org/jdk pull/12213/head:pull/12213
PR: https://git.openjdk.org/jdk/pull/12213
More information about the hotspot-dev
mailing list