RFR: JDK-8224963: Char-Byte Performance Enhancement
Adam Farley8
adam.farley at uk.ibm.com
Wed May 29 14:53:50 UTC 2019
Hi Vladimir,
I have a locally-written performance test I used to get the "6x".
Will chase up with the guy who wrote it to see if I can share it.
If not, I'll write a new one.
As for the enhancements, two options are:
- matching on the new method names, and replacing the inner logic
with some souped-up version of said logic.
- alter the code to match on one of the C2 idioms, though I imagine
if it were that simple, OpenJDK would come with a list of said
idioms so everything people write can be easily accelerated by the
JIT.
As for how OpenJ9 does it specifically, I don't know, and I suspect
it's safer if I don't find out, contamination-wise.
Does any of that help?
Best Regards
Adam Farley
IBM Runtimes
Vladimir Ivanov <vladimir.x.ivanov at oracle.com> wrote on 29/05/2019
13:22:27:
> From: Vladimir Ivanov <vladimir.x.ivanov at oracle.com>
> To: Adam Farley8 <adam.farley at uk.ibm.com>, hotspot-compiler-
> dev at openjdk.java.net
> Date: 29/05/2019 13:22
> Subject: Re: RFR: JDK-8224963: Char-Byte Performance Enhancement
>
> Hi Adam,
>
> The bug mentions ~6x improvement in throughput. Are there have any
> microbenchmarks you can share which demonstrate that? That would greatly
> simplify the analysis of changes you propose.
>
> Also, if you can elaborate on what optimization opportunities C2 misses
> in original code, please, do.
>
> Best regards,
> Vladimir Ivanov
>
> On 29/05/2019 12:45, Adam Farley8 wrote:
> > Hi All,
> >
> > Could someone familiar with the Hotspot JIT please review and opine on
> > the below?
> >
> > The Char-Byte encoding/decoding methods inside some of the sun.nio.cs
> > classes
> > (such as US_ASCII) see a lot of use, and OpenJDK on the OpenJ9 VM
seems to
> > do this a lot faster.
> >
> > Is it possible to achieve a similar improvement on OpenJDK on Hotspot
by
> > tweaking the CL code to match Hotspot JIT compiler idioms, or by
> > introducing
> > a method name for the HS JIT to match on?
> >
> > An example of these changes to US_ASCII.java is linked below. No
OpenJ9
> > code
> > is included in the work item or the webrev, to avoid contamination.
> >
> > Work item: https://urldefense.proofpoint.com/v2/url?
> u=https-3A__bugs.openjdk.java.net_browse_JDK-2D8224963&d=DwIC-
> g&c=jf_iaSHvJObTbx-siA1ZOg&r=P5m8KWUXJf-
> CeVJc0hDGD9AQ2LkcXDC0PMV9ntVw5Ho&m=4XPqGhxLchCLvSQhTIu3Wvm63NE2XpuEJf-
> PzjFCXb4&s=2ChxP3IE0tkvevxSXfil3PGlpEHkUPxgwMxHH5J-A34&e=
> >
> > Example Webrev: _https://urldefense.proofpoint.com/v2/url?
> u=http-3A__cr.openjdk.java.net_-7Eafarley_8224963_webrev_-5F&d=DwIC-
> g&c=jf_iaSHvJObTbx-siA1ZOg&r=P5m8KWUXJf-
> CeVJc0hDGD9AQ2LkcXDC0PMV9ntVw5Ho&m=4XPqGhxLchCLvSQhTIu3Wvm63NE2XpuEJf-
> PzjFCXb4&s=fCeNvvk3Fehc6ssZfoNkJao_NJyoxeov7cxiyMSvuwQ&e=
> >
> > Best Regards
> >
> > Adam Farley
> > IBM Runtimes
> >
> > Unless stated otherwise above:
> > IBM United Kingdom Limited - Registered in England and Wales with
number
> > 741598.
> > Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6
3AU
>
Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number
741598.
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/attachments/20190529/fc05be35/attachment-0001.html>
More information about the hotspot-compiler-dev
mailing list