[llvm] 1f37d94 - [PowerPC] Add extra v2i64 splat load tests. NFC
David Green via llvm-commits
llvm-commits at lists.llvm.org
Thu May 5 07:57:05 PDT 2022
Author: David Green
Date: 2022-05-05T15:56:55+01:00
New Revision: 1f37d948383a7ef009d4cfe35a0ce7fe4d21c8a0
URL: https://github.com/llvm/llvm-project/commit/1f37d948383a7ef009d4cfe35a0ce7fe4d21c8a0
DIFF: https://github.com/llvm/llvm-project/commit/1f37d948383a7ef009d4cfe35a0ce7fe4d21c8a0.diff
LOG: [PowerPC] Add extra v2i64 splat load tests. NFC
In service of D123801, this add some tests targetting a v2i64 splat of a
load, and regenerates vsx_shuffle_le.ll for easier updating.
Added:
Modified:
llvm/test/CodeGen/PowerPC/canonical-merge-shuffles.ll
llvm/test/CodeGen/PowerPC/vsx_shuffle_le.ll
Removed:
################################################################################
diff --git a/llvm/test/CodeGen/PowerPC/canonical-merge-shuffles.ll b/llvm/test/CodeGen/PowerPC/canonical-merge-shuffles.ll
index 97dffac2022c3..a92d25b42c0e4 100644
--- a/llvm/test/CodeGen/PowerPC/canonical-merge-shuffles.ll
+++ b/llvm/test/CodeGen/PowerPC/canonical-merge-shuffles.ll
@@ -821,6 +821,85 @@ entry:
ret <2 x i64> %1
}
+define <2 x i64> @testSplati64_0(<1 x i64>* nocapture readonly %ptr) #0 {
+; CHECK-P8-LABEL: testSplati64_0:
+; CHECK-P8: # %bb.0: # %entry
+; CHECK-P8-NEXT: lxvdsx v2, 0, r3
+; CHECK-P8-NEXT: blr
+;
+; CHECK-P9-LABEL: testSplati64_0:
+; CHECK-P9: # %bb.0: # %entry
+; CHECK-P9-NEXT: lxvdsx v2, 0, r3
+; CHECK-P9-NEXT: blr
+;
+; CHECK-P9-BE-LABEL: testSplati64_0:
+; CHECK-P9-BE: # %bb.0: # %entry
+; CHECK-P9-BE-NEXT: lxvdsx v2, 0, r3
+; CHECK-P9-BE-NEXT: blr
+;
+; CHECK-NOVSX-LABEL: testSplati64_0:
+; CHECK-NOVSX: # %bb.0: # %entry
+; CHECK-NOVSX-NEXT: ld r3, 0(r3)
+; CHECK-NOVSX-NEXT: addi r4, r1, -16
+; CHECK-NOVSX-NEXT: std r3, -8(r1)
+; CHECK-NOVSX-NEXT: std r3, -16(r1)
+; CHECK-NOVSX-NEXT: lvx v2, 0, r4
+; CHECK-NOVSX-NEXT: blr
+;
+; CHECK-P7-LABEL: testSplati64_0:
+; CHECK-P7: # %bb.0: # %entry
+; CHECK-P7-NEXT: lxvdsx v2, 0, r3
+; CHECK-P7-NEXT: blr
+entry:
+ %0 = load <1 x i64>, <1 x i64>* %ptr, align 8
+ %1 = shufflevector <1 x i64> %0, <1 x i64> undef, <2 x i32> <i32 0, i32 0>
+ ret <2 x i64> %1
+}
+
+define <2 x i64> @testSplati64_1(<2 x i64>* nocapture readonly %ptr) #0 {
+; CHECK-P8-LABEL: testSplati64_1:
+; CHECK-P8: # %bb.0: # %entry
+; CHECK-P8-NEXT: lxvd2x vs0, 0, r3
+; CHECK-P8-NEXT: xxspltd v2, vs0, 1
+; CHECK-P8-NEXT: blr
+;
+; CHECK-P9-LABEL: testSplati64_1:
+; CHECK-P9: # %bb.0: # %entry
+; CHECK-P9-NEXT: lxv v2, 0(r3)
+; CHECK-P9-NEXT: xxspltd v2, v2, 0
+; CHECK-P9-NEXT: blr
+;
+; CHECK-P9-BE-LABEL: testSplati64_1:
+; CHECK-P9-BE: # %bb.0: # %entry
+; CHECK-P9-BE-NEXT: lxv v2, 0(r3)
+; CHECK-P9-BE-NEXT: xxspltd v2, v2, 1
+; CHECK-P9-BE-NEXT: blr
+;
+; CHECK-NOVSX-LABEL: testSplati64_1:
+; CHECK-NOVSX: # %bb.0: # %entry
+; CHECK-NOVSX-NEXT: ld r4, 8(r3)
+; CHECK-NOVSX-NEXT: std r4, -8(r1)
+; CHECK-NOVSX-NEXT: addis r4, r2, .LCPI21_0 at toc@ha
+; CHECK-NOVSX-NEXT: ld r3, 0(r3)
+; CHECK-NOVSX-NEXT: addi r4, r4, .LCPI21_0 at toc@l
+; CHECK-NOVSX-NEXT: lvx v2, 0, r4
+; CHECK-NOVSX-NEXT: std r3, -16(r1)
+; CHECK-NOVSX-NEXT: addi r3, r1, -16
+; CHECK-NOVSX-NEXT: lvx v3, 0, r3
+; CHECK-NOVSX-NEXT: vperm v2, v3, v3, v2
+; CHECK-NOVSX-NEXT: blr
+;
+; CHECK-P7-LABEL: testSplati64_1:
+; CHECK-P7: # %bb.0: # %entry
+; CHECK-P7-NEXT: lxvd2x vs0, 0, r3
+; CHECK-P7-NEXT: xxspltd v2, vs0, 1
+; CHECK-P7-NEXT: blr
+entry:
+ %0 = load <2 x i64>, <2 x i64>* %ptr, align 8
+ %1 = shufflevector <2 x i64> %0, <2 x i64> undef, <2 x i32> <i32 1, i32 1>
+ ret <2 x i64> %1
+}
+
define dso_local void @testByteSplat() #0 {
; CHECK-P8-LABEL: testByteSplat:
; CHECK-P8: # %bb.0: # %entry
diff --git a/llvm/test/CodeGen/PowerPC/vsx_shuffle_le.ll b/llvm/test/CodeGen/PowerPC/vsx_shuffle_le.ll
index c2b886d6055a9..eda1ecb9396af 100644
--- a/llvm/test/CodeGen/PowerPC/vsx_shuffle_le.ll
+++ b/llvm/test/CodeGen/PowerPC/vsx_shuffle_le.ll
@@ -1,3 +1,4 @@
+; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
; RUN: llc -verify-machineinstrs -mcpu=pwr8 -mattr=+vsx \
; RUN: -mtriple=powerpc64le-unknown-linux-gnu < %s | FileCheck %s
@@ -9,267 +10,315 @@
; RUN: --check-prefix=CHECK-P9 --implicit-check-not xxswapd
define <2 x double> @test00(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test00:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: xxspltd 34, 0, 0
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test00:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(3)
+; CHECK-P9-NEXT: xxspltd 34, 0, 1
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 0, i32 0>
ret <2 x double> %v3
-
-; CHECK-LABEL: test00
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: xxspltd 34, 0, 0
-
-; CHECK-P9-LABEL: test00
-; CHECK-P9: lxv 0, 0(3)
-; CHECK-P9: xxspltd 34, 0, 1
}
define <2 x double> @test01(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test01:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: xxswapd 34, 0
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test01:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 34, 0(3)
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 0, i32 1>
ret <2 x double> %v3
-
-; CHECK-LABEL: test01
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: xxswapd 34, 0
-
-; CHECK-P9-LABEL: test01
-; CHECK-P9: lxv 34, 0(3)
}
define <2 x double> @test02(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test02:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: lxvd2x 1, 0, 4
+; CHECK-NEXT: xxswapd 0, 0
+; CHECK-NEXT: xxswapd 1, 1
+; CHECK-NEXT: xxmrgld 34, 1, 0
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test02:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(3)
+; CHECK-P9-NEXT: lxv 1, 0(4)
+; CHECK-P9-NEXT: xxmrgld 34, 1, 0
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 0, i32 2>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test02
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: lxvd2x 1, 0, 4
-; CHECK: xxswapd 0, 0
-; CHECK: xxswapd 1, 1
-; CHECK: xxmrgld 34, 1, 0
-
-; CHECK-P9-LABEL: @test02
-; CHECK-P9: lxv 0, 0(3)
-; CHECK-P9: lxv 1, 0(4)
-; CHECK-P9: xxmrgld 34, 1, 0
}
define <2 x double> @test03(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test03:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: lxvd2x 1, 0, 4
+; CHECK-NEXT: xxswapd 0, 0
+; CHECK-NEXT: xxswapd 1, 1
+; CHECK-NEXT: xxpermdi 34, 1, 0, 1
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test03:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(3)
+; CHECK-P9-NEXT: lxv 1, 0(4)
+; CHECK-P9-NEXT: xxpermdi 34, 1, 0, 1
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 0, i32 3>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test03
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: lxvd2x 1, 0, 4
-; CHECK: xxswapd 0, 0
-; CHECK: xxswapd 1, 1
-; CHECK: xxpermdi 34, 1, 0, 1
-
-; CHECK-P9-LABEL: @test03
-; CHECK-P9: lxv 0, 0(3)
-; CHECK-P9: lxv 1, 0(4)
-; CHECK-P9: xxpermdi 34, 1, 0, 1
}
define <2 x double> @test10(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test10:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 34, 0, 3
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test10:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxvd2x 34, 0, 3
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 1, i32 0>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test10
-; CHECK: lxvd2x 34, 0, 3
-
-; CHECK-P9-LABEL: @test10
-; CHECK-P9: lxvd2x 34, 0, 3
}
define <2 x double> @test11(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test11:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: xxspltd 34, 0, 1
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test11:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(3)
+; CHECK-P9-NEXT: xxspltd 34, 0, 0
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 1, i32 1>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test11
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: xxspltd 34, 0, 1
-
-; CHECK-P9-LABEL: @test11
-; CHECK-P9: lxv 0, 0(3)
-; CHECK-P9: xxspltd 34, 0, 0
}
define <2 x double> @test12(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test12:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: lxvd2x 1, 0, 4
+; CHECK-NEXT: xxswapd 0, 0
+; CHECK-NEXT: xxswapd 1, 1
+; CHECK-NEXT: xxpermdi 34, 1, 0, 2
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test12:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(3)
+; CHECK-P9-NEXT: lxv 1, 0(4)
+; CHECK-P9-NEXT: xxpermdi 34, 1, 0, 2
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 1, i32 2>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test12
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: lxvd2x 1, 0, 4
-; CHECK: xxswapd 0, 0
-; CHECK: xxswapd 1, 1
-; CHECK: xxpermdi 34, 1, 0, 2
-
-; CHECK-P9-LABEL: @test12
-; CHECK-P9: lxv 0, 0(3)
-; CHECK-P9: lxv 1, 0(4)
-; CHECK-P9: xxpermdi 34, 1, 0, 2
}
define <2 x double> @test13(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test13:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: lxvd2x 1, 0, 4
+; CHECK-NEXT: xxswapd 0, 0
+; CHECK-NEXT: xxswapd 1, 1
+; CHECK-NEXT: xxmrghd 34, 1, 0
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test13:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(3)
+; CHECK-P9-NEXT: lxv 1, 0(4)
+; CHECK-P9-NEXT: xxmrghd 34, 1, 0
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 1, i32 3>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test13
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: lxvd2x 1, 0, 4
-; CHECK: xxswapd 0, 0
-; CHECK: xxswapd 1, 1
-; CHECK: xxmrghd 34, 1, 0
-
-; CHECK-P9-LABEL: @test13
-; CHECK-P9: lxv 0, 0(3)
-; CHECK-P9: lxv 1, 0(4)
-; CHECK-P9: xxmrghd 34, 1, 0
}
define <2 x double> @test20(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test20:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: lxvd2x 1, 0, 4
+; CHECK-NEXT: xxswapd 0, 0
+; CHECK-NEXT: xxswapd 1, 1
+; CHECK-NEXT: xxmrgld 34, 0, 1
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test20:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(3)
+; CHECK-P9-NEXT: lxv 1, 0(4)
+; CHECK-P9-NEXT: xxmrgld 34, 0, 1
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 2, i32 0>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test20
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: lxvd2x 1, 0, 4
-; CHECK: xxswapd 0, 0
-; CHECK: xxswapd 1, 1
-; CHECK: xxmrgld 34, 0, 1
-
-; CHECK-P9-LABEL: @test20
-; CHECK-P9: lxv 0, 0(3)
-; CHECK-P9: lxv 1, 0(4)
-; CHECK-P9: xxmrgld 34, 0, 1
}
define <2 x double> @test21(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test21:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: lxvd2x 1, 0, 4
+; CHECK-NEXT: xxswapd 0, 0
+; CHECK-NEXT: xxswapd 1, 1
+; CHECK-NEXT: xxpermdi 34, 0, 1, 1
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test21:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(3)
+; CHECK-P9-NEXT: lxv 1, 0(4)
+; CHECK-P9-NEXT: xxpermdi 34, 0, 1, 1
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 2, i32 1>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test21
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: lxvd2x 1, 0, 4
-; CHECK: xxswapd 0, 0
-; CHECK: xxswapd 1, 1
-; CHECK: xxpermdi 34, 0, 1, 1
-
-; CHECK-P9-LABEL: @test21
-; CHECK-P9: lxv 0, 0(3)
-; CHECK-P9: lxv 1, 0(4)
-; CHECK-P9: xxpermdi 34, 0, 1, 1
}
define <2 x double> @test22(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test22:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 4
+; CHECK-NEXT: xxspltd 34, 0, 0
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test22:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(4)
+; CHECK-P9-NEXT: xxspltd 34, 0, 1
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 2, i32 2>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test22
-; CHECK: lxvd2x 0, 0, 4
-; CHECK: xxspltd 34, 0, 0
-
-; CHECK-P9-LABEL: @test22
-; CHECK-P9: lxv 0, 0(4)
-; CHECK-P9: xxspltd 34, 0, 1
}
define <2 x double> @test23(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test23:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 4
+; CHECK-NEXT: xxswapd 34, 0
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test23:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 34, 0(4)
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 2, i32 3>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test23
-; CHECK: lxvd2x 0, 0, 4
-; CHECK: xxswapd 34, 0
-
-; CHECK-P9-LABEL: @test23
-; CHECK-P9: lxv 34, 0(4)
}
define <2 x double> @test30(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test30:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: lxvd2x 1, 0, 4
+; CHECK-NEXT: xxswapd 0, 0
+; CHECK-NEXT: xxswapd 1, 1
+; CHECK-NEXT: xxpermdi 34, 0, 1, 2
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test30:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(3)
+; CHECK-P9-NEXT: lxv 1, 0(4)
+; CHECK-P9-NEXT: xxpermdi 34, 0, 1, 2
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 3, i32 0>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test30
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: lxvd2x 1, 0, 4
-; CHECK: xxswapd 0, 0
-; CHECK: xxswapd 1, 1
-; CHECK: xxpermdi 34, 0, 1, 2
-
-; CHECK-P9-LABEL: @test30
-; CHECK-P9: lxv 0, 0(3)
-; CHECK-P9: lxv 1, 0(4)
-; CHECK-P9: xxpermdi 34, 0, 1, 2
}
define <2 x double> @test31(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test31:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 3
+; CHECK-NEXT: lxvd2x 1, 0, 4
+; CHECK-NEXT: xxswapd 0, 0
+; CHECK-NEXT: xxswapd 1, 1
+; CHECK-NEXT: xxmrghd 34, 0, 1
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test31:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(3)
+; CHECK-P9-NEXT: lxv 1, 0(4)
+; CHECK-P9-NEXT: xxmrghd 34, 0, 1
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 3, i32 1>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test31
-; CHECK: lxvd2x 0, 0, 3
-; CHECK: lxvd2x 1, 0, 4
-; CHECK: xxswapd 0, 0
-; CHECK: xxswapd 1, 1
-; CHECK: xxmrghd 34, 0, 1
-
-; CHECK-P9-LABEL: @test31
-; CHECK-P9: lxv 0, 0(3)
-; CHECK-P9: lxv 1, 0(4)
-; CHECK-P9: xxmrghd 34, 0, 1
}
define <2 x double> @test32(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test32:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 34, 0, 4
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test32:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxvd2x 34, 0, 4
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 3, i32 2>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test32
-; CHECK: lxvd2x 34, 0, 4
-
-; CHECK-P9-LABEL: @test32
-; CHECK-P9: lxvd2x 34, 0, 4
}
define <2 x double> @test33(<2 x double>* %p1, <2 x double>* %p2) {
+; CHECK-LABEL: test33:
+; CHECK: # %bb.0:
+; CHECK-NEXT: lxvd2x 0, 0, 4
+; CHECK-NEXT: xxspltd 34, 0, 1
+; CHECK-NEXT: blr
+;
+; CHECK-P9-LABEL: test33:
+; CHECK-P9: # %bb.0:
+; CHECK-P9-NEXT: lxv 0, 0(4)
+; CHECK-P9-NEXT: xxspltd 34, 0, 0
+; CHECK-P9-NEXT: blr
%v1 = load <2 x double>, <2 x double>* %p1
%v2 = load <2 x double>, <2 x double>* %p2
%v3 = shufflevector <2 x double> %v1, <2 x double> %v2, <2 x i32> < i32 3, i32 3>
ret <2 x double> %v3
-
-; CHECK-LABEL: @test33
-; CHECK: lxvd2x 0, 0, 4
-; CHECK: xxspltd 34, 0, 1
-
-; CHECK-P9-LABEL: @test33
-; CHECK-P9: lxv 0, 0(4)
-; CHECK-P9: xxspltd 34, 0, 0
}
More information about the llvm-commits
mailing list