In thinking about it I figured it may be because I was using Integer and
not Int; I recompiled without -fall-strict and with Int instead of
Integer.  In that case,

mkArray1: 27.27u 2.37s 0:32.32 91.7%
mkArray2: 25.88u 2.33s 0:30.97 91.0%

So here there's basically no difference in performance; the one with zeros
is just a bit faster than the other, but probably not significantly so.

So this case didn't show a problem with undefined.  Could there ever be a
problem or is the compiler smart enough to catch this?

 - Hal

--
Hal Daume III

 "Computer science is no more about computers    | [EMAIL PROTECTED]
  than astronomy is about telescopes." -Dijkstra | www.isi.edu/~hdaume

On Wed, 15 May 2002, Simon Marlow wrote:

> [ moved to [EMAIL PROTECTED] ]
> 
> > The timing results were:
> > 
> > mkArray1: 11.42u 0.79s 0:13.47 90.6%
> > mkArray2: 24.55u 2.31s 0:30.12 89.1%
> > 
> > Which is actually *slower*.  Any ideas why?  (These were 
> > compiled with ghc
> > 5.02.3 -O2 -fvia-c -fall-strict)
> 
> What are the results without -fall-strict?  (-fall-strict is an old
> experimental flag and almost certainly doesn't do anything reasonable.
> We've de-documented it in the HEAD).
> 
> Cheers,
>       Simon
> _______________________________________________
> Glasgow-haskell-users mailing list
> [EMAIL PROTECTED]
> http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
> 

_______________________________________________
Glasgow-haskell-users mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to