For PR950:
The long awaited CAST patch. This introduces 12 new instructions into LLVM
to replace the cast instruction. Corresponding changes throughout LLVM are
provided. This passes llvm-test, llvm/test, and SPEC CPUINT2000 with the
exception of 175.vpr which fails only on a slight floating point output
difference.
llvm-svn: 31931
diff --git a/llvm/test/Regression/Transforms/InstCombine/zext.ll b/llvm/test/Regression/Transforms/InstCombine/zext.ll
new file mode 100644
index 0000000..27442aa
--- /dev/null
+++ b/llvm/test/Regression/Transforms/InstCombine/zext.ll
@@ -0,0 +1,9 @@
+; Tests to make sure elimination of casts is working correctly
+; RUN: llvm-as < %s | opt -instcombine -disable-output &&
+; RUN: llvm-as < %s | opt -instcombine | llvm-dis | notcast '' '%c1.*'
+
+long %test_sext_zext(short %A) {
+ %c1 = zext short %A to uint
+ %c2 = sext uint %c1 to long
+ ret long %c2
+}