On Sun, Mar 28, 2010 at 03:37:16PM +0200, Szikra Istvan wrote: > >> If it's generating calls from my function (unwanted), it could be so > >> kind to put the callee next to the caller.
Perhaps I misunderstand your wish, but this seems possible only the first time a function is called. And if it is called only once, then it might as well be in-line. > The compiler generates function calls from a peace of code, but > does not tell the linker to keep it together. Probably the compiler > doesn't even know, because it doesn't see the big picture. But I do! > so how do I tell the compiler to stop messing around, and I know what > I'm doing so leave that part of the code alone, or stop recognizing > that pattern in the entire project? Since the discussion has proceeded this far, you've presumably not had satisfaction from choosing for yourself where a function lives?: void foo(void) __attribute__ ((section (".bootloader"))); When finer control of the placement of code in the binary is required, it is only necessary to write one's own linker script. This takes time and effort to learn, but it is satisfying when the result is exactly as desired. The ld manpage is not overly informative, but its info page is a goldmine. Erik -- If at first you don't succeed, try again. Then Quit. No use being a damn fool about it. - W.C. Fields _______________________________________________ AVR-GCC-list mailing list AVR-GCC-list@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-gcc-list