aboutsummaryrefslogtreecommitdiffstats
path: root/test/CodeGen/Thumb2/load-global.ll
diff options
context:
space:
mode:
authorDavid Goodwin <david_goodwin@apple.com>2009-07-01 00:01:13 +0000
committerDavid Goodwin <david_goodwin@apple.com>2009-07-01 00:01:13 +0000
commitd1fa120aeec67e94e6ed6056593ccb630fe2db0e (patch)
tree43dab5d1dfd23fa4c5088c600effaa9e89d6051e /test/CodeGen/Thumb2/load-global.ll
parentdb47ed0925ce97f3134189c96ebc35b2cdae1ce3 (diff)
downloadexternal_llvm-d1fa120aeec67e94e6ed6056593ccb630fe2db0e.tar.gz
external_llvm-d1fa120aeec67e94e6ed6056593ccb630fe2db0e.tar.bz2
external_llvm-d1fa120aeec67e94e6ed6056593ccb630fe2db0e.zip
Add PIC load and store patterns for Thumb-2.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74577 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/Thumb2/load-global.ll')
-rw-r--r--test/CodeGen/Thumb2/load-global.ll14
1 files changed, 12 insertions, 2 deletions
diff --git a/test/CodeGen/Thumb2/load-global.ll b/test/CodeGen/Thumb2/load-global.ll
index 0ffcb9575d..1b1fe7b1b5 100644
--- a/test/CodeGen/Thumb2/load-global.ll
+++ b/test/CodeGen/Thumb2/load-global.ll
@@ -1,5 +1,15 @@
-; RUN: llvm-as < %s | llc -mtriple=thumbv7-apple-darwin
-; RUN: llvm-as < %s | llc -mtriple=thumbv7-apple-darwin -relocation-model=pic | grep add | grep pc
+; RUN: llvm-as < %s | \
+; RUN: llc -mtriple=thumbv7-apple-darwin -relocation-model=static | \
+; RUN: not grep {L_G\$non_lazy_ptr}
+; RUN: llvm-as < %s | \
+; RUN: llc -mtriple=thumbv7-apple-darwin -relocation-model=dynamic-no-pic | \
+; RUN: grep {L_G\$non_lazy_ptr} | count 2
+; RUN: llvm-as < %s | \
+; RUN: llc -mtriple=thumbv7-apple-darwin -relocation-model=pic | \
+; RUN: grep {ldr.*pc} | count 1
+; RUN: llvm-as < %s | \
+; RUN: llc -mtriple=thumbv7-linux-gnueabi -relocation-model=pic | \
+; RUN: grep {GOT} | count 1
@G = external global i32