Commit f07f25fd authored by simonpj@microsoft.com's avatar simonpj@microsoft.com

Don't inline a loop breaker, even if it has an INLINE pragma

We preserve the InlineRule on loop breakers, in the hope that they'll
stop being a loop breaker later.  So don't inline them!
parent 7fa25f74
......@@ -777,6 +777,10 @@ postInlineUnconditionally env top_lvl bndr occ_info rhs unfolding
activeInline :: SimplEnv -> OutId -> Bool
activeInline env id
| isNonRuleLoopBreaker (idOccInfo id) -- Things with an INLINE pragma may have
-- an unfolding *and* be a loop breaker
= False -- (maybe the knot is not yet untied)
| otherwise
= case getMode env of
SimplGently { sm_inline = inlining_on }
-> inlining_on && isEarlyActive act
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment