Messages in this thread | | | Date | Thu, 28 Feb 2008 12:13:09 +0100 (CET) | From | Jiri Kosina <> | Subject | Re: Linux 2.6.25-rc2 |
| |
On Wed, 27 Feb 2008, Andrew Morton wrote:
> Doing ++ on a u32 _is_ atomic wrt interrupts on x86 and probably lots of > other architectures, so we're OK using unsigned there.
So you make implicit assumptions about how gcc compiles your ++? I am afraid you can't do that, gcc is absolutely free to turn variable++; statement to non-atomic sequence of instructions (memory->register load, increment register, for example).
-- Jiri Kosina SUSE Labs
| |