[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-gcc-list] Improving in leaps and skips!
From: |
Björn Haase |
Subject: |
Re: [avr-gcc-list] Improving in leaps and skips! |
Date: |
Wed, 2 Mar 2005 23:09:35 +0100 |
User-agent: |
KMail/1.7.1 |
>
> The point is: nested functions *do work* in AVR-Ada for what they are
> typically used in Ada (limiting visibilty, enhancing code readability).
>
> Rolf
IIRC nested functions are completely dysfunctional for avr when using C. The
problem seems to be, that for any nested function gcc- c wants to generate a
trampoline (self-modifying code stub on the stack-frame) which is not
possible with read-only program memory.
If I understand correctly, the main use for nested functions is to locally
define small functions that could access the local variables of the parent
function and that could be passed, e.g. to library functions like quick-sort.
E.g. for sorting arrays that reside on the stack frame of the parent
function.
I have seen a thread stating that this "passing pointers to nested functions
to library routines" is a very popular coding style in ada.
Yours,
Björn
- Re: [Fwd: AW: [avr-gcc-list] Improving in leaps and skips!], E. Weddington, 2005/03/01
- Re: [Fwd: AW: [avr-gcc-list] Improving in leaps and skips!], Björn Haase, 2005/03/01
- Re: [avr-gcc-list] Improving in leaps and skips!, E. Weddington, 2005/03/01
- Re: [avr-gcc-list] Improving in leaps and skips!, Björn Haase, 2005/03/01
- Re: [avr-gcc-list] Improving in leaps and skips!, E. Weddington, 2005/03/01
- Re: [avr-gcc-list] Improving in leaps and skips!, Russell Shaw, 2005/03/01
- Re: [avr-gcc-list] Improving in leaps and skips!, Joerg Wunsch, 2005/03/02
- Re: [avr-gcc-list] Improving in leaps and skips!, Rolf Ebert, 2005/03/02
- Re: [avr-gcc-list] Improving in leaps and skips!, E. Weddington, 2005/03/02
- Re: [avr-gcc-list] Improving in leaps and skips!, Rolf Ebert, 2005/03/02
- Re: [avr-gcc-list] Improving in leaps and skips!,
Björn Haase <=
- Re: [avr-gcc-list] Improving in leaps and skips!, Rolf Ebert, 2005/03/13
- Re: [avr-gcc-list] Improving in leaps and skips!, Marek Michalkiewicz, 2005/03/13
- Re: [avr-gcc-list] Improving in leaps and skips!, Jeff Barlow, 2005/03/13
- Re: [avr-gcc-list] Improving in leaps and skips!, Ben L. Titzer, 2005/03/15
- Re: [avr-gcc-list] Improving in leaps and skips!, E. Weddington, 2005/03/14
- Re: [avr-gcc-list] Improving in leaps and skips!, Ben L. Titzer, 2005/03/15
- Re: [avr-gcc-list] Improving in leaps and skips!, E. Weddington, 2005/03/14
- Re: [avr-gcc-list] Improving in leaps and skips!, Richard Urwin, 2005/03/02
- Re: [avr-gcc-list] Improving in leaps and skips!, E. Weddington, 2005/03/02
- Re: [avr-gcc-list] Improving in leaps and skips!, Joerg Wunsch, 2005/03/03