This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/17884] [4.0 Regression] asm 'volatile' is not honored as documented


------- Additional Comments From dalej at apple dot com  2004-10-08 18:27 -------
The doc also says "You can prevent an asm from being deleted, moved significantly, or combined,
by writing the keyword volatile after the asm."  Which seems to contradict the later statement
that they can be moved across jumps; if that's not significant motion, what is?  Both sentences
go back to at least 2.95.

So what are the semantics of 'asm volatile'?  If it does not disable code motion, it seems to me
Fariborz is right that it's a NOP and should be deprecated.  But there is a lot of code around here
that uses it, and worked as intended with 3.3.  IMO the incorrect statement in the doc is the
last one, not the first two.



-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17884


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]