I think #2 is the winner here - the synchronized versions of the classes are much slower than just using a simple Monitor. But IronPython's data structures are thread safe and we just use Monitor's for most of them (there are some more tuned classes in the system as well but there aren't too many of those). ________________________________________ From: [EMAIL PROTECTED] [EMAIL PROTECTED] On Behalf Of Arman Bostani [EMAIL PROTECTED] Sent: Tuesday, April 24, 2007 11:42 AM To: [email protected] Subject: Re: [IronPython] pybench results for CPython and IronPython
I assume that IronPython is implemented with thread-safe data structures (i.e. there's no GIL). If so, then IronPython is at a disadvantage on single-threaded benchmarks like pybench. Just for fun, I tested System.Collections.SortedList against its thread safe (Synchronized) version. The latter was 5 times slower! In light of this simple test, its possible that 1) IP is very efficient at implementing thread safety 2) .NET Synchronized collections are horribly slow 3) my assumption on IP's implementation are wrong. -arman _______________________________________________ users mailing list [email protected] http://lists.ironpython.com/listinfo.cgi/users-ironpython.com _______________________________________________ users mailing list [email protected] http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
