RFR: 8323079: Regression of -5% to -11% with SPECjvm2008-MonteCarlo after JDK-8319451
Quan Anh Mai
qamai at openjdk.org
Tue Jun 11 11:16:11 UTC 2024
On Tue, 11 Jun 2024 11:06:11 GMT, Quan Anh Mai <qamai at openjdk.org> wrote:
> Hi,
>
> I cannot explain the regression, comparing the current mainline to JDK-21 reveals a decrease in performance, yet it is only for some combinations of OS-GC and perfasm shows that the hot regions (>99% of execution time) do not contain differences that can explain the results.
>
> Consequently, with the advice of @TobiHartmann , I propose to effectively revert JDK-8319451 for the generation of `CMove`s inside loops. For those outside, the before-JDK-8319451 probability threshold is 0.001 and the current value is 0.01. I think the current value is more reasonable as evidenced by the benchmark added in JDK-8319451.
>
> Please kindly review, thank you very much.
> Quan Anh
@TobiHartmann
Can you verify if the regression is solved with this patch.
Also, I decided to not include your benchmark. The reason is that it is actually similar to that added by JDK-8319451. For such a small array, I believe the branch predictor can remember the whole sequence, which results in perfect prediction all the time, explaining the results. I recall that when making that benchmark, my CPU could remember an array of 1000 elements, which led to me using a huge array of 1 million.
Thank you very much.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/19650#issuecomment-2160481354
More information about the hotspot-compiler-dev
mailing list