RFR: 8305959: x86: Improve itable_stub [v4]
Boris Ulasevich
bulasevich at openjdk.org
Fri Jun 2 09:40:14 UTC 2023
> Async profiler shows that applications spend up to 10% in itable_stubs.
>
> The current inefficiency of itable stubs is as follows. The generated itable_stub scans itable twice: first it checks if the object class is a subtype of the resolved_class, and then it finds the holder_class that implements the method. I suggest doing this in one pass: with a first loop over itable, check pointer equality to both holder_class and resolved_class. Once we have finished searching for resolved_class, continue searching for holder_class in a separate loop if it has not yet been found.
>
> This approach gives 1-10% improvement on the synthetic benchmarks and 3% improvement on Naive Bayes benchmark from the Renaissance Benchmark Suite (Intel Xeon X5675).
Boris Ulasevich has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains five additional commits since the last revision:
- Merge branch 'openjdk:master' into improve_itable_stub
- Apply suggestions from code review
Co-authored-by: Aleksey Shipilëv <shipilev at amazon.de>
- readability rework
- cleanup
- 8305959: x86: Improve itable_stub
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/13460/files
- new: https://git.openjdk.org/jdk/pull/13460/files/0ef7fd9c..b06688cb
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=13460&range=03
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=13460&range=02-03
Stats: 227335 lines in 3780 files changed: 166899 ins; 30675 del; 29761 mod
Patch: https://git.openjdk.org/jdk/pull/13460.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/13460/head:pull/13460
PR: https://git.openjdk.org/jdk/pull/13460
More information about the hotspot-dev
mailing list