RFR: 8274242: Implement fast-path for ASCII-compatible CharsetEncoders on x86 [v3]

Claes Redestad redestad at openjdk.java.net
Mon Sep 27 12:14:05 UTC 2021


On Mon, 27 Sep 2021 09:34:21 GMT, Volker Simonis <simonis at openjdk.org> wrote:

>> Claes Redestad has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Add Matcher predicate to avoid changing shared code as non-x86 platforms implements support for the _encodeAsciiArray intrinsic
>
> src/hotspot/share/opto/c2compiler.cpp line 222:
> 
>> 220: #if !defined(X86)
>> 221:     return false; // not yet implemented
>> 222: #endif
> 
> It might be a little more work, but I think it's cleaner to move the decision whether the intrinisc is supported into the Matcher like for most other intrinsics and keep this code here platform independent. Otherwise we will get an increasing cascade of ifdefs as people start implementing this for other platforms.

Not too much work. I recently introduced platform-specific `matcher_*.hpp` files, so since then adding a boolean constant is easy (no need to muck with the .ad files).

-------------

PR: https://git.openjdk.java.net/jdk/pull/5621


More information about the nio-dev mailing list