merge GHC HEAD
[ghc-hetmet.git] / compiler / nativeGen / PPC / Regs.hs
index d649d84..7a2a84b 100644 (file)
@@ -40,7 +40,6 @@ module PPC.Regs (
        -- horrow show
        freeReg,
        globalRegMaybe,
-       get_GlobalReg_reg_or_addr,
        allocatableRegs
 
 )
@@ -55,9 +54,8 @@ import Reg
 import RegClass
 import Size
 
-import CgUtils          ( get_GlobalReg_addr )
 import BlockId
-import Cmm
+import OldCmm
 import CLabel           ( CLabel )
 import Unique
 
@@ -211,7 +209,6 @@ spRel n     = AddrRegImm sp (ImmInt (n * wORD_SIZE))
 -- argRegs is the set of regs which are read for an n-argument call to C.
 -- For archs which pass all args on the stack (x86), is empty.
 -- Sparc passes up to the first 6 args in regs.
--- Dunno about Alpha.
 argRegs :: RegNo -> [Reg]
 argRegs 0 = []
 argRegs 1 = map regSingle [3]
@@ -595,20 +592,6 @@ globalRegMaybe _   = panic "PPC.Regs.globalRegMaybe: not defined"
 #endif /* powerpc_TARGET_ARCH */
 
 
--- We map STG registers onto appropriate CmmExprs.  Either they map
--- to real machine registers or stored as offsets from BaseReg.  Given
--- a GlobalReg, get_GlobalReg_reg_or_addr produces either the real
--- register it is in, on this platform, or a CmmExpr denoting the
--- address in the register table holding it.
--- (See also get_GlobalReg_addr in CgUtils.)
-
-get_GlobalReg_reg_or_addr :: GlobalReg -> Either Reg CmmExpr
-get_GlobalReg_reg_or_addr mid
-   = case globalRegMaybe mid of
-        Just rr -> Left rr
-        Nothing -> Right (get_GlobalReg_addr mid)
-
-
 -- allocatableRegs is allMachRegNos with the fixed-use regs removed.
 -- i.e., these are the regs for which we are prepared to allow the
 -- register allocator to attempt to map VRegs to.