summaryrefslogtreecommitdiff
path: root/test/CodeGen/ms-x86-intrinsics.c
diff options
context:
space:
mode:
authorNico Weber <nicolasweber@gmx.de>2019-02-13 19:04:26 +0000
committerNico Weber <nicolasweber@gmx.de>2019-02-13 19:04:26 +0000
commit4f0d23590fe2c2fbeb4b40a67550cb2b3c34dbd5 (patch)
tree712f51fb70a3b83a21b1d52ef137d80216f6ce11 /test/CodeGen/ms-x86-intrinsics.c
parent6f25168e02f67dd5753b12f475e2f6a0f7b1a631 (diff)
downloadclang-4f0d23590fe2c2fbeb4b40a67550cb2b3c34dbd5.tar.gz
Re-enable the test disabled in r353836 and hopefully make it pass in gcc builds
Argument evaluation order is different between gcc and clang, so pull out the Builder calls to make the generated IR independent of the host compiler's argument evaluation order. Thanks to rnk for reminding me of this clang/gcc difference. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@353969 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/ms-x86-intrinsics.c')
-rw-r--r--test/CodeGen/ms-x86-intrinsics.c30
1 files changed, 13 insertions, 17 deletions
diff --git a/test/CodeGen/ms-x86-intrinsics.c b/test/CodeGen/ms-x86-intrinsics.c
index 8d703e9fa4..ffcf09052b 100644
--- a/test/CodeGen/ms-x86-intrinsics.c
+++ b/test/CodeGen/ms-x86-intrinsics.c
@@ -143,33 +143,29 @@ unsigned __int64 test__shiftleft128(unsigned __int64 l, unsigned __int64 h,
unsigned char d) {
return __shiftleft128(l, h, d);
}
-// FIXME: Add ':' after all the CHECK-X64 lines here once it's understood
-// why the order of the output is different when using clang or gcc as host cc.
// CHECK-X64-LABEL: define dso_local i64 @test__shiftleft128(i64 %l, i64 %h, i8 %d)
// CHECK-X64: = zext i64 %{{.*}} to i128
-// CHECK-X64 = shl nuw i128 %{{.*}}, 64
-// CHECK-X64 = zext i64 %{{.*}} to i128
-// CHECK-X64 = or i128 %
-// CHECK-X64 = and i8 %{{.*}}, 63
-// CHECK-X64 = shl i128 %
-// CHECK-X64 = lshr i128 %
-// CHECK-X64 = trunc i128 %
+// CHECK-X64: = shl nuw i128 %{{.*}}, 64
+// CHECK-X64: = zext i64 %{{.*}} to i128
+// CHECK-X64: = or i128 %
+// CHECK-X64: = and i8 %{{.*}}, 63
+// CHECK-X64: = shl i128 %
+// CHECK-X64: = lshr i128 %
+// CHECK-X64: = trunc i128 %
// CHECK-X64: ret i64 %
unsigned __int64 test__shiftright128(unsigned __int64 l, unsigned __int64 h,
unsigned char d) {
return __shiftright128(l, h, d);
}
-// FIXME: Add ':' after all the CHECK-X64 lines here once it's understood
-// why the order of the output is different when using clang or gcc as host cc.
// CHECK-X64-LABEL: define dso_local i64 @test__shiftright128(i64 %l, i64 %h, i8 %d)
// CHECK-X64: = zext i64 %{{.*}} to i128
-// CHECK-X64 = shl nuw i128 %{{.*}}, 64
-// CHECK-X64 = zext i64 %{{.*}} to i128
-// CHECK-X64 = or i128 %
-// CHECK-X64 = and i8 %{{.*}}, 63
-// CHECK-X64 = lshr i128 %
-// CHECK-X64 = trunc i128 %
+// CHECK-X64: = shl nuw i128 %{{.*}}, 64
+// CHECK-X64: = zext i64 %{{.*}} to i128
+// CHECK-X64: = or i128 %
+// CHECK-X64: = and i8 %{{.*}}, 63
+// CHECK-X64: = lshr i128 %
+// CHECK-X64: = trunc i128 %
// CHECK-X64: ret i64 %
#endif // defined(__x86_64__)