diff --git a/test/CodeGen/Generic/addc-fold2.ll b/test/CodeGen/Generic/addc-fold2.ll new file mode 100644 index 00000000000..72cc0f63b4c --- /dev/null +++ b/test/CodeGen/Generic/addc-fold2.ll @@ -0,0 +1,11 @@ +; RUN: llvm-as < %s | llc && +; RUN: llvm-as < %s | llc -march=x86 | grep 'add' && +; RUN: llvm-as < %s | llc -march=x86 | not grep 'adc' + +define i64 @test(i64 %A, i32 %B) { + %tmp12 = zext i32 %B to i64 ; [#uses=1] + %tmp3 = shl i64 %tmp12, 32 ; [#uses=1] + %tmp5 = add i64 %tmp3, %A ; [#uses=1] + ret i64 %tmp5 +} +