[ECOS] newbie query! spinlocks mlqueue
Hans Hübner
hans@huebner.org
Wed Dec 21 07:06:00 GMT 2005
On Wed, 21 Dec 2005, jeane wrote:
> Thanks for the link I went through it, I'm new to ecos my assumption
> was while using a spin-lock
[...]
> I went through the spinlock's implementation on uni-processor I didn't
> see any while loop /test_and_set instruction in Cyg_SpinLock::lock()
> which will amount to the CPU spinning. Neither was there an
> implementation which will disable scheduling. So how does the uni
> -processor spin-lock guarantee "locking" across threads when
> pre-emptible scheduling is enabled.
>From the documentation: "Therefore spinlocks are only appropriate for SMP
systems where the current owner of a spinlock can continue running on a
different processor."
-Hans
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
More information about the Ecos-discuss
mailing list