diff options
author | Ben Gamari <ben@smart-cactus.org> | 2022-01-26 22:32:19 -0500 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2022-01-29 14:52:56 -0500 |
commit | ea2a403451caa15beca77af42fe0c34e7f1d7dc4 (patch) | |
tree | 48002eb2a8fa1da9ac2c555fd76e83e2db642701 /compiler | |
parent | 88fea6aaecc8818d370d2e6952df6549484eb108 (diff) | |
download | haskell-ea2a403451caa15beca77af42fe0c34e7f1d7dc4.tar.gz |
CmmToAsm: Drop ncgExpandTop
This was only needed for SPARC's synthetic instructions.
Diffstat (limited to 'compiler')
-rw-r--r-- | compiler/GHC/CmmToAsm.hs | 15 | ||||
-rw-r--r-- | compiler/GHC/CmmToAsm/AArch64.hs | 1 | ||||
-rw-r--r-- | compiler/GHC/CmmToAsm/Monad.hs | 1 | ||||
-rw-r--r-- | compiler/GHC/CmmToAsm/PPC.hs | 1 | ||||
-rw-r--r-- | compiler/GHC/CmmToAsm/X86.hs | 1 | ||||
-rw-r--r-- | compiler/GHC/Driver/Flags.hs | 1 | ||||
-rw-r--r-- | compiler/GHC/Driver/Session.hs | 2 |
7 files changed, 2 insertions, 20 deletions
diff --git a/compiler/GHC/CmmToAsm.hs b/compiler/GHC/CmmToAsm.hs index d59f716e95..e7a392d822 100644 --- a/compiler/GHC/CmmToAsm.hs +++ b/compiler/GHC/CmmToAsm.hs @@ -669,29 +669,18 @@ cmmNativeGen logger modLoc ncgImpl us fileIds dbgMap cmm count invert (CmmProc info lbl live (ListGraph blocks)) = CmmProc info lbl live (ListGraph $ invertConds info blocks) - ---- expansion of SPARC synthetic instrs - let expanded = - {-# SCC "sparc_expand" #-} - ncgExpandTop ncgImpl branchOpt - --ncgExpandTop ncgImpl sequenced - - putDumpFileMaybe logger - Opt_D_dump_asm_expanded "Synthetic instructions expanded" - FormatCMM - (vcat $ map (pprNatCmmDecl ncgImpl) expanded) - -- generate unwinding information from cmm let unwinds :: BlockMap [UnwindPoint] unwinds = {-# SCC "unwindingInfo" #-} - foldl' addUnwind mapEmpty expanded + foldl' addUnwind mapEmpty branchOpt where addUnwind acc proc = acc `mapUnion` computeUnwinding config ncgImpl proc return ( usAlloc , fileIds' - , expanded + , branchOpt , lastMinuteImports ++ imports , ppr_raStatsColor , ppr_raStatsLinear diff --git a/compiler/GHC/CmmToAsm/AArch64.hs b/compiler/GHC/CmmToAsm/AArch64.hs index 14f4b5d0bd..e6f656e26a 100644 --- a/compiler/GHC/CmmToAsm/AArch64.hs +++ b/compiler/GHC/CmmToAsm/AArch64.hs @@ -32,7 +32,6 @@ ncgAArch64 config ,maxSpillSlots = AArch64.maxSpillSlots config ,allocatableRegs = AArch64.allocatableRegs platform ,ncgAllocMoreStack = AArch64.allocMoreStack platform - ,ncgExpandTop = id ,ncgMakeFarBranches = const id ,extractUnwindPoints = const [] ,invertCondBranches = \_ _ -> id diff --git a/compiler/GHC/CmmToAsm/Monad.hs b/compiler/GHC/CmmToAsm/Monad.hs index fa6a8706a1..5ae6785706 100644 --- a/compiler/GHC/CmmToAsm/Monad.hs +++ b/compiler/GHC/CmmToAsm/Monad.hs @@ -82,7 +82,6 @@ data NcgImpl statics instr jumpDest = NcgImpl { pprNatCmmDecl :: NatCmmDecl statics instr -> SDoc, maxSpillSlots :: Int, allocatableRegs :: [RealReg], - ncgExpandTop :: [NatCmmDecl statics instr] -> [NatCmmDecl statics instr], ncgAllocMoreStack :: Int -> NatCmmDecl statics instr -> UniqSM (NatCmmDecl statics instr, [(BlockId,BlockId)]), -- ^ The list of block ids records the redirected jumps to allow us to update diff --git a/compiler/GHC/CmmToAsm/PPC.hs b/compiler/GHC/CmmToAsm/PPC.hs index 01d479d1c5..cbfbdb539c 100644 --- a/compiler/GHC/CmmToAsm/PPC.hs +++ b/compiler/GHC/CmmToAsm/PPC.hs @@ -32,7 +32,6 @@ ncgPPC config = NcgImpl , maxSpillSlots = PPC.maxSpillSlots config , allocatableRegs = PPC.allocatableRegs platform , ncgAllocMoreStack = PPC.allocMoreStack platform - , ncgExpandTop = id , ncgMakeFarBranches = PPC.makeFarBranches , extractUnwindPoints = const [] , invertCondBranches = \_ _ -> id diff --git a/compiler/GHC/CmmToAsm/X86.hs b/compiler/GHC/CmmToAsm/X86.hs index 4b2f4dfaf2..91b571f4de 100644 --- a/compiler/GHC/CmmToAsm/X86.hs +++ b/compiler/GHC/CmmToAsm/X86.hs @@ -37,7 +37,6 @@ ncgX86_64 config = NcgImpl , maxSpillSlots = X86.maxSpillSlots config , allocatableRegs = X86.allocatableRegs platform , ncgAllocMoreStack = X86.allocMoreStack platform - , ncgExpandTop = id , ncgMakeFarBranches = const id , extractUnwindPoints = X86.extractUnwindPoints , invertCondBranches = X86.invertCondBranches diff --git a/compiler/GHC/Driver/Flags.hs b/compiler/GHC/Driver/Flags.hs index ce68014d2d..df833b03d1 100644 --- a/compiler/GHC/Driver/Flags.hs +++ b/compiler/GHC/Driver/Flags.hs @@ -69,7 +69,6 @@ data DumpFlag | Opt_D_dump_asm_regalloc_stages | Opt_D_dump_asm_conflicts | Opt_D_dump_asm_stats - | Opt_D_dump_asm_expanded | Opt_D_dump_c_backend | Opt_D_dump_llvm | Opt_D_dump_core_stats diff --git a/compiler/GHC/Driver/Session.hs b/compiler/GHC/Driver/Session.hs index 02b1a637ff..2e7574837f 100644 --- a/compiler/GHC/Driver/Session.hs +++ b/compiler/GHC/Driver/Session.hs @@ -2425,8 +2425,6 @@ dynamic_flags_deps = [ (setDumpFlag Opt_D_dump_asm_regalloc_stages) , make_ord_flag defGhcFlag "ddump-asm-stats" (setDumpFlag Opt_D_dump_asm_stats) - , make_ord_flag defGhcFlag "ddump-asm-expanded" - (setDumpFlag Opt_D_dump_asm_expanded) , make_ord_flag defGhcFlag "ddump-llvm" (NoArg $ setObjBackend LLVM >> setDumpFlag' Opt_D_dump_llvm) , make_ord_flag defGhcFlag "ddump-c-backend" |