http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41849
Georg-Johann Lay <gjl at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gjl at gcc dot gnu.org, | |hendrixgr at gmail dot com Component|rtl-optimization |target Known to work| |4.5.0 --- Comment #1 from Georg-Johann Lay <gjl at gcc dot gnu.org> 2011-04-20 19:45:54 UTC --- Unfortunately, we don't see the exact command line. I don't see this for 4.5.0, tried -O, -O2, -Os, -O3. All gives foo: /* prologue: function */ /* frame size = 0 */ /* stack size = 0 */ .L__stack_usage = 0 sts timer0_h8_buf,r3 /* epilogue start */ ret Note that volatile on register variables does not work as expected. volatile is meaningful for memory locations only. As the addresses in your snipp indicate there is much more code in the module, so presumably we don't see the proper source.