Re: [PATCH 6/8] i386: bitops: Don't mark memory as clobbered unnecessarily

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Trent Piepho <xyzzy@...>
Cc: Nick Piggin <nickpiggin@...>, Satyam Sharma <ssatyam@...>, Linux Kernel Mailing List <linux-kernel@...>, David Howells <dhowells@...>, Andi Kleen <ak@...>, Andrew Morton <akpm@...>
Date: Wednesday, July 25, 2007 - 9:22 pm

On Wed, 25 Jul 2007, Linus Torvalds wrote:

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.

		Linus
-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH 0/8] i386: bitops: Cleanup, sanitize, optimize, Satyam Sharma, (Mon Jul 23, 12:05 pm)
Re: [PATCH 0/8] i386: bitops: Cleanup, sanitize, optimize, Denis Vlasenko, (Mon Jul 30, 1:57 pm)
Re: [PATCH 0/8] i386: bitops: Cleanup, sanitize, optimize, Satyam Sharma, (Mon Jul 30, 9:07 pm)
Re: [PATCH 4/8] i386: bitops: Kill volatile-casting of memor..., Benjamin Herrenschmidt, (Tue Jul 24, 5:49 am)
[PATCH 3/8] i386: bitops: Rectify bogus "+m" constraints, Satyam Sharma, (Mon Jul 23, 12:05 pm)
[PATCH 2/8] i386: bitops: Rectify bogus "Ir" constraints, Satyam Sharma, (Mon Jul 23, 12:05 pm)
Re: [PATCH 8/8] i386: bitops: smp_mb__{before, after}_clear_..., Jeremy Fitzhardinge, (Tue Jul 24, 3:48 am)
Re: [PATCH 6/8] i386: bitops: Don't mark memory as clobbered..., Linus Torvalds, (Wed Jul 25, 9:22 pm)
Re: [PATCH 6/8] i386: bitops: Don't mark memory as clobbered..., Jeremy Fitzhardinge, (Tue Jul 24, 5:31 pm)
Re: [PATCH 6/8] i386: bitops: Don't mark memory as clobbered..., Benjamin Herrenschmidt, (Tue Jul 24, 5:52 am)
Re: [PATCH 6/8] i386: bitops: Don't mark memory as clobbered..., Benjamin Herrenschmidt, (Tue Jul 24, 5:36 pm)
Re: [PATCH 6/8] i386: bitops: Don't mark memory as clobbered..., Benjamin Herrenschmidt, (Tue Jul 24, 5:37 pm)
Re: [PATCH 6/8] i386: bitops: Don't mark memory as clobbered..., Benjamin Herrenschmidt, (Tue Jul 24, 6:32 pm)
Re: [PATCH 6/8] i386: bitops: Don't mark memory as clobbered..., Jeremy Fitzhardinge, (Mon Jul 23, 1:49 pm)
[PATCH 1/8] i386: bitops: Update/correct comments, Satyam Sharma, (Mon Jul 23, 12:05 pm)
Re: [PATCH 7/8] i386: bitops: Kill needless usage of __asm__..., Jeremy Fitzhardinge, (Mon Jul 23, 12:23 pm)
Re: [PATCH 7/8] i386: bitops: Kill needless usage of __asm__..., Jeremy Fitzhardinge, (Mon Jul 23, 1:39 pm)
Re: [PATCH 7/8] i386: bitops: Kill needless usage of __asm__..., Jeremy Fitzhardinge, (Mon Jul 23, 2:28 pm)
Re: [PATCH 7/8] i386: bitops: Kill needless usage of __asm__..., Jeremy Fitzhardinge, (Mon Jul 23, 4:40 pm)