diff options
Diffstat (limited to 'compiler/codeGen/CodeGen')
-rw-r--r-- | compiler/codeGen/CodeGen/Platform.hs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/compiler/codeGen/CodeGen/Platform.hs b/compiler/codeGen/CodeGen/Platform.hs index 2ed99833a9..78fba978ec 100644 --- a/compiler/codeGen/CodeGen/Platform.hs +++ b/compiler/codeGen/CodeGen/Platform.hs @@ -17,6 +17,8 @@ import qualified CodeGen.Platform.NoRegs as NoRegs callerSaves :: Platform -> GlobalReg -> Bool callerSaves platform + | platformUnregisterised platform = NoRegs.callerSaves + | otherwise = case platformArch platform of ArchX86 -> X86.callerSaves ArchX86_64 -> X86_64.callerSaves @@ -37,6 +39,8 @@ callerSaves platform -- possbily mapped to real registers. activeStgRegs :: Platform -> [GlobalReg] activeStgRegs platform + | platformUnregisterised platform = NoRegs.activeStgRegs + | otherwise = case platformArch platform of ArchX86 -> X86.activeStgRegs ArchX86_64 -> X86_64.activeStgRegs @@ -52,6 +56,8 @@ activeStgRegs platform haveRegBase :: Platform -> Bool haveRegBase platform + | platformUnregisterised platform = NoRegs.haveRegBase + | otherwise = case platformArch platform of ArchX86 -> X86.haveRegBase ArchX86_64 -> X86_64.haveRegBase |