RFR: 8269598: Regressions up to 5% on aarch64 seems due to JDK-8268858
Joshua Zhu
jzhu at openjdk.java.net
Thu Jul 15 01:52:14 UTC 2021
On Tue, 13 Jul 2021 16:08:23 GMT, Vladimir Kozlov <kvn at openjdk.org> wrote:
>> Hi,
>>
>> Please review this change.
>> It fixes the SPECjvm2008 regression on aarch64 caused by JDK-8268858.
>>
>> Compressor::compress() in case "compress" of SPECjvm2008 performed
>> degraded by 5% due to extra spillings. There existed an LRG that covered
>> almost the entire function, hence it interfered with more live ranges.
>> These interferences caused the LRG no freedom and lastly RA had to spill
>> it to stack. After the fix, the LRG is split into two shorter live
>> ranges. Both LRGs are assigned to registers due to fewer interferences.
>>
>> See details at: http://cr.openjdk.java.net/~jzhu/8269598/analysis.pdf
>> OptoAssembly: http://cr.openjdk.java.net/~jzhu/8269598/
>>
>> The root cause is:
>> When PreserveFramePointer is off, frame pointer is allocatable, but
>> different from other SOC registers, it is excluded from fatproj's mask
>> because its save type is No-Save. Therefore fatproj was not treated as
>> high-pressure transition point in the previous int_pressure_limit()
>> computation. This fix ensures high pressure at fatproj when
>> PreserveFramePointer is off. See check_pressure_at_fatproj() [1].
>>
>> After this fix, the regression disappeared.
>> The result of regression cases in SPECjvm2008:
>> http://cr.openjdk.java.net/~jzhu/8269598/Book1.pdf
>>
>> [1] https://github.com/openjdk/jdk/blob/375fc2a2b29c454b36d3ae068a080b28f6ec04e9/src/hotspot/share/opto/chaitin.hpp#L620
>>
>> Best Regards,
>> Joshua
>
> Good.
Thanks @vnkozlov @dean-long for your review.
-------------
PR: https://git.openjdk.java.net/jdk/pull/4766
More information about the hotspot-compiler-dev
mailing list