patch applied (ghc): Moved global register saving from the backend to codeGen

Simon Marlow simonmar at microsoft.com
Tue Jul 3 10:43:06 EDT 2007


Fri May 25 12:38:04 PDT 2007  Michael D. Adams <t-madams at microsoft.com>
  * Moved global register saving from the backend to codeGen
  
  This frees the Cmm data type from keeping a list of live global registers
  in CmmCall which helps prepare for the CPS conversion phase.
  
  CPS conversion does its own liveness analysis and takes input that should
  not directly refer to parameter registers (e.g. R1, F5, D3, L2).  Since
  these are the only things which could occur in the live global register
  list, CPS conversion makes that field of the CmmCall constructor obsolite.
  
  Once the CPS conversion pass is fully implemented, global register saving
  will move from codeGen into the CPS pass.  Until then, this patch
  is worth scrutinizing and testing to ensure it doesn't cause any performance
  or correctness problems as the code passed to the backends by the CPS
  converting will look very similar to the code that this patch makes codeGen
  pass to the backend.

    M ./compiler/cmm/Cmm.hs -4
    M ./compiler/cmm/CmmLint.hs -1 +1
    M ./compiler/cmm/CmmOpt.hs -3 +3
    M ./compiler/cmm/PprC.hs -21 +9
    M ./compiler/cmm/PprCmm.hs -3 +3
    M ./compiler/codeGen/CgForeignCall.hs -5 +14
    M ./compiler/codeGen/CgUtils.hs -1 +11
    M ./compiler/nativeGen/AsmCodeGen.lhs -9 +4
    M ./compiler/nativeGen/MachCodeGen.hs -17 +16
    M ./compiler/nativeGen/MachRegs.lhs +4



More information about the Cvs-ghc mailing list