[commit: ghc] master: PPC NCG: Make calling convention more general (64020fe)
git at git.haskell.org
git at git.haskell.org
Fri Jan 18 01:42:40 UTC 2019
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/64020feaee79aa27716aa9cb0cd457d8c8394682/ghc
>---------------------------------------------------------------
commit 64020feaee79aa27716aa9cb0cd457d8c8394682
Author: Peter Trommler <ptrommler at acm.org>
Date: Fri Dec 28 23:52:31 2018 +0100
PPC NCG: Make calling convention more general
All operating systems except AIX and Darwin follow the ELF
specification.
>---------------------------------------------------------------
64020feaee79aa27716aa9cb0cd457d8c8394682
compiler/nativeGen/PPC/CodeGen.hs | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)
diff --git a/compiler/nativeGen/PPC/CodeGen.hs b/compiler/nativeGen/PPC/CodeGen.hs
index bbc3411..5586e0e 100644
--- a/compiler/nativeGen/PPC/CodeGen.hs
+++ b/compiler/nativeGen/PPC/CodeGen.hs
@@ -1570,13 +1570,12 @@ data GenCCallPlatform = GCPLinux | GCPLinux64ELF !Int | GCPAIX
platformToGCP :: Platform -> GenCCallPlatform
platformToGCP platform = case platformOS platform of
- OSLinux -> case platformArch platform of
- ArchPPC -> GCPLinux
- ArchPPC_64 ELF_V1 -> GCPLinux64ELF 1
- ArchPPC_64 ELF_V2 -> GCPLinux64ELF 2
- _ -> panic "PPC.CodeGen.platformToGCP: Unknown Linux"
OSAIX -> GCPAIX
- _ -> panic "PPC.CodeGen.platformToGCP: not defined for this OS"
+ _ -> case platformArch platform of
+ ArchPPC -> GCPLinux
+ ArchPPC_64 ELF_V1 -> GCPLinux64ELF 1
+ ArchPPC_64 ELF_V2 -> GCPLinux64ELF 2
+ _ -> panic "platformToGCP: Not PowerPC"
genCCall'
More information about the ghc-commits
mailing list