Bulat Ziganshin wrote:
Taral wrote:
T> I don't see that more optimization follows from the availability
T> of information regarding the strictness of a function result's
T> subcomponents.
ghc uses unboxed tuples just for such sort of optimizations. instead
of returning possibly-unevaluated pair with possibly-unevaluated
elements it just return, say, two doubles in registers - a huge win
Mmm, not quite. Unboxed tuples are boxed tuples restricted such that they
never have to be stored on the heap, but this has no effect on semantics at
all. A function returning (# Double,Double #) may still return two thunks.
-- Ben
_______________________________________________
Haskell-prime mailing list
Haskell-prime@haskell.org
http://haskell.org/mailman/listinfo/haskell-prime