[Mono-devel-list] Language Shootout - problems with Mono times

Paolo Molaro lupus at ximian.com
Fri Sep 3 13:11:47 EDT 2004

On 09/01/04 Isaac Gouy wrote:
> > > My ancient Linux 2.4.19 Gentoo gives both sensible results and too
> > > small  results. (Not sure which version the other guys are using.)
> > 
> > Kernel 2.2.20 has the same behaviour: sometimes the results are
> > correct and sometimes not.
> Beyond me. Do you know of anyone who might be interested in looking at
> this issue?

I wrote to the kernel developers: it looks like timing info is not
reported from subthreads unless the subthread exits: it's a timing
issue. Sometimes after executing the C# program the subthread that
executes it manages to call pthread_exit() before the main program quits
and sometimes not, so you get the incorrect timings.
This could be considered a buglet in mono, though the time results are
the only thing that should be affected by it. Maybe Dick has further
insights why we don't properly wait for a thread with pthread_join()
(ie why we use pthread_detach(): there may be other ways for us
to wait for the thread to call pthread_exit ()).


lupus at debian.org                                     debian/rules
lupus at ximian.com                             Monkeys do it better

More information about the Mono-devel-list mailing list