diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2006-10-16 16:33:29 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2006-10-16 16:33:29 +0000 |
commit | bec2e38a9156aa35a200914a700de1e8d0810d80 (patch) | |
tree | a79aa753d1de31bddd2481898fa5bae508c1ed38 /test | |
parent | d9b8e40ab3b51fa49f0c35cccb2bd795a786162b (diff) |
implement smull and umull
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30975 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r-- | test/CodeGen/ARM/long.ll | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/test/CodeGen/ARM/long.ll b/test/CodeGen/ARM/long.ll index c01a4cb613..834f068710 100644 --- a/test/CodeGen/ARM/long.ll +++ b/test/CodeGen/ARM/long.ll @@ -7,7 +7,9 @@ ; RUN: llvm-as < %s | llc -march=arm | grep "adds" | wc -l | grep 1 && ; RUN: llvm-as < %s | llc -march=arm | grep "adcs" | wc -l | grep 1 && ; RUN: llvm-as < %s | llc -march=arm | grep "subs" | wc -l | grep 1 && -; RUN: llvm-as < %s | llc -march=arm | grep "sbcs" | wc -l | grep 1 +; RUN: llvm-as < %s | llc -march=arm | grep "sbcs" | wc -l | grep 1 && +; RUN: llvm-as < %s | llc -march=arm | grep "smull" | wc -l | grep 1 && +; RUN: llvm-as < %s | llc -march=arm | grep "umull" | wc -l | grep 1 long %f1() { entry: @@ -52,3 +54,19 @@ entry: %tmp = sub long %a, %b ret long %tmp } + +long %f(int %a, int %b) { +entry: + %tmp = cast int %a to long + %tmp1 = cast int %b to long + %tmp2 = mul long %tmp1, %tmp + ret long %tmp2 +} + +ulong %g(uint %a, uint %b) { +entry: + %tmp = cast uint %a to ulong + %tmp1 = cast uint %b to ulong + %tmp2 = mul ulong %tmp1, %tmp + ret ulong %tmp2 +} |