diff options
| author | QingShan Zhang <qshanz@cn.ibm.com> | 2018-08-20 02:52:55 +0000 |
|---|---|---|
| committer | QingShan Zhang <qshanz@cn.ibm.com> | 2018-08-20 02:52:55 +0000 |
| commit | f8f9af7ba529ab900eba783fa76229f77a545e07 (patch) | |
| tree | d213eade4c2f88037e22c55847afd8e1b689b128 /llvm/test/CodeGen/PowerPC/bitcasts-direct-move.ll | |
| parent | fdca0c6d2ea9b2d30965f8f170d705a858c43b9d (diff) | |
| download | bcm5719-llvm-f8f9af7ba529ab900eba783fa76229f77a545e07.tar.gz bcm5719-llvm-f8f9af7ba529ab900eba783fa76229f77a545e07.zip | |
[PowerPC] Add a peephole post RA to transform the inst that fed by add
If the arch is P8, we will select XFLOAD to load the floating point, and then, expand it to vsx and non-vsx X-form instruction post RA. This patch is trying to convert the X-form to D-form if it meets the requirement that one operand of the x-form inst is the special Zero register, and another operand fed by add inst. i.e.
y = add imm, reg
LFDX. 0, y
-->
LFD imm(reg)
Reviewers: Nemanjai
Differential Revision: https://reviews.llvm.org/D49007
llvm-svn: 340149
Diffstat (limited to 'llvm/test/CodeGen/PowerPC/bitcasts-direct-move.ll')
| -rw-r--r-- | llvm/test/CodeGen/PowerPC/bitcasts-direct-move.ll | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/test/CodeGen/PowerPC/bitcasts-direct-move.ll b/llvm/test/CodeGen/PowerPC/bitcasts-direct-move.ll index e5fd9f50a06..54e378e8d8a 100644 --- a/llvm/test/CodeGen/PowerPC/bitcasts-direct-move.ll +++ b/llvm/test/CodeGen/PowerPC/bitcasts-direct-move.ll @@ -18,7 +18,7 @@ define i64 @f64toi64(double %a) { entry: %0 = bitcast double %a to i64 ret i64 %0 -; CHECK-P7: stfdx 1, +; CHECK-P7: stfd 1, ; CHECK-P7: ld 3, ; CHECK: mffprd 3, 1 } @@ -39,7 +39,7 @@ entry: %0 = bitcast i64 %a to double ret double %0 ; CHECK-P7: std 3, -; CHECK-P7: lfdx 1, +; CHECK-P7: lfd 1, ; CHECK: mtvsrd 1, 3 } @@ -58,7 +58,7 @@ define i64 @f64toi64u(double %a) { entry: %0 = bitcast double %a to i64 ret i64 %0 -; CHECK-P7: stfdx 1, +; CHECK-P7: stfd 1, ; CHECK-P7: ld 3, ; CHECK: mffprd 3, 1 } @@ -79,6 +79,6 @@ entry: %0 = bitcast i64 %a to double ret double %0 ; CHECK-P7: std 3, -; CHECK-P7: lfdx 1, +; CHECK-P7: lfd 1, ; CHECK: mtvsrd 1, 3 } |

