RFR (XS): 8023472: C2 optimization breaks with G1
Christian Thalinger
christian.thalinger at oracle.com
Wed Aug 21 16:04:29 PDT 2013
On Aug 21, 2013, at 3:18 PM, Vladimir Kozlov <vladimir.kozlov at oracle.com> wrote:
> http://cr.openjdk.java.net/~kvn/8023472/webrev/
>
> The load of previous value in G1 pre-barrier code (method GraphKit::g1_write_barrier_pre()) does not have control. It is from the time when G1 code was merged into Hotspot sources. I can only speculate that it was done to allow commoning with a preceding normal load if it exists and to avoid generation of 2 loads.
> This problem, I think, only affects loads from an array because a load from a field should be guarded by NULL check of object.
>
> The fix is to put control on this load to always generate it after if (marking) check. I doubt it affect performance much. If there was load before the value should be in cache.
The fix looks good. Can you at least do a refworkload run to do some due diligence?
>
> Added regression test.
Could you change the name of the test? Since we moved away from using bug ids the test name should more or less explain what it tests. I suppose there will be more G1CrashTest's in the future :-)
-- Chris
>
> Thanks,
> Vladimir
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
More information about the hotspot-compiler-dev
mailing list