aboutsummaryrefslogtreecommitdiffstats
path: root/test/CodeGen/Mips/2010-11-09-Mul.ll
diff options
context:
space:
mode:
authorBruno Cardoso Lopes <bruno.cardoso@gmail.com>2010-11-12 00:38:32 +0000
committerBruno Cardoso Lopes <bruno.cardoso@gmail.com>2010-11-12 00:38:32 +0000
commit7d5652dcd5371d086e2b24cb9c14a34b74481df8 (patch)
tree634e911efae75b1bfaf27d9763333ce313f6dcfc /test/CodeGen/Mips/2010-11-09-Mul.ll
parent97928d136a15b30954c4bf7d4b57ba62301a830e (diff)
downloadexternal_llvm-7d5652dcd5371d086e2b24cb9c14a34b74481df8.zip
external_llvm-7d5652dcd5371d086e2b24cb9c14a34b74481df8.tar.gz
external_llvm-7d5652dcd5371d086e2b24cb9c14a34b74481df8.tar.bz2
Enable mips32 mul instruction. Patch by Akira Hatanaka <ahatanaka@mips.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@118864 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/Mips/2010-11-09-Mul.ll')
-rw-r--r--test/CodeGen/Mips/2010-11-09-Mul.ll15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/CodeGen/Mips/2010-11-09-Mul.ll b/test/CodeGen/Mips/2010-11-09-Mul.ll
new file mode 100644
index 0000000..65a10b5
--- /dev/null
+++ b/test/CodeGen/Mips/2010-11-09-Mul.ll
@@ -0,0 +1,15 @@
+; RUN: llc -march=mips -mcpu=4ke < %s | FileCheck %s
+
+; CHECK: mul $2, $5, $4
+define i32 @mul1(i32 %a, i32 %b) nounwind readnone {
+entry:
+ %mul = mul i32 %b, %a
+ ret i32 %mul
+}
+
+; CHECK: mul $2, $5, $4
+define i32 @mul2(i32 %a, i32 %b) nounwind readnone {
+entry:
+ %mul = mul nsw i32 %b, %a
+ ret i32 %mul
+}