summaryrefslogtreecommitdiff
path: root/test/CodeGen/ARM/t2-imm.ll
diff options
context:
space:
mode:
authorAnton Korobeynikov <asl@math.spbu.ru>2009-09-27 23:52:58 +0000
committerAnton Korobeynikov <asl@math.spbu.ru>2009-09-27 23:52:58 +0000
commit6a2fa325c1763a0fb27eceaa78b3a9bf683416bf (patch)
tree6f1b31c52cf85ce37ae6a044454cf75fb9b39d0d /test/CodeGen/ARM/t2-imm.ll
parent1edaef62a4a0e6166ab30a54150bca2362ad1c5e (diff)
downloadllvm-6a2fa325c1763a0fb27eceaa78b3a9bf683416bf.tar.gz
llvm-6a2fa325c1763a0fb27eceaa78b3a9bf683416bf.tar.bz2
llvm-6a2fa325c1763a0fb27eceaa78b3a9bf683416bf.tar.xz
Use movt/movw pair to materialize 32 bit constants on ARMv6T2+.
This should be better than single load from constpool. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82948 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/ARM/t2-imm.ll')
-rw-r--r--test/CodeGen/ARM/t2-imm.ll9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/CodeGen/ARM/t2-imm.ll b/test/CodeGen/ARM/t2-imm.ll
new file mode 100644
index 0000000000..8b619bfef3
--- /dev/null
+++ b/test/CodeGen/ARM/t2-imm.ll
@@ -0,0 +1,9 @@
+; RUN: llc < %s -march=arm -mattr=+thumb2 | FileCheck %s
+
+define i32 @f6(i32 %a) {
+; CHECK:f6
+; CHECK: movw r0, #1123
+; CHECK: movt r0, #1000
+ %tmp = add i32 0, 65537123
+ ret i32 %tmp
+}