malloc and threads
Daniel Jacobowitz
drow@mvista.com
Sun Dec 1 09:09:00 GMT 2002
On Wed, Nov 27, 2002 at 09:07:58AM -0800, David Boreham wrote:
> > XScale is an ARM based processor
>
> Perhaps there is a bug in the XScale locking code
> or in the CPU hardware ?
Well, there are bugs in the ARM locking code. I recommend interested
parties look at the conversation between myself and Richard Earnshaw
about this on the gcc-patches list, on Oct. 4th-7th:
Subject: Atomic operations on the ARM
I don't believe it will affect malloc's use of locks; in short
test-and-set works but exchange-and-add is not atomic.
I'm not sure if compare_and_swap works correctly or not. A glance
suggests that it does not.
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
More information about the Libc-alpha
mailing list