This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: New problems with gcc-2.8.0 based code - NOW FIXED!
- To: Paul Koning <pkoning at xedia dot com>
- Subject: Re: New problems with gcc-2.8.0 based code - NOW FIXED!
- From: Linus Torvalds <torvalds at transmeta dot com>
- Date: Tue, 30 Dec 1997 12:27:01 -0800 (PST)
- cc: kenner at vlsi1 dot ultra dot nyu dot edu, gcc2 at cygnus dot com, egcs at cygnus dot com
Paul Koning writes:
>
> On the other hand, an asm that has no explicit output clearly must
> have side effects, otherwise it wouldn't have been put there. So for
> such an asm, "volatile" is the right treatment.
I agree 100%.
Any asm without any outputs by very definition has to have some side
effect to be useful, and as such the compiler should consider it volatile
by default. That makes gcc not only conform with the documentation, it is
also the only interpretation that makes any sense at all.
The lack of a "novolatile" keyword is a non-issue, as anybody who would
ever want to use it seems rather misguided.
Linus