aboutsummaryrefslogtreecommitdiff
path: root/test/CodeGen
diff options
context:
space:
mode:
authorChad Rosier <mcrosier@apple.com>2011-05-26 23:13:19 +0000
committerChad Rosier <mcrosier@apple.com>2011-05-26 23:13:19 +0000
commit62660310d9e5f9ecf329fd3cacb67c344a12ddbc (patch)
treef855da88d8e7d023205268a089306dafde169b50 /test/CodeGen
parent0958870a085e74c3216186700ca24f3272340ad2 (diff)
Renamed llvm.x86.sse42.crc32 intrinsics; crc64 doesn't exist.
crc32.[8|16|32] have been renamed to .crc32.32.[8|16|32] and crc64.[8|16|32] have been renamed to .crc32.64.[8|64]. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132163 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen')
-rw-r--r--test/CodeGen/X86/sse42.ll31
-rw-r--r--test/CodeGen/X86/sse42_64.ll21
2 files changed, 37 insertions, 15 deletions
diff --git a/test/CodeGen/X86/sse42.ll b/test/CodeGen/X86/sse42.ll
index f415439cd4..c7875238ec 100644
--- a/test/CodeGen/X86/sse42.ll
+++ b/test/CodeGen/X86/sse42.ll
@@ -1,38 +1,39 @@
; RUN: llc < %s -mtriple=i686-apple-darwin9 -mattr=sse42 | FileCheck %s -check-prefix=X32
; RUN: llc < %s -mtriple=x86_64-apple-darwin9 -mattr=sse42 | FileCheck %s -check-prefix=X64
-declare i32 @llvm.x86.sse42.crc32.8(i32, i8) nounwind
-declare i32 @llvm.x86.sse42.crc32.16(i32, i16) nounwind
-declare i32 @llvm.x86.sse42.crc32.32(i32, i32) nounwind
+declare i32 @llvm.x86.sse42.crc32.32.8(i32, i8) nounwind
+declare i32 @llvm.x86.sse42.crc32.32.16(i32, i16) nounwind
+declare i32 @llvm.x86.sse42.crc32.32.32(i32, i32) nounwind
-define i32 @crc32_8(i32 %a, i8 %b) nounwind {
- %tmp = call i32 @llvm.x86.sse42.crc32.8(i32 %a, i8 %b)
+define i32 @crc32_32_8(i32 %a, i8 %b) nounwind {
+ %tmp = call i32 @llvm.x86.sse42.crc32.32.8(i32 %a, i8 %b)
ret i32 %tmp
-; X32: _crc32_8:
+; X32: _crc32_32_8:
; X32: crc32b 8(%esp), %eax
-; X64: _crc32_8:
+; X64: _crc32_32_8:
; X64: crc32b %sil,
}
-define i32 @crc32_16(i32 %a, i16 %b) nounwind {
- %tmp = call i32 @llvm.x86.sse42.crc32.16(i32 %a, i16 %b)
+define i32 @crc32_32_16(i32 %a, i16 %b) nounwind {
+ %tmp = call i32 @llvm.x86.sse42.crc32.32.16(i32 %a, i16 %b)
ret i32 %tmp
-; X32: _crc32_16:
+; X32: _crc32_32_16:
; X32: crc32w 8(%esp), %eax
-; X64: _crc32_16:
+; X64: _crc32_32_16:
; X64: crc32w %si,
}
-define i32 @crc32_32(i32 %a, i32 %b) nounwind {
- %tmp = call i32 @llvm.x86.sse42.crc32.32(i32 %a, i32 %b)
+define i32 @crc32_32_32(i32 %a, i32 %b) nounwind {
+ %tmp = call i32 @llvm.x86.sse42.crc32.32.32(i32 %a, i32 %b)
ret i32 %tmp
-; X32: _crc32_32:
+; X32: _crc32_32_32:
; X32: crc32l 8(%esp), %eax
-; X64: _crc32_32:
+; X64: _crc32_32_32:
; X64: crc32l %esi,
}
+
diff --git a/test/CodeGen/X86/sse42_64.ll b/test/CodeGen/X86/sse42_64.ll
new file mode 100644
index 0000000000..8b3a69bcaa
--- /dev/null
+++ b/test/CodeGen/X86/sse42_64.ll
@@ -0,0 +1,21 @@
+; RUN: llc < %s -mtriple=x86_64-apple-darwin9 -mattr=sse42 | FileCheck %s -check-prefix=X64
+
+declare i64 @llvm.x86.sse42.crc32.64.8(i64, i8) nounwind
+declare i64 @llvm.x86.sse42.crc32.64.64(i64, i64) nounwind
+
+define i64 @crc32_64_8(i64 %a, i8 %b) nounwind {
+ %tmp = call i64 @llvm.x86.sse42.crc32.64.8(i64 %a, i8 %b)
+ ret i64 %tmp
+
+; X64: _crc32_64_8:
+; X64: crc32b %sil,
+}
+
+define i64 @crc32_64_64(i64 %a, i64 %b) nounwind {
+ %tmp = call i64 @llvm.x86.sse42.crc32.64.64(i64 %a, i64 %b)
+ ret i64 %tmp
+
+; X64: _crc32_64_64:
+; X64: crc32q %rsi,
+}
+