summaryrefslogtreecommitdiff
path: root/compiler/GHC/CmmToAsm/SPARC/CodeGen.hs
diff options
context:
space:
mode:
authorSylvain Henry <sylvain@haskus.fr>2020-03-31 18:49:01 +0200
committerMarge Bot <ben+marge-bot@smart-cactus.org>2020-04-03 06:26:54 -0400
commitcc2918a0407e1581e824ebd90a1fcbb0637d5744 (patch)
tree42cdc286b9b2557252f59db47373305c1cfc9c36 /compiler/GHC/CmmToAsm/SPARC/CodeGen.hs
parenta485c3c4049fff09e989bfd7d2ba47035c92a69b (diff)
downloadhaskell-cc2918a0407e1581e824ebd90a1fcbb0637d5744.tar.gz
Refactor CmmStatics
In !2959 we noticed that there was some redundant code (in GHC.Cmm.Utils and GHC.Cmm.StgToCmm.Utils) used to deal with `CmmStatics` datatype (before SRT generation) and `RawCmmStatics` datatype (after SRT generation). This patch removes this redundant code by using a single GADT for (Raw)CmmStatics.
Diffstat (limited to 'compiler/GHC/CmmToAsm/SPARC/CodeGen.hs')
-rw-r--r--compiler/GHC/CmmToAsm/SPARC/CodeGen.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/GHC/CmmToAsm/SPARC/CodeGen.hs b/compiler/GHC/CmmToAsm/SPARC/CodeGen.hs
index ec7d59fe02..94609fbcc1 100644
--- a/compiler/GHC/CmmToAsm/SPARC/CodeGen.hs
+++ b/compiler/GHC/CmmToAsm/SPARC/CodeGen.hs
@@ -342,7 +342,7 @@ generateJumpTableForInstr :: Platform -> Instr
-> Maybe (NatCmmDecl RawCmmStatics Instr)
generateJumpTableForInstr platform (JMP_TBL _ ids label) =
let jumpTable = map (jumpTableEntry platform) ids
- in Just (CmmData (Section ReadOnlyData label) (RawCmmStatics label jumpTable))
+ in Just (CmmData (Section ReadOnlyData label) (CmmStaticsRaw label jumpTable))
generateJumpTableForInstr _ _ = Nothing