lkml.org 
[lkml]   [2007]   [May]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC/PATCH] doc: volatile considered evil
On Tue, 8 May 2007, Jeremy Fitzhardinge wrote:

> Sounds like it's referring to micro-architectural reordering, which is
> distinct from compiler reordering. In other words, even if you
> specified "-mvolatile-asm-stop" I would assume that the compiler could
> still reorder the asm statements. Am I right, or should I read more
> into the manual description than it actually says?
>

The ia64 architecture does not include any interlocks for asm constructs
and allow them to be executed in parallel without stop bits (although it
should emit a diagnostic message from gcc, although that is not a
constraint that was introduced in C99). Adding -mvolatile-asm-stops will
add these stop bits for any asm volatile construct that does not already
have them so that gcc is aware that it is unsafe to execute such
constructs in parallel.

[ This is a tangent because we currently don't have -mvolatile-asm-stop
support and it's ia64-specific. If they ever request such support,
then this will simply alter your warning about reordering asm
volatile constructs to exclude the ia64 case. ]

David
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-05-09 00:39    [W:0.061 / U:1.168 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site