string methods intrinsics, place for checks

Tom Rodriguez Thomas.Rodriguez at Sun.COM
Tue Aug 18 15:51:10 PDT 2009


I don't know that there's a clear place to draw the line.  I'd tend  
towards writing things in ideal if possible since that exposes it to  
optimization and reduces the amount of assembly.  I'd probably have a  
stronger opinion about a more concrete example.

tom

On Aug 18, 2009, at 2:35 PM, Vladimir Kozlov wrote:

> I am modifying our string intrinsics to pass char[] pointers and
> counters instead of string oops to allow EA eliminate non-escaping
> string object (6827605). This will also allow to do some checks
> in ideal graph instead of in a mach node encoding. But it may affect
> ideal optimizations since it may complicate control flow.
>
> So I need your opinion where I should draw the line.
>
> For example, for String.equals() I compare counters in ideal but
> check it for 0 in mach (mach node needs only one counter) since
> == 0 is rare case.
>
> Thanks,
> Vladimir
>
>



More information about the hotspot-compiler-dev mailing list