[M3devel] results of threadtest program on Windows7

Jay K jay.krell at cornell.edu
Sat Feb 26 22:13:27 CET 2011


Thanks.

jbook2:thread jay$ ./I386_DARWIN/threadtest 
Writing file...done
Creating read threads...done
Creating fork threads...done
Creating alloc threads...done
Creating lock threads...done
running...printing oldest/median age/newest
..........laziest thread is 1/0/0 (tests: read 0/0/0 fork 0/0/0 alloc 1/0/0 lock 1/1/1)
..........laziest thread is 1/0/0 (tests: read 1/0/0 fork 1/1/0 alloc 0/0/0 lock 0/0/0)

those aren't errors, right?

I can reproduce problems on Darwin -- assertion failures, errors in ThreadPThreadC.c like EBUSY and I think EINVAL.
  EBUSY is from pthread_mutex_destroy, which means we are freeing a mutex while it is locked, which means
   there is a problem. Such as the garbage collector collecting non-garbage. It ccould be something else though.

I'm trying with user threads. User threads do print the above. But so far has a longer runtime than with pthreads,
  hasn't hit any SIGSEGV or assertion failure or anything yet.

I do wonder .. oh, and then w/ user threads:

All tests complete.  Congratulations.

I do wonder about scheduling order and when the preemptions occur.
For example user threads does offer Disable/EnableScheduling.
Maybe the timeslices vary a lot and userthreads preempt a lot less?
Maybe we can try w/ tuning the user thread timeslice to match whatever pthread uses on whatever platform (
there likely no guarantee or documentation, but for experimental purposes we can likely figure it out
experimentally).

It will be interesting to see the results on Windows too. I'll probably try that right away.

 - Jay

> To: rcolebur at SCIRES.COM
> Date: Sat, 26 Feb 2011 10:10:44 -0800
> From: mika at async.caltech.edu
> CC: m3devel at elegosoft.com
> Subject: Re: [M3devel] results of threadtest program on Windows7
> 
> 
> Hi Randy,
> 
> I just implemented Jay's suggestion for removing the dependency on the
> external program "sleep".  You can CVS update and try again now.
> 
>     Mika
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://m3lists.elegosoft.com/pipermail/m3devel/attachments/20110226/9957d5d8/attachment-0002.html>


More information about the M3devel mailing list