Which version of C? The answers vary. For 1st ed. K&R, you're going to get implementation-specific behaviour, which might very well vary whether or not optimization is enabled.
In other words, the very definition of undefined behavior; You cannot reason about how the program will behave. This topic has already been covered fairly well on SO: http://stackoverflow.com/questions/949433/could-anyone-expla...
A nontrivial example is the value of "-64 >> 3". More info at http://stackoverflow.com/questions/2397984/undefined-unspeci...
I think the post you reply to refers to the fact that early K&R C predates any standard that introduced the term 'undefined behavior'. At that time, the standard was just 'whatever that tool Kernighan and Ritchie wrote does'.
The maxim then (and now) being: Don't Write Silly Code.