[MLton-user] Tracking down allocations
Ville Laurikari
ville at laurikari.net
Sat Jul 14 23:11:37 PDT 2007
On Sun, Jul 15, 2007 at 01:44:32AM +0100, Joe Hurd wrote:
> mlprof -show-line true -raw true x mlmon.out
>
> pointed me to the "let" line with 40,000,000,000 allocations being
> done. Where exactly should I look next to see where the allocations
> are being done?
I did a similar excercise a few weeks ago. I was able to eliminate
all allocations in my program by compiling with "mlton -inline 100000"
instead of the default. Maybe that could help in your case as well?
In my program, the allocations that weren't eliminated with default
inlining were just argument tuples for a couple of functions. The
functions were extremely short and I would have thought they would
have been inlined and the tuples eliminated, but that was not the
case.
--
http://www.iki.fi/vl/
More information about the MLton-user
mailing list