summaryrefslogtreecommitdiff
path: root/compiler/nativeGen/PPC/CodeGen.hs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/nativeGen/PPC/CodeGen.hs')
-rw-r--r--compiler/nativeGen/PPC/CodeGen.hs6
1 files changed, 5 insertions, 1 deletions
diff --git a/compiler/nativeGen/PPC/CodeGen.hs b/compiler/nativeGen/PPC/CodeGen.hs
index e2c568c836..18ce58a11e 100644
--- a/compiler/nativeGen/PPC/CodeGen.hs
+++ b/compiler/nativeGen/PPC/CodeGen.hs
@@ -2081,7 +2081,11 @@ genSwitch dflags expr targets
BCTR ids (Just lbl)
]
return code
- where (offset, ids) = switchTargetsToTable targets
+ where
+ (offset, lblInfos) = switchTargetsToTable targets
+ -- lblInfos contains branch weights too,
+ -- but we only use the labels for now.
+ ids = map (fmap liLbl) lblInfos
generateJumpTableForInstr :: DynFlags -> Instr
-> Maybe (NatCmmDecl CmmStatics Instr)