Integrated: 8253734: C2: Optimize Move nodes

Vladimir Ivanov vlivanov at openjdk.java.net
Mon Oct 26 17:30:25 UTC 2020


On Fri, 23 Oct 2020 08:27:50 GMT, Vladimir Ivanov <vlivanov at openjdk.org> wrote:

> Introduce the following transformations for Move nodes: 
> 1. `MoveI2F (MoveF2I x) => x`
> 
> 1. `MoveI2F (LoadI mem) => LoadF mem` 
> 
> 1. `StoreI mem (MoveF2I x) => StoreF mem x` 
> 
> (The same applies to MoveL2D/MoveD2L.)
> 
> №1 eliminates redundant operations and №2/№3 avoid reg-to-reg moves in generated code:
> 0x000000010d09964c:   vmovss 0x20(%rsi),%xmm1
> 0x000000010d099651:   vmovd  %xmm1,%eax                   ;*invokestatic floatToRawIntBits
> vs
> 0x0000000110c5a6cc:   mov    0x20(%rsi),%eax              ;*invokestatic floatToRawIntBits
>  
> 
> (№2 and №3 are performed late (after loop opts are over) to avoid high-level optimizations passes to handle newly introduced mismatched accesses.)
> 
> Testing: tier1-5.

This pull request has now been integrated.

Changeset: 83a91bfa
Author:    Vladimir Ivanov <vlivanov at openjdk.org>
URL:       https://git.openjdk.java.net/jdk/commit/83a91bfa
Stats:     132 lines in 5 files changed: 117 ins; 0 del; 15 mod

8253734: C2: Optimize Move nodes

Reviewed-by: thartmann, neliasso, kvn

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

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


More information about the hotspot-compiler-dev mailing list