> -----Original Message----- > From: > [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] > org] On Behalf Of David Brown > Sent: Tuesday, October 02, 2007 2:48 AM > To: 'AVR-GCC-LIST' > Subject: Re: [avr-gcc-list] Problem with delay loop > > Graham Davies wrote: > > Eric Weddington wrote: > >> ... We were discussing the possibility of the compiler being > >> smarter about 'volatile' and local automatic variables. I would > >> definitely say that if the local variable's address is taken, then > >> all bets are off. > > > > Second point first. If the address of a variable is taken then the > > compiler cannot put it in a register. If it is declared automatic, > > it goes on the stack, if there is one, or somewhere else in > memory if > > there > > Actually, you're slightly wrong on both accounts here. On > the AVR, the > registers are available in the memory map, so it is possible to take > their addresses (it's not commonly done, except perhaps on the old > RAM-less Tiny's, but it's possible).
True. However in practice, I don't think the AVR port in GCC is aware of these aliases and I don't think that it will use them. _______________________________________________ AVR-GCC-list mailing list AVR-GCC-list@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-gcc-list