getrusage bug?

Stephen Weeks MLton@sourcelight.com
Fri, 22 Jun 2001 11:13:34 -0700


> I noticed that the times reported by mlton for assemble and link are almost
> always zero, so something is wrong.  I wrote the following simple SML program to
> test out getrusage, and indeed, by stracing it, one can see that
> getrusage(RUSAGE_CHILDREN, ...) is always returning 0, even with a child that is
> spinning at full speed.  Any ideas what's wrong?  Is this a know bug in
> getrusage and is there a workaround?

Ahh, now I see.  RUSAGE_CHILDREN is only for children who have exited and the
parent has waited for them?  So we must not be waiting for the children that do
the gcc/assembler calls.  I am investigating.