Request for reviews (S): 7041100: The load in String.equals intrinsic executed before null check

Tom Rodriguez tom.rodriguez at oracle.com
Mon May 2 14:09:34 PDT 2011


I think the updated webrev looks good.

tom

On May 2, 2011, at 10:24 AM, Vladimir Kozlov wrote:

> http://cr.openjdk.java.net/~kvn/7041100/webrev
> 
> Fixed 7041100: The load in String.equals intrinsic executed before null check
> 
> String.equals intrinsic has (rec == arg) check followed by NULL check generated by gen_instanceof() when there was no NULL check before. If compiled method also has (rec == arg) check followed by explicit NULL check of argument then a load from argument could be scheduled before NULL check because of 6831314 bug.
> 
> Generate explicit check (uncast(argument) == null) in String.equals intrinsic until 6831314 is fixed. We have to uncast not-nullness otherwise the check will fold immediately and it is needed until after CCP phase.



More information about the hotspot-compiler-dev mailing list