
On Sun, 2009-05-24 at 12:48 -0400, Mario Blažević wrote:
How about diffing the whole core output (and using -ddump-simpl). If there's a performance difference then there must be a difference in the core code too.
I can't exactly use diff because the generated identifier names are not the same, but after poring over with Emacs ediff I have found only one difference that's not attributable to identifiers:
$diff main.simpl imported.simpl ... 223c232 < a_s1rs [ALWAYS Just L] :: GHC.Integer.Internals.Integer ---
a_s1sV [ALWAYS Just S] :: GHC.Integer.Internals.Integer
...
Good find!
Does this S vs. L difference have anything to do with strictness and laziness?
Yes. So, I think we should open a ghc but report with all the details, particularly the example's source, the ghc version and that highlight of that strictness difference. Duncan