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 c/42126] gcc optimizes line away/optimizes to an endless loop



------- Comment #5 from codemasterhs at yahoo dot de  2009-11-21 09:02 -------
(In reply to comment #4)
> The pointer is not declared volatile.
> 
> static struct smpMsg_t * volatile freeList;
> 
> would be a volatile pointer.
> 

Ok, this worked. So where has to be the volatile keyword, so that everything
works? I mean I thought "volatile TYPE (like int, char and so on) foo" is
right, isn´t it? Or does this only not work for pointers?


-- 


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


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