diff options
| author | Ed Schouten <ed@FreeBSD.org> | 2009-06-27 10:44:33 +0000 |
|---|---|---|
| committer | Ed Schouten <ed@FreeBSD.org> | 2009-06-27 10:44:33 +0000 |
| commit | f859468f5a21b6952ab62917777f9fb3bba57003 (patch) | |
| tree | 9794dc36f22f2a2b3f8063829d8a9b3a7794acc8 /test/CodeGen/ARM/carry.ll | |
| parent | f76359690a7035ad21498f2ba6be6991d3b2032d (diff) | |
Diffstat (limited to 'test/CodeGen/ARM/carry.ll')
| -rw-r--r-- | test/CodeGen/ARM/carry.ll | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/test/CodeGen/ARM/carry.ll b/test/CodeGen/ARM/carry.ll new file mode 100644 index 000000000000..3bf2dc0b4f03 --- /dev/null +++ b/test/CodeGen/ARM/carry.ll @@ -0,0 +1,16 @@ +; RUN: llvm-as < %s | llc -march=arm | grep "subs r" | count 2 +; RUN: llvm-as < %s | llc -march=arm | grep "adc r" +; RUN: llvm-as < %s | llc -march=arm | grep "sbc r" | count 2 + +define i64 @f1(i64 %a, i64 %b) { +entry: + %tmp = sub i64 %a, %b + ret i64 %tmp +} + +define i64 @f2(i64 %a, i64 %b) { +entry: + %tmp1 = shl i64 %a, 1 + %tmp2 = sub i64 %tmp1, %b + ret i64 %tmp2 +} |
