[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: hook question
- From: Mike Pall <mikelu-0610@...>
- Date: Tue, 10 Oct 2006 14:07:51 +0200
Hi,
David Jones wrote:
> This assumes that updates to each of hookmask and hook will take
> place atomically. There's no guarantee of that. On some
> architectures an update of hook may consist of two writes (to two
> halves of a 64-bit quantity say) and a re-ordered write to hookmask
> may appear in between them.
Please. If updates to a pointer sized quantity (32 bit on 32 bit
systems, 64 bit on 64 bit systems) are non-atomic, fire the CPU
designer team. AFAIK none of the 64 bit multi-core machines on
the market do this.
> I can see that the code has been written with great care, but that
> doesn't make it correct.
Make a test case, find a machine where it verifiably fails (build
one, if necessary) and submit a patch. Being a pragmatic, I'll
type Ctrl-D now and continue with more interesting things.
Bye,
Mike