Request for reviews (L): 6761600: Use SSE 4.2 In STTNI Intrinsics

Tom Rodriguez Thomas.Rodriguez at Sun.COM
Fri Feb 6 17:40:46 PST 2009


>> Would you please point out where is this constant optimization?  
>> Thanks,
>
> It's the existing LibraryCallKit::inline_string_indexOf  
> implementation.  It's only used if the argument is a constant  
> string.  If you've benchmarked it and it's always faster to use the  
> SSE4.2 version that's fine.

Actually it occurs to me that the new SSE4.2 indexOf is improperly  
gated on is_Con()

   // don't intrinsify is argument isn't a constant string.
   if (!argument->is_Con()) {
     return false;
   }

This occurs near the top which means that the SSE4.2 version will  
never be used on non-constant strings even though it will work  
correctly with them.  I think you need to rearrange the tests.

tom

>
>
> tom
>
>>
>>
>> Changpeng.
>




More information about the hotspot-compiler-dev mailing list