[MLton] Question on profile.fun

Matthew Fluet fluet@cs.cornell.edu
Fri, 10 Jun 2005 23:28:26 -0400 (EDT)


> > Here are the results of that experiment:
> > 
> >      1.97 dropProfileR
> >           flatten (* without shrinking *)
> >      1.94 dropProfileFlatten
> >           shrink
> >     12.94 dropProfileS
> > 
> > Well, the above is encouraging, at least from the point of view that it 
> > confirms that flatten itself isn't really sensitive to the presence of 
> > profiling annotations.
> 
> Two things jumped out at me from looking at the pre/post shrink pass.
>
> * The other situation is that we don't simplify Case blocks that 
>   have profile statements.
> 
>   This seems much more significant.  It also seems that it could be 
>   accomodated by duplicating the profile statements when a trace through a 
>   Case block is taken.  We specifically rule this out by only simplifying 
>   Case blocks where 0 = Vector.length statements.

I doubt anyone else is hacking on this, but, just in case, I'm laying 
claim to this improvement.  I've had some initial success modifying the 
shrinker to handle this situation, and I think I see some clear means of 
extending it to handle more.  Hope to report by the end of the weekend.