[commit: ghc] master: Remove dead code (a8a0764)

git at git.haskell.org git at git.haskell.org
Tue Sep 10 11:48:58 CEST 2013


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/a8a0764a2670dd46603e8f4c02c8ed35e5011535/ghc

>---------------------------------------------------------------

commit a8a0764a2670dd46603e8f4c02c8ed35e5011535
Author: Jan Stolarek <jan.stolarek at p.lodz.pl>
Date:   Mon Sep 9 16:11:53 2013 +0100

    Remove dead code


>---------------------------------------------------------------

a8a0764a2670dd46603e8f4c02c8ed35e5011535
 compiler/cmm/CmmCallConv.hs              |    8 +-------
 compiler/nativeGen/SPARC/CodeGen/Base.hs |    1 +
 compiler/nativeGen/X86/Regs.hs           |    7 -------
 3 files changed, 2 insertions(+), 14 deletions(-)

diff --git a/compiler/cmm/CmmCallConv.hs b/compiler/cmm/CmmCallConv.hs
index eeca0b4..3549933 100644
--- a/compiler/cmm/CmmCallConv.hs
+++ b/compiler/cmm/CmmCallConv.hs
@@ -3,7 +3,7 @@ module CmmCallConv (
   ParamLocation(..),
   assignArgumentsPos,
   assignStack,
-  globalArgRegs, realArgRegsCover
+  realArgRegsCover
 ) where
 
 #include "HsVersions.h"
@@ -173,12 +173,6 @@ allRegs dflags = (allVanillaRegs dflags,
 nodeOnly :: AvailRegs
 nodeOnly = ([VanillaReg 1], [], [], [], [])
 
-globalArgRegs :: DynFlags -> [GlobalReg]
-globalArgRegs dflags = map ($ VGcPtr) (allVanillaRegs dflags) ++
-                       allFloatRegs dflags ++
-                       allDoubleRegs dflags ++
-                       allLongRegs dflags
-
 -- This returns the set of global registers that *cover* the machine registers
 -- used for argument passing. On platforms where registers can overlap---right
 -- now just x86-64, where Float and Double registers overlap---passing this set
diff --git a/compiler/nativeGen/SPARC/CodeGen/Base.hs b/compiler/nativeGen/SPARC/CodeGen/Base.hs
index 16384f1..5ad2ff0 100644
--- a/compiler/nativeGen/SPARC/CodeGen/Base.hs
+++ b/compiler/nativeGen/SPARC/CodeGen/Base.hs
@@ -31,6 +31,7 @@ import Reg
 import CodeGen.Platform
 import DynFlags
 import Cmm
+import PprCmmExpr ()
 import Platform
 
 import Outputable
diff --git a/compiler/nativeGen/X86/Regs.hs b/compiler/nativeGen/X86/Regs.hs
index bd60fb0..b5139c9 100644
--- a/compiler/nativeGen/X86/Regs.hs
+++ b/compiler/nativeGen/X86/Regs.hs
@@ -17,7 +17,6 @@ module X86.Regs (
         argRegs,
         allArgRegs,
         allIntArgRegs,
-        allHaskellArgRegs,
         callClobberedRegs,
         instrClobberedRegs,
         allMachRegNos,
@@ -52,7 +51,6 @@ import Reg
 import RegClass
 
 import Cmm
-import CmmCallConv
 import CLabel           ( CLabel )
 import DynFlags
 import Outputable
@@ -439,11 +437,6 @@ instrClobberedRegs platform
 
 --
 
--- All machine registers that are used for argument-passing to Haskell functions
-allHaskellArgRegs :: DynFlags -> [Reg]
-allHaskellArgRegs dflags = [ RegReal r | Just r <- map (globalRegMaybe platform) (globalArgRegs dflags) ]
-    where platform = targetPlatform dflags
-
 -- 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.




More information about the ghc-commits mailing list