summaryrefslogtreecommitdiffstats
path: root/llvm/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
commit86c7e20ca6aaa4049dd2be489bbd8f5acecf95e6 (patch)
treedc08259948610d03ab8b5241df45c9022d86ce61 /llvm/test/CodeGen/Thumb2/load-global.ll
parent89026b501810331593b0704b88c99936588af181 (diff)
downloadbcm5719-llvm-86c7e20ca6aaa4049dd2be489bbd8f5acecf95e6.tar.gz
bcm5719-llvm-86c7e20ca6aaa4049dd2be489bbd8f5acecf95e6.zip
Add PIC load and store patterns for Thumb-2.
llvm-svn: 74577
Diffstat (limited to 'llvm/test/CodeGen/Thumb2/load-global.ll')
-rw-r--r--llvm/test/CodeGen/Thumb2/load-global.ll14
1 files changed, 12 insertions, 2 deletions
diff --git a/llvm/test/CodeGen/Thumb2/load-global.ll b/llvm/test/CodeGen/Thumb2/load-global.ll
index 0ffcb9575d5..1b1fe7b1b5f 100644
--- a/llvm/test/CodeGen/Thumb2/load-global.ll
+++ b/llvm/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
OpenPOWER on IntegriCloud