[lkml]   [2007]   [Jul]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 6/8] i386: bitops: Don't mark memory as clobbered unnecessarily

On Wed, 25 Jul 2007, Linus Torvalds wrote:
> Hmm. I really think you should take this up with the gcc people. That
> looks like a gcc bug - because there really is nothing that guarantees
> that the asm doesn't change the array that "x" points to, and the asm
> clearly talks about clobbering memory.

Actually, I take that back. I think gcc does the right thing, and yes,
it's explained by the memory clobber being just a blind "write to memory"
rather than read memory. My bad.

It does leave us with very few ways of saying that an asm can *read*
memory, and so it might be good to have it clarified that "volatile"
implies that (at least with the memory clobber).

Your examples are good, I think.

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2007-07-26 03:25    [W:0.113 / U:0.252 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site