summaryrefslogtreecommitdiff
path: root/test/CodeGen/Mips/i32k.ll
diff options
context:
space:
mode:
authorReed Kotler <rkotler@mips.com>2013-10-12 02:19:08 +0000
committerReed Kotler <rkotler@mips.com>2013-10-12 02:19:08 +0000
commit7f0125ba1950b8d7e32023fcada85c5adca1cd5a (patch)
treeb617939f85ac5154bdd9d10d9c66ab89572c802c /test/CodeGen/Mips/i32k.ll
parente3ba15c794839abe076e3e2bdf6c626396a19d4d (diff)
downloadllvm-7f0125ba1950b8d7e32023fcada85c5adca1cd5a.tar.gz
llvm-7f0125ba1950b8d7e32023fcada85c5adca1cd5a.tar.bz2
llvm-7f0125ba1950b8d7e32023fcada85c5adca1cd5a.tar.xz
For Mips16, start to consolidate all forms of 32 bit literal loading so that
they can be better handled and optimized in the Mips16 constant island code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192520 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/Mips/i32k.ll')
-rw-r--r--test/CodeGen/Mips/i32k.ll19
1 files changed, 13 insertions, 6 deletions
diff --git a/test/CodeGen/Mips/i32k.ll b/test/CodeGen/Mips/i32k.ll
index c6da8b1ac9..f4dd1eb78a 100644
--- a/test/CodeGen/Mips/i32k.ll
+++ b/test/CodeGen/Mips/i32k.ll
@@ -1,16 +1,23 @@
-; RUN: llc -march=mipsel -mcpu=mips16 -relocation-model=pic -O3 < %s | FileCheck %s -check-prefix=16a
-; RUN: llc -march=mipsel -mcpu=mips16 -relocation-model=pic -O3 < %s | FileCheck %s -check-prefix=16b
+; RUN: llc -mtriple=mipsel-linux-gnu -march=mipsel -mcpu=mips16 -relocation-model=pic -O3 < %s | FileCheck %s -check-prefix=16
@.str = private unnamed_addr constant [4 x i8] c"%i\0A\00", align 1
define i32 @main() nounwind {
entry:
%call = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8]* @.str, i32 0, i32 0), i32 1075344593) nounwind
-; 16a: li ${{[0-9]+}}, 29905
-; 16b: li ${{[0-9]+}}, 16408
+; 16: lw ${{[0-9]+}}, 1f
+; 16: b 2f
+; 16: .align 2
+; 16: 1: .word 1075344593
+; 16: 2:
+
%call1 = tail call i32 (i8*, ...)* @printf(i8* getelementptr inbounds ([4 x i8]* @.str, i32 0, i32 0), i32 -1075344593) nounwind
-; 16a: li ${{[0-9]+}}, 49127
-; 16b: li ${{[0-9]+}}, 35631
+
+; 16: lw ${{[0-9]+}}, 1f
+; 16: b 2f
+; 16: .align 2
+; 16: 1: .word -1075344593
+; 16: 2:
ret i32 0
}