[Mono-list] Interlocked on a SMP machine
alan.mcgovern at gmail.com
Fri Jun 22 11:49:18 EDT 2007
Can i see your testcase?
On 6/22/07, P. Oscar Boykin <oscar.boykin at gmail.com> wrote:
> I have some code that is implemented two ways. Once using a standard
> lock, and once using System.Threading.Interlocked and no locks
> Both seem to function correctly, however, the Interlocked version
> seems to only use one CPU (my max CPU is 100%). When using the lock
> based version, the CPU utilization goes to 200% (approximately).
> Thus, the lock version is much faster.
> Is this to be expected? Have I misunderstood Interlocked? Is it a
> limitation in mono?
> This was on mono 1.2.3 from Ubuntu 7.04.
> Mono-list maillist - Mono-list at lists.ximian.com
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Mono-list