
#16039: 'GHC.Magic.noinline <var>' should not float out -------------------------------------+------------------------------------- Reporter: heisenbug | Owner: heisenbug Type: bug | Status: new Priority: normal | Milestone: 8.10.1 Component: Compiler | Version: 8.2.1 Resolution: | Keywords: FloatOut Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: #15155 | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by heisenbug): Replying to [comment:12 simonpj]:
a bunch of expressions (e.g noinline @ (Role -> Type -> MCoercionN -> Coercion) mkGReflCo) that are destined for class dictionaries got floated out for no reason.
Interesting. Which pass did this?
Simplifier. But the mechanism by which it picks up the level variables is still a riddle for me. I'll research this, as I think things should be done in one place.
I suspect that we should have invariants like {{{ exprIsTrivial e implies notWorthFloating e exprIsTrivial e implies exprIsCheapX e }}} I wonder if these are true right now?
Who knows. This is a nice use-case for `ASSERT()`. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/16039#comment:13 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler