projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix bug in vectorised DataCon worker generation
[ghc-hetmet.git]
/
compiler
/
cmm
/
CmmInfo.hs
diff --git
a/compiler/cmm/CmmInfo.hs
b/compiler/cmm/CmmInfo.hs
index
78ff5af
..
017efe4
100644
(file)
--- a/
compiler/cmm/CmmInfo.hs
+++ b/
compiler/cmm/CmmInfo.hs
@@
-165,8
+165,8
@@
mkInfoTableAndCode info_lbl std_info extra_bits entry_lbl args blocks
| otherwise -- Separately emit info table (with the function entry
= -- point as first entry) and the entry code
| otherwise -- Separately emit info table (with the function entry
= -- point as first entry) and the entry code
- [mkDataLits info_lbl (CmmLabel entry_lbl : std_info ++ extra_bits),
- CmmProc [] entry_lbl args blocks]
+ [CmmProc [] entry_lbl args blocks,
+ mkDataLits info_lbl (CmmLabel entry_lbl : std_info ++ extra_bits)]
mkSRTLit :: CLabel
-> C_SRT
mkSRTLit :: CLabel
-> C_SRT
@@
-214,7
+214,9
@@
mkLiveness uniq live =
mkBits (reg:regs) = take sizeW bits ++ mkBits regs where
sizeW = case reg of
Nothing -> 1
mkBits (reg:regs) = take sizeW bits ++ mkBits regs where
sizeW = case reg of
Nothing -> 1
- Just r -> machRepByteWidth (localRegRep r) `quot` wORD_SIZE
+ Just r -> (machRepByteWidth (localRegRep r) + wORD_SIZE - 1)
+ `quot` wORD_SIZE
+ -- number of words, rounded up
bits = repeat $ is_non_ptr reg -- True <=> Non Ptr
is_non_ptr Nothing = True
bits = repeat $ is_non_ptr reg -- True <=> Non Ptr
is_non_ptr Nothing = True