summaryrefslogtreecommitdiff
path: root/test/CodeGen/PowerPC/mcm-3.ll
diff options
context:
space:
mode:
authorBill Schmidt <wschmidt@linux.vnet.ibm.com>2013-09-17 20:03:25 +0000
committerBill Schmidt <wschmidt@linux.vnet.ibm.com>2013-09-17 20:03:25 +0000
commit5bd1dfa2b5deab10a1a7a5a4ba117c28d878595d (patch)
treec313e49febb06d1386268c994f38b7284c782e57 /test/CodeGen/PowerPC/mcm-3.ll
parent65457b679ae240c1a37da82c5484dac478c47b6d (diff)
downloadllvm-5bd1dfa2b5deab10a1a7a5a4ba117c28d878595d.tar.gz
llvm-5bd1dfa2b5deab10a1a7a5a4ba117c28d878595d.tar.bz2
llvm-5bd1dfa2b5deab10a1a7a5a4ba117c28d878595d.tar.xz
[PowerPC] Fix problems with large code model (PR17169).
Large code model on PPC64 requires creating and referencing TOC entries when using the addis/ld form of addressing. This was not being done in all cases. The changes in this patch to PPCAsmPrinter::EmitInstruction() fix this. Two test cases are also modified to reflect this requirement. Fast-isel was not creating correct code for loading floating-point constants using large code model. This also requires the addis/ld form of addressing. Previously we were using the addis/lfd shortcut which is only applicable to medium code model. One test case is modified to reflect this requirement. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@190882 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/PowerPC/mcm-3.ll')
-rw-r--r--test/CodeGen/PowerPC/mcm-3.ll8
1 files changed, 5 insertions, 3 deletions
diff --git a/test/CodeGen/PowerPC/mcm-3.ll b/test/CodeGen/PowerPC/mcm-3.ll
index ce151fbf57..b6d681d580 100644
--- a/test/CodeGen/PowerPC/mcm-3.ll
+++ b/test/CodeGen/PowerPC/mcm-3.ll
@@ -33,9 +33,11 @@ entry:
; LARGE: ld [[REG2:[0-9]+]], [[VAR]]@toc@l([[REG1]])
; LARGE: lwz {{[0-9]+}}, 0([[REG2]])
; LARGE: stw {{[0-9]+}}, 0([[REG2]])
-; LARGE: .type [[VAR]],@object
-; LARGE: .data
-; LARGE: .globl [[VAR]]
; LARGE: [[VAR]]:
+; LARGE: .tc [[VAR2:[a-z0-9A-Z_.]+]][TC],[[VAR2]]
+; LARGE: .type [[VAR2]],@object
+; LARGE: .data
+; LARGE: .globl [[VAR2]]
+; LARGE: [[VAR2]]:
; LARGE: .long 5