projects
/
ghc-hetmet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
87c4411
)
Ignore comments when inlining.
author
Edward Z. Yang
<ezyang@mit.edu>
Fri, 25 Mar 2011 12:01:08 +0000
(12:01 +0000)
committer
Edward Z. Yang
<ezyang@mit.edu>
Fri, 25 Mar 2011 12:01:08 +0000
(12:01 +0000)
compiler/cmm/CmmOpt.hs
patch
|
blob
|
history
diff --git
a/compiler/cmm/CmmOpt.hs
b/compiler/cmm/CmmOpt.hs
index
df0555f
..
0dec26d
100644
(file)
--- a/
compiler/cmm/CmmOpt.hs
+++ b/
compiler/cmm/CmmOpt.hs
@@
-142,6
+142,7
@@
lookForInline u expr (stmt : rest)
-- single-assignment.
ok_to_skip = case stmt of
CmmNop -> True
-- single-assignment.
ok_to_skip = case stmt of
CmmNop -> True
+ CmmComment{} -> True
CmmAssign (CmmLocal (LocalReg u' _)) rhs | u' /= u -> True
CmmAssign g@(CmmGlobal _) rhs -> not (g `regUsedIn` expr)
_other -> False
CmmAssign (CmmLocal (LocalReg u' _)) rhs | u' /= u -> True
CmmAssign g@(CmmGlobal _) rhs -> not (g `regUsedIn` expr)
_other -> False