David Brown <da...@westcontrol.com> wrote: > It might be worth filing a report for a better clarification in the > documentation (does that need a bug report?) to make it clearer that > "always_inline" has no effect without a normal "inline" declaration.
Ah yes, you are right. Compile the following snippet: #define PORTA (*(volatile uint8_t *)0x3B) static inline void __attribute__((always_inline)) toggle_pin(void) { PORTA |= 1; PORTA &= ~1; } int main(void) { toggle_pin(); return 0; } with these two commands: avr-gcc -O0 -S foo.c # works correctly avr-gcc -O0 -S -Dinline= foo.c # doesn't inline toggle_pin() -- cheers, J"org .-.-. --... ...-- -.. . DL8DTL http://www.sax.de/~joerg/ NIC: JW11-RIPE Never trust an operating system you don't have sources for. ;-) _______________________________________________ AVR-GCC-list mailing list AVR-GCC-list@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-gcc-list