[aarch64-port-dev ] RFR (trivial) : fix aarch64-8u type profile bug

Yangfei (Felix) felix.yang at huawei.com
Thu Sep 26 01:59:12 UTC 2019


> > > This also reminds me of another two aarch64-specific profiling issues:
> > > https://bugs.openjdk.java.net/browse/JDK-8188221
> > > https://bugs.openjdk.java.net/browse/JDK-8189439
> > >
> > > I think they also should be incorporated in aarch64 8u.  What do you think?
> >
> > I've always been reluctant to backport performance-only patches to 8u,
> > but I admit that version will be around for a long time, so OK.
> >
> 
> Looks like the upstream patches can be simplified: 'mdp' is loaded by
> test_method_data_pointer which is called by profile_return_type &
> profile_parameters_type.
> 
> Patch:
> diff -r 03fce7b04b42
> src/hotspot/cpu/aarch64/templateInterpreterGenerator_aarch64.cpp
> --- a/src/hotspot/cpu/aarch64/templateInterpreterGenerator_aarch64.cpp
> Tue Sep 24 03:28:42 2019 -0400
> +++ b/src/hotspot/cpu/aarch64/templateInterpreterGenerator_aarch64.cpp
> +++ Wed Sep 25 16:15:57 2019 +0800
> @@ -444,7 +444,6 @@
>      Register obj = r0;
>      Register mdp = r1;
>      Register tmp = r2;
> -    __ ldr(mdp, Address(rmethod, Method::method_data_offset()));
>      __ profile_return_type(mdp, obj, tmp);
>    }
> 
> @@ -1634,13 +1633,8 @@
>    __ mov(rscratch2, true);
>    __ strb(rscratch2, do_not_unlock_if_synchronized);
> 
> -  Label no_mdp;
>    Register mdp = r3;
> -  __ ldr(mdp, Address(rmethod, Method::method_data_offset()));
> -  __ cbz(mdp, no_mdp);
> -  __ add(mdp, mdp, in_bytes(MethodData::data_offset()));
>    __ profile_parameters_type(mdp, r1, r2);
> -  __ bind(no_mdp);
> 
>    // increment invocation count & check for overflow
>    Label invocation_counter_overflow;

CCing to hotspot-runtime-dev list.  

This has passed hotspot jtreg test on aarch64-linux.  Is it OK to go? 

Thanks,
Felix



More information about the aarch64-port-dev mailing list