discuss about release barrier for final fields initialization
Wei Kuai
wei.kuai at gmail.com
Fri Jan 19 10:05:45 UTC 2024
I've submitted a jbs for it. https://bugs.openjdk.org/browse/JDK-8324186
Thanks,
Kuai Wei
On Fri, Jan 19, 2024 at 5:08 PM Andrew Haley <aph-open at littlepinkcloud.com>
wrote:
> On 1/18/24 10:49, Wei Kuai wrote:
> > I tested "dmb.ishst; dmb.ishld" for release barrier. The test case is
> jmh of allocation with final fields.
> https://gist.github.com/kuaiwei/f71fba40df29991c93325a8600e34c13 <
> https://gist.github.com/kuaiwei/f71fba40df29991c93325a8600e34c13>
> > In N1
> > dmb.ish : 1168.059 ops/s
> > dmb.ishst+dmb.ishld: 1321.783 ops/s
> > dmb.ishst : 1511.267 ops/s
> > In N2
> > dmb.ish : 3672.087 ops/s
> > dmb.ishst+dmb.ishld: 4840.322 ops/s
> > dmb.ishst : 6005.430 ops/s
> >
> > The "dmb.ishst+dmb.ishld" can gain 13% and 32% on N1 and N2. It looks a
> better replacement for "dmb.ish"
>
> Let's do that, then.
>
> If you'd like to submit a patch that does this, please make sure to include
> the benchmark.
>
> We should also stop merging 'dmb ld' and 'dmb st' into 'dmb sy'. We still
> want
> to merge duplicated `dmb`s, but the side effect of strengthening is not
> good.
>
> --
> Andrew Haley (he/him)
> Java Platform Lead Engineer
> Red Hat UK Ltd. <https://www.redhat.com>
> https://keybase.io/andrewhaley
> EAC8 43EB D3EF DB98 CC77 2FAD A5CD 6035 332F A671
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/hotspot-compiler-dev/attachments/20240119/9095f7e4/attachment.htm>
More information about the hotspot-compiler-dev
mailing list