[9] RFR(XS): 8157842: indexOfChar intrinsic is not emitted on x86

Vladimir Kozlov vladimir.kozlov at oracle.com
Mon May 30 17:45:47 UTC 2016


match_rule_supported() should check UseSSE42Intrinsics instead since it 
is used in predicate:

   predicate(UseSSE42Intrinsics);
   match(Set result (StrIndexOfChar (Binary str1 cnt1) ch));


Also we can remove "assert(UseSSE >= 4" in 
MacroAssembler::string_indexof_char() because UseSSE42Intrinsics will be 
false if UseSSE < 4. See code in vm_version_x86.cpp

Thanks,
Vladimir

On 5/30/16 4:22 AM, Tobias Hartmann wrote:
> Hi,
>
> please review the following patch:
>
> https://bugs.openjdk.java.net/browse/JDK-8157842
> http://cr.openjdk.java.net/~thartmann/8157842/webrev.00/
>
> Andrew Haley noticed that there is a typo in x86.ad that prevents the StrIndexOfChar intrinsic from being emitted [1]. The problem is that we check for UseSSE > 4 instead of UseSSE >= 4 in Matcher::match_rule_supported() on x86.
>
> Tested with JPRT, RBT is running.
>
> Thanks,
> Tobias
>
> [1] http://mail.openjdk.java.net/pipermail/hotspot-dev/2016-May/023218.html
>


More information about the hotspot-compiler-dev mailing list