Note [Floating out of top level bindings]
NB: we do need to float out of top-level bindings
Consider x = length [True,False]
We want to get
s1 = False : []
s2 = True : s1
x = length s2
We return a *list* of bindings, because we may start with
x* = f (g y)
where x is demanded, in which case we want to finish with
a = g y
x* = f a
And then x will actually end up case-bound References 0
This Note does not link to any other.
Referenced by 2
- GHC.CoreToStg.Prep call site
- Floating in CorePrep GHC.CoreToStg.Prep