diff options
author | Peter Trommler <ptrommler@acm.org> | 2018-12-11 16:43:49 +0100 |
---|---|---|
committer | Peter Trommler <ptrommler@acm.org> | 2019-02-27 19:09:38 +0100 |
commit | 9758dcadac31f9c9a0b4e84acaaabdc8c99fcdf1 (patch) | |
tree | ed4ae7e3d7c9fec308e7646623fb046ebe01e158 /compiler/nativeGen/PPC/Ppr.hs | |
parent | 2e8f664957dc3763dc4375894b8dc4d046d2e95b (diff) | |
download | haskell-wip/ppc-reg-alloc.tar.gz |
PPC NCG: Use liveness information in CmmCallwip/ppc-reg-alloc
We make liveness information for global registers
available on `JMP` and `BCTR`, which were the last instructions
missing. With complete liveness information we do not need to
reserve global registers in `freeReg` anymore and moreover
assign R9 and R10 and HpLim to callee save registers. We change
the calling convention so R1 to R10 occupy a contiguous range
of registers.
Cleanup by removing `Reg_Su`, which was unused, from `freeReg`
and removing unused register definitions.
The calculation of the number of floating point registers is too
conservative. Just follow X86 and specify the constants directly.
Overall this results in 0.3 % smaller code size in nofib while
runtime is sligtly better in some tests.
Diffstat (limited to 'compiler/nativeGen/PPC/Ppr.hs')
-rw-r--r-- | compiler/nativeGen/PPC/Ppr.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/nativeGen/PPC/Ppr.hs b/compiler/nativeGen/PPC/Ppr.hs index c54d4430eb..f45c8b2bda 100644 --- a/compiler/nativeGen/PPC/Ppr.hs +++ b/compiler/nativeGen/PPC/Ppr.hs @@ -551,7 +551,7 @@ pprInstr (BCCFAR cond blockid prediction) = vcat [ Just True -> char '-' Just False -> char '+' -pprInstr (JMP lbl) +pprInstr (JMP lbl _) -- We never jump to ForeignLabels; if we ever do, c.f. handling for "BL" | isForeignLabel lbl = panic "PPC.Ppr.pprInstr: JMP to ForeignLabel" | otherwise = @@ -568,7 +568,7 @@ pprInstr (MTCTR reg) = hcat [ char '\t', pprReg reg ] -pprInstr (BCTR _ _) = hcat [ +pprInstr (BCTR _ _ _) = hcat [ char '\t', text "bctr" ] |