summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Trommler <ptrommler@acm.org>2018-12-29 10:12:48 +0100
committerPeter Trommler <ptrommler@acm.org>2019-01-15 12:58:23 -0500
commit8b5e50eb3c2920c3126ea0d9512518f6557bd20a (patch)
tree351de5ca402fc3e89760b37b93e6735dcdb4699f
parent753d27aad73725b46b81fb4f69956e50f9d1870c (diff)
downloadhaskell-8b5e50eb3c2920c3126ea0d9512518f6557bd20a.tar.gz
PPC NCG: GOT declaration for all 64-bit ELF systems
-rw-r--r--compiler/nativeGen/PIC.hs8
1 files changed, 3 insertions, 5 deletions
diff --git a/compiler/nativeGen/PIC.hs b/compiler/nativeGen/PIC.hs
index 7778729368..280a87e786 100644
--- a/compiler/nativeGen/PIC.hs
+++ b/compiler/nativeGen/PIC.hs
@@ -527,19 +527,17 @@ pprGotDeclaration _ _ OSAIX
]
--- PPC 64 ELF v1 needs a Table Of Contents (TOC) on Linux
-pprGotDeclaration _ (ArchPPC_64 ELF_V1) OSLinux
+-- PPC 64 ELF v1 needs a Table Of Contents (TOC)
+pprGotDeclaration _ (ArchPPC_64 ELF_V1) _
= text ".section \".toc\",\"aw\""
-- In ELF v2 we also need to tell the assembler that we want ABI
-- version 2. This would normally be done at the top of the file
-- right after a file directive, but I could not figure out how
-- to do that.
-pprGotDeclaration _ (ArchPPC_64 ELF_V2) OSLinux
+pprGotDeclaration _ (ArchPPC_64 ELF_V2) _
= vcat [ text ".abiversion 2",
text ".section \".toc\",\"aw\""
]
-pprGotDeclaration _ (ArchPPC_64 _) _
- = panic "pprGotDeclaration: ArchPPC_64 only Linux supported"
-- Emit GOT declaration
-- Output whatever needs to be output once per .s file.