http://blogs.howstuffworks.com/2009/08/26/how-shock-absorbers-work-2/
The credit goes to original author.
cheers!
static int foo; void bar(void) { foo = 0; while (foo != 255) ; }
This code will be optimized to:
void bar_optimized(void) { foo = 0; while (true) ; }by an optimizing compiler.
static volatile int foo; void bar (void) { foo = 0; while (foo != 255) ; }
svn checkout <here you enter the web page address>