This is the mail archive of the
mailing list for the glibc project.
Re: PATCH: Add memory barrier to malloc
On Tue, May 06, 2003 at 03:43:19PM -0000, Wolfram Gloger wrote:
> > > > H.J. Lu> a->next = main_arena.next;
> > > > H.J. Lu> + atomic_write_barrier ();
> > > > H.J. Lu> main_arena.next = a;
> If the patch above makes a difference it just shows that read access
> to a pointer in memory isn't atomic on ia64.
No, the problem that this shows is that if a->next isn't committed to
memory, that a reader can main_arena.next == a, but an trash in a->next.