projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
SPARC NCG: Keep track of destinations when doing a tabled jump
[ghc-hetmet.git]
/
compiler
/
nativeGen
/
MachCodeGen.hs
diff --git
a/compiler/nativeGen/MachCodeGen.hs
b/compiler/nativeGen/MachCodeGen.hs
index
da2b0ea
..
cac9f17
100644
(file)
--- a/
compiler/nativeGen/MachCodeGen.hs
+++ b/
compiler/nativeGen/MachCodeGen.hs
@@
-4309,8
+4309,8
@@
genSwitch expr ids
, SLL e_reg (RIImm $ ImmInt 2) offset_reg
-- load and jump to the destination
, SLL e_reg (RIImm $ ImmInt 2) offset_reg
-- load and jump to the destination
- , LD II32 (AddrRegReg base_reg offset_reg) dst
- , JMP (AddrRegImm dst (ImmInt 0))
+ , LD II32 (AddrRegReg base_reg offset_reg) dst
+ , JMP_TBL (AddrRegImm dst (ImmInt 0)) [i | Just i <- ids]
, NOP ]
#else
, NOP ]
#else