[M3commit] CVS Update: cm3

Jay Krell jkrell at elego.de
Thu Dec 10 13:18:48 CET 2009


CVSROOT:	/usr/cvs
Changes by:	jkrell at birch.	09/12/10 13:18:48

Modified files:
	cm3/m3-libs/m3core/src/thread/WIN32/: ThreadWin32.i3 
	                                      ThreadWin32.m3 
	                                      ThreadWin32C.c 

Log message:
	Change LockMutex into basically just EnterCriticalSection,
	UnlockMutex into basically just LeaveCriticalSection.
	No more use of giant lock or Self() in them.
	This precludes an optimization of condition variables
	mentioned by Birrel (not shown by him, but easy to understand,
	but also it was never done here).
	
	Before long we'll probably just switch to Java's implementation
	anyway, which doesn't have a giant lock (if/when I understand it better,
	or maybe Tony will do this, since it might improve pthreads also
	and sounds like he wants to).
	
	Note this makes LockMutex/UnlockMutex very much resemble
	the .v0 and .v1 files that were left here.
	(which I went back and made the code look more like;
	not maintaining a uint32 "holder" threadi but just a boolean "held",
	but without the cache and still using C to know about the size
	of a critical section)
	
	remove incorrect lockingLevel comments in the perf code
	
	Note that I think perflocking should be moved one line
	up in LockMutex, but I match pthreads here, and it doesn't
	really matter




More information about the M3commit mailing list