Remove most of the CPP from AsmCodeGen
[ghc-hetmet.git] / compiler / nativeGen / PPC / RegInfo.hs
index 91c9e15..bfc712a 100644 (file)
@@ -7,7 +7,7 @@
 -----------------------------------------------------------------------------
 
 module PPC.RegInfo (
-        JumpDest( DestBlockId ), 
+        JumpDest( DestBlockId ), getJumpDestBlockId,
        canShortcut, 
        shortcutJump, 
 
@@ -31,6 +31,10 @@ import Unique
 
 data JumpDest = DestBlockId BlockId | DestImm Imm
 
+getJumpDestBlockId :: JumpDest -> Maybe BlockId
+getJumpDestBlockId (DestBlockId bid) = Just bid
+getJumpDestBlockId _                 = Nothing
+
 canShortcut :: Instr -> Maybe JumpDest
 canShortcut _ = Nothing