aboutsummaryrefslogtreecommitdiff
path: root/test/Transforms
diff options
context:
space:
mode:
authorMatt Beaumont-Gay <matthewbg@google.com>2012-12-14 17:55:15 +0000
committerMatt Beaumont-Gay <matthewbg@google.com>2012-12-14 17:55:15 +0000
commit6aed25d93d1cfcde5809a73ffa7dc1b0d6396f66 (patch)
tree57e2fdf1caf960d8d878e0289f32af6759832b49 /test/Transforms
parent7139cfb19b1cc28dfd5e274c07ec68835bc6d6d6 (diff)
parent1ad9253c9d34ccbce3e7e4ea5d87c266cbf93410 (diff)
Updating branches/google/stable to r169803
git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/google/stable@170212 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms')
-rw-r--r--test/Transforms/BBVectorize/X86/cmp-types.ll16
-rw-r--r--test/Transforms/BBVectorize/X86/sh-rec.ll54
-rw-r--r--test/Transforms/BBVectorize/X86/sh-rec2.ll85
-rw-r--r--test/Transforms/BBVectorize/X86/sh-rec3.ll170
-rw-r--r--test/Transforms/BBVectorize/X86/sh-types.ll25
-rw-r--r--test/Transforms/BBVectorize/simple.ll24
-rw-r--r--test/Transforms/ConstProp/loads.ll132
-rw-r--r--test/Transforms/GVN/crash-no-aa.ll3
-rw-r--r--test/Transforms/GVN/rle.ll8
-rw-r--r--test/Transforms/GlobalOpt/blockaddress.ll20
-rw-r--r--test/Transforms/GlobalOpt/tls.ll53
-rw-r--r--test/Transforms/IndVarSimplify/eliminate-comparison.ll103
-rw-r--r--test/Transforms/IndVarSimplify/iv-zext.ll2
-rw-r--r--test/Transforms/Inline/2006-11-09-InlineCGUpdate-2.ll1
-rw-r--r--test/Transforms/Inline/2006-11-09-InlineCGUpdate.ll1
-rw-r--r--test/Transforms/Inline/lifetime-no-datalayout.ll23
-rw-r--r--test/Transforms/Inline/lifetime.ll44
-rw-r--r--test/Transforms/InstCombine/2010-05-30-memcpy-Struct.ll (renamed from test/Transforms/SimplifyLibCalls/2010-05-30-memcpy-Struct.ll)6
-rw-r--r--test/Transforms/InstCombine/2010-11-01-lshr-mask.ll4
-rw-r--r--test/Transforms/InstCombine/2012-07-25-LoadPart.ll10
-rw-r--r--test/Transforms/InstCombine/abs-1.ll41
-rw-r--r--test/Transforms/InstCombine/align-external.ll2
-rw-r--r--test/Transforms/InstCombine/alloca.ll16
-rw-r--r--test/Transforms/InstCombine/cos-1.ll38
-rw-r--r--test/Transforms/InstCombine/cos-2.ll17
-rw-r--r--test/Transforms/InstCombine/debug-line.ll (renamed from test/Transforms/SimplifyLibCalls/debug-line.ll)2
-rw-r--r--test/Transforms/InstCombine/disable-simplify-libcalls.ll335
-rw-r--r--test/Transforms/InstCombine/double-float-shrink-1.ll (renamed from test/Transforms/SimplifyLibCalls/double-float-shrink.ll)262
-rw-r--r--test/Transforms/InstCombine/double-float-shrink-2.ll80
-rw-r--r--test/Transforms/InstCombine/exp2-1.ll76
-rw-r--r--test/Transforms/InstCombine/exp2-2.ll17
-rw-r--r--test/Transforms/InstCombine/fast-math.ll32
-rw-r--r--test/Transforms/InstCombine/ffs-1.ll134
-rw-r--r--test/Transforms/InstCombine/fprintf-1.ll80
-rw-r--r--test/Transforms/InstCombine/fputs-1.ll43
-rw-r--r--test/Transforms/InstCombine/fwrite-1.ll57
-rw-r--r--test/Transforms/InstCombine/icmp.ll18
-rw-r--r--test/Transforms/InstCombine/isascii-1.ll32
-rw-r--r--test/Transforms/InstCombine/isdigit-1.ll48
-rw-r--r--test/Transforms/InstCombine/memcmp-1.ll72
-rw-r--r--test/Transforms/InstCombine/memcmp-2.ll17
-rw-r--r--test/Transforms/InstCombine/memcpy-1.ll17
-rw-r--r--test/Transforms/InstCombine/memcpy-2.ll17
-rw-r--r--test/Transforms/InstCombine/memcpy-from-global.ll10
-rw-r--r--test/Transforms/InstCombine/memmove-1.ll17
-rw-r--r--test/Transforms/InstCombine/memmove-2.ll17
-rw-r--r--test/Transforms/InstCombine/memset-1.ll17
-rw-r--r--test/Transforms/InstCombine/memset-2.ll17
-rw-r--r--test/Transforms/InstCombine/mul.ll2
-rw-r--r--test/Transforms/InstCombine/osx-names.ll (renamed from test/Transforms/SimplifyLibCalls/osx-names.ll)2
-rw-r--r--test/Transforms/InstCombine/pow-1.ll152
-rw-r--r--test/Transforms/InstCombine/pow-2.ll14
-rw-r--r--test/Transforms/InstCombine/pr12338.ll42
-rw-r--r--test/Transforms/InstCombine/printf-1.ll119
-rw-r--r--test/Transforms/InstCombine/printf-2.ll41
-rw-r--r--test/Transforms/InstCombine/puts-1.ll31
-rw-r--r--test/Transforms/InstCombine/sdiv-1.ll4
-rw-r--r--test/Transforms/InstCombine/shift.ll80
-rw-r--r--test/Transforms/InstCombine/signext.ll4
-rw-r--r--test/Transforms/InstCombine/sprintf-1.ll100
-rw-r--r--test/Transforms/InstCombine/strcspn-1.ll57
-rw-r--r--test/Transforms/InstCombine/strcspn-2.ll21
-rw-r--r--test/Transforms/InstCombine/strncmp-1.ll10
-rw-r--r--test/Transforms/InstCombine/strspn-1.ll56
-rw-r--r--test/Transforms/InstCombine/strstr-1.ll65
-rw-r--r--test/Transforms/InstCombine/strstr-2.ll18
-rw-r--r--test/Transforms/InstCombine/toascii-1.ll59
-rw-r--r--test/Transforms/InstCombine/vector_gep1.ll5
-rw-r--r--test/Transforms/InstCombine/vector_gep2.ll11
-rw-r--r--test/Transforms/InstCombine/xor2.ll31
-rw-r--r--test/Transforms/InstSimplify/compare.ll49
-rw-r--r--test/Transforms/InstSimplify/fast-math.ll35
-rw-r--r--test/Transforms/LoopIdiom/X86/lit.local.cfg6
-rw-r--r--test/Transforms/LoopIdiom/X86/popcnt.ll120
-rw-r--r--test/Transforms/LoopVectorize/X86/conversion-cost.ll4
-rw-r--r--test/Transforms/LoopVectorize/X86/cost-model.ll2
-rw-r--r--test/Transforms/LoopVectorize/gcc-examples.ll13
-rw-r--r--test/Transforms/LoopVectorize/if-conversion-reduction.ll38
-rw-r--r--test/Transforms/LoopVectorize/if-conversion.ll108
-rw-r--r--test/Transforms/LoopVectorize/intrinsic.ll851
-rw-r--r--test/Transforms/LoopVectorize/no_int_induction.ll33
-rw-r--r--test/Transforms/LoopVectorize/runtime-check.ll36
-rw-r--r--test/Transforms/Reassociate/crash.ll28
-rw-r--r--test/Transforms/SCCP/loadtest.ll5
-rw-r--r--test/Transforms/SROA/basictest.ll44
-rw-r--r--test/Transforms/SROA/big-endian.ll9
-rw-r--r--test/Transforms/SROA/phi-and-select.ll35
-rw-r--r--test/Transforms/SROA/vector-promotion.ll122
-rw-r--r--test/Transforms/SimplifyCFG/X86/lit.local.cfg6
-rw-r--r--test/Transforms/SimplifyCFG/X86/switch_to_lookup_table.ll (renamed from test/Transforms/SimplifyCFG/switch_to_lookup_table.ll)30
-rw-r--r--test/Transforms/SimplifyCFG/switch_create.ll5
-rw-r--r--test/Transforms/SimplifyLibCalls/FFS.ll45
-rw-r--r--test/Transforms/SimplifyLibCalls/FPrintF.ll28
-rw-r--r--test/Transforms/SimplifyLibCalls/FPuts.ll29
-rw-r--r--test/Transforms/SimplifyLibCalls/IsDigit.ll21
-rw-r--r--test/Transforms/SimplifyLibCalls/Printf.ll37
-rw-r--r--test/Transforms/SimplifyLibCalls/Puts.ll15
-rw-r--r--test/Transforms/SimplifyLibCalls/SPrintF.ll40
-rw-r--r--test/Transforms/SimplifyLibCalls/StrSpn.ll41
-rw-r--r--test/Transforms/SimplifyLibCalls/StrStr.ll60
-rw-r--r--test/Transforms/SimplifyLibCalls/ToAscii.ll21
-rw-r--r--test/Transforms/SimplifyLibCalls/abs.ll11
-rw-r--r--test/Transforms/SimplifyLibCalls/cos.ll14
-rw-r--r--test/Transforms/SimplifyLibCalls/exp2.ll38
-rw-r--r--test/Transforms/SimplifyLibCalls/floor.ll85
-rw-r--r--test/Transforms/SimplifyLibCalls/fwrite.ll13
-rw-r--r--test/Transforms/SimplifyLibCalls/iprintf.ll71
-rw-r--r--test/Transforms/SimplifyLibCalls/memcmp.ll35
-rw-r--r--test/Transforms/SimplifyLibCalls/memmove.ll12
-rw-r--r--test/Transforms/SimplifyLibCalls/memset-64.ll12
-rw-r--r--test/Transforms/SimplifyLibCalls/memset.ll12
-rw-r--r--test/Transforms/SimplifyLibCalls/pow-to-sqrt.ll33
-rw-r--r--test/Transforms/SimplifyLibCalls/pow2.ll37
113 files changed, 4563 insertions, 965 deletions
diff --git a/test/Transforms/BBVectorize/X86/cmp-types.ll b/test/Transforms/BBVectorize/X86/cmp-types.ll
new file mode 100644
index 0000000000..a4fcbb6048
--- /dev/null
+++ b/test/Transforms/BBVectorize/X86/cmp-types.ll
@@ -0,0 +1,16 @@
+target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128"
+target triple = "x86_64-unknown-linux-gnu"
+; RUN: opt < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=corei7 -bb-vectorize -S | FileCheck %s
+
+%"struct.btSoftBody" = type { float, float, float*, i8 }
+
+define void @test1(%"struct.btSoftBody"* %n1, %"struct.btSoftBody"* %n2) uwtable align 2 {
+entry:
+ %tobool15 = icmp ne %"struct.btSoftBody"* %n1, null
+ %cond16 = zext i1 %tobool15 to i32
+ %tobool21 = icmp ne %"struct.btSoftBody"* %n2, null
+ %cond22 = zext i1 %tobool21 to i32
+ ret void
+; CHECK: @test1
+}
+
diff --git a/test/Transforms/BBVectorize/X86/sh-rec.ll b/test/Transforms/BBVectorize/X86/sh-rec.ll
new file mode 100644
index 0000000000..1e0492c2a8
--- /dev/null
+++ b/test/Transforms/BBVectorize/X86/sh-rec.ll
@@ -0,0 +1,54 @@
+target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128"
+target triple = "x86_64-unknown-linux-gnu"
+; RUN: opt < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=corei7 -bb-vectorize -S | FileCheck %s
+
+define void @ptoa() nounwind uwtable {
+entry:
+ %call = call i8* @malloc() nounwind
+ br i1 undef, label %return, label %if.end10
+
+if.end10: ; preds = %entry
+ %incdec.ptr = getelementptr inbounds i8* %call, i64 undef
+ %call17 = call i32 @ptou() nounwind
+ %incdec.ptr26.1 = getelementptr inbounds i8* %incdec.ptr, i64 -2
+ store i8 undef, i8* %incdec.ptr26.1, align 1
+ %div27.1 = udiv i32 %call17, 100
+ %rem.2 = urem i32 %div27.1, 10
+ %add2230.2 = or i32 %rem.2, 48
+ %conv25.2 = trunc i32 %add2230.2 to i8
+ %incdec.ptr26.2 = getelementptr inbounds i8* %incdec.ptr, i64 -3
+ store i8 %conv25.2, i8* %incdec.ptr26.2, align 1
+ %incdec.ptr26.3 = getelementptr inbounds i8* %incdec.ptr, i64 -4
+ store i8 undef, i8* %incdec.ptr26.3, align 1
+ %div27.3 = udiv i32 %call17, 10000
+ %rem.4 = urem i32 %div27.3, 10
+ %add2230.4 = or i32 %rem.4, 48
+ %conv25.4 = trunc i32 %add2230.4 to i8
+ %incdec.ptr26.4 = getelementptr inbounds i8* %incdec.ptr, i64 -5
+ store i8 %conv25.4, i8* %incdec.ptr26.4, align 1
+ %div27.4 = udiv i32 %call17, 100000
+ %rem.5 = urem i32 %div27.4, 10
+ %add2230.5 = or i32 %rem.5, 48
+ %conv25.5 = trunc i32 %add2230.5 to i8
+ %incdec.ptr26.5 = getelementptr inbounds i8* %incdec.ptr, i64 -6
+ store i8 %conv25.5, i8* %incdec.ptr26.5, align 1
+ %incdec.ptr26.6 = getelementptr inbounds i8* %incdec.ptr, i64 -7
+ store i8 0, i8* %incdec.ptr26.6, align 1
+ %incdec.ptr26.7 = getelementptr inbounds i8* %incdec.ptr, i64 -8
+ store i8 undef, i8* %incdec.ptr26.7, align 1
+ %div27.7 = udiv i32 %call17, 100000000
+ %rem.8 = urem i32 %div27.7, 10
+ %add2230.8 = or i32 %rem.8, 48
+ %conv25.8 = trunc i32 %add2230.8 to i8
+ %incdec.ptr26.8 = getelementptr inbounds i8* %incdec.ptr, i64 -9
+ store i8 %conv25.8, i8* %incdec.ptr26.8, align 1
+ unreachable
+
+return: ; preds = %entry
+ ret void
+; CHECK: @ptoa
+}
+
+declare noalias i8* @malloc() nounwind
+
+declare i32 @ptou()
diff --git a/test/Transforms/BBVectorize/X86/sh-rec2.ll b/test/Transforms/BBVectorize/X86/sh-rec2.ll
new file mode 100644
index 0000000000..ef2239932f
--- /dev/null
+++ b/test/Transforms/BBVectorize/X86/sh-rec2.ll
@@ -0,0 +1,85 @@
+target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64: