projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove most of the CPP from AsmCodeGen
[ghc-hetmet.git]
/
compiler
/
nativeGen
/
SPARC
/
ShortcutJump.hs
diff --git
a/compiler/nativeGen/SPARC/ShortcutJump.hs
b/compiler/nativeGen/SPARC/ShortcutJump.hs
index
c0c3343
..
30e48bb
100644
(file)
--- a/
compiler/nativeGen/SPARC/ShortcutJump.hs
+++ b/
compiler/nativeGen/SPARC/ShortcutJump.hs
@@
-1,6
+1,6
@@
module SPARC.ShortcutJump (
module SPARC.ShortcutJump (
- JumpDest(..),
+ JumpDest(..), getJumpDestBlockId,
canShortcut,
shortcutJump,
shortcutStatic,
canShortcut,
shortcutJump,
shortcutStatic,
@@
-25,6
+25,10
@@
data JumpDest
= DestBlockId BlockId
| DestImm Imm
= DestBlockId BlockId
| DestImm Imm
+getJumpDestBlockId :: JumpDest -> Maybe BlockId
+getJumpDestBlockId (DestBlockId bid) = Just bid
+getJumpDestBlockId _ = Nothing
+
canShortcut :: Instr -> Maybe JumpDest
canShortcut _ = Nothing
canShortcut :: Instr -> Maybe JumpDest
canShortcut _ = Nothing