It's different viewpoints...
Posted May 27, 2011 14:26 UTC (Fri) by
mpr22 (subscriber, #60784)
In reply to:
It's different viewpoints... by anton
Parent article:
What Every C Programmer Should Know About Undefined Behavior #3/3
Most optimizing compilers have a "do not optimize" mode. In gcc, "do not optimize" (-O0) is the default setting; you have to explicitly enable the footgun. -O0 still violates the programmer's expectations in C99 and C++98, though, since the "inline" keyword is ineffective, even on the tiniest of functions, when gcc's optimizer is disabled.
(
Log in to post comments)