RFR: 8257223: C2: Optimize RegMask::is_bound
Nils Eliasson
neliasso at openjdk.java.net
Mon Nov 30 22:47:00 UTC 2020
On Mon, 30 Nov 2020 13:00:15 GMT, Claes Redestad <redestad at openjdk.org> wrote:
> - Avoid Size() for is_bound1 (does relatively expensive computations)
> - Refactor loops to more efficiently check that the remainder of the mask is empty after a match. (Using the same structure helped gcc merge the control flows in `is_bound` for an additional benefit)
>
> This removes ~80k (~1%) of the C2 bootstrap overhead, and reduces time spent doing Register_Allocate in SimpleRepeatCompilation.largeMethod by about 0.4%. There's a small but statistically insignificant effect (~0.2%) on the score, too:
>
> Benchmark Mode Cnt Score Error Units
> SimpleRepeatCompilation.largeMethod_repeat_c2 ss 20 8119.278 ± 37.803 ms/op
> SimpleRepeatCompilation.largeMethod_repeat_c2 ss 20 8099.331 ± 33.159 ms/op
Looks good!
-------------
Marked as reviewed by neliasso (Reviewer).
PR: https://git.openjdk.java.net/jdk/pull/1515
More information about the hotspot-compiler-dev
mailing list