RFR(M) JDK-8181809 PPC64: Leverage mtfprd/mffprd on POWER8

Matthew Brandyberry mbrandy at linux.vnet.ibm.com
Tue Jun 20 13:38:57 UTC 2017


Hi Martin,

Thanks for the review.  I'll take a look at these areas and report back 
-- especially the integration into C1.

On 6/20/17 8:33 AM, Doerr, Martin wrote:
> Hi Matt,
>
> thanks for providing this webrev. I had already thought about using these instructions for this purpose and your change matches pretty much what I'd do.
>
> Here a couple of comments:
> ppc.ad:
> This was a lot of work. Thanks for doing it.
> effect(DEF dst, USE src); is redundant if a match rule match(Set dst (MoveL2D src)); exists.
>
> vm_version:
> This part is in conflict with Michihiro's change which is already pushed in jdk10, but it's trivial to resolve. I'm ok with using has_vpmsumb() for has_mtfprd(). In the past, we sometimes had trouble with assuming that a certain Power processor supports all new instructions if it supports certain ones. We also use the hotspot code on as400 where certain instruction subsets were disabled while other Power 8 instructions were usable. Maybe you can double-check if there may exist configurations in which has_vpmsumb() doesn't match has_mtfprd().
>
> C1:
> It should also be possible to use the instructions in C1 compiler. Maybe you would like to take a look at it as well and see if it can be done with feasible effort.
> Here are some hints:
> The basic decisions are made in LIRGenerator::do_Convert. You could skip the force_to_spill or must_start_in_memory steps.
> The final assembly code gets emitted in LIR_Assembler::emit_opConvert where you could replace the store instructions.
> For testing, you can use -XX:TieredStopAtLevel=1, for example.
>
> Thanks and best regards,
> Martin
>
>
> -----Original Message-----
> From: hotspot-dev [mailto:hotspot-dev-bounces at openjdk.java.net] On Behalf Of Matthew Brandyberry
> Sent: Montag, 19. Juni 2017 18:28
> To: ppc-aix-port-dev at openjdk.java.net; hotspot-dev at openjdk.java.net
> Subject: RFR(M) JDK-8181809 PPC64: Leverage mtfprd/mffprd on POWER8
>
> This is a PPC-specific hotspot optimization that leverages the
> mtfprd/mffprd instructions for for movement between general purpose and
> floating point registers (rather than through memory).  It yields a ~35%
> improvement measured via a microbenchmark. Please review: Bug:
> https://bugs.openjdk.java.net/browse/JDK-8181809 Webrev:
> http://cr.openjdk.java.net/~gromero/8181809/v1/ Thanks, Matt
>
>



More information about the hotspot-dev mailing list