summaryrefslogtreecommitdiff
path: root/compiler/GHC/CmmToAsm/CFG.hs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/GHC/CmmToAsm/CFG.hs')
-rw-r--r--compiler/GHC/CmmToAsm/CFG.hs7
1 files changed, 4 insertions, 3 deletions
diff --git a/compiler/GHC/CmmToAsm/CFG.hs b/compiler/GHC/CmmToAsm/CFG.hs
index 870897cceb..17631c989d 100644
--- a/compiler/GHC/CmmToAsm/CFG.hs
+++ b/compiler/GHC/CmmToAsm/CFG.hs
@@ -74,6 +74,7 @@ import Data.Bifunctor
import GHC.Utils.Outputable
import GHC.Utils.Panic
+import GHC.Utils.Panic.Plain
-- DEBUGGING ONLY
--import GHC.Cmm.DebugBlock
--import GHC.Data.OrdList
@@ -212,7 +213,7 @@ getCfgNodes m =
hasNode :: CFG -> BlockId -> Bool
hasNode m node =
-- Check the invariant that each node must exist in the first map or not at all.
- ASSERT( found || not (any (mapMember node) m))
+ assert (found || not (any (mapMember node) m))
found
where
found = mapMember node m
@@ -645,8 +646,8 @@ getCfg platform weights graph =
(CmmCall { cml_cont = Nothing }) -> []
other ->
panic "Foo" $
- ASSERT2(False, ppr "Unknown successor cause:" <>
- (pdoc platform branch <+> text "=>" <> pdoc platform (G.successors other)))
+ assertPpr False (ppr "Unknown successor cause:" <>
+ (pdoc platform branch <+> text "=>" <> pdoc platform (G.successors other))) $
map (\x -> ((bid,x),mkEdgeInfo 0)) $ G.successors other
where
bid = G.entryLabel block