This is the mail archive of the crossgcc@sourceware.org mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: EABI PowerPC - function without stack frame




Frank Juergen-r58616 wrote:
Hi !!

I want to use a C function from the an exception vector (only this vector use this function). For this reason I need a function without a stack frame (during this time is no memory available).

How can I do this with gcc (I use the gcc for the target eabi-powerpc ) ?

I dig under __attribute__ but I can't find anything (possible I'm blind ;o) )

Your question is actually very specific to the powerpc model used in your application environment since PPC exception vectors use procesor-variant specific registers to save the current state. The PPC cache and MMU configuration define an execution environment which you need to comply before the C function can access memory.


The GCC run-time model in eabi-powerpc is isolated from these details. You have to work them in assembly-language exception vector processing, so that an EABI-compliant (in addition to cache and MMU-compliant) environment is created for your C function.

You got a great value with the GCC cross-compiler technology, with an adequately defined mission statement (EABI spec in this case). What it doesn't provide, you must make up.

As a reminder, your C function will be somehow restricted in which library function calls it can make (reentrancy concerns).

Have fun.

--

- Thierry Moreau

CONNOTECH Experts-conseils inc.
9130 Place de Montgolfier
Montreal, Qc
Canada   H2M 2A1

Tel.: (514)385-5691
Fax:  (514)385-5900

web site: http://www.connotech.com
e-mail: thierry.moreau@connotech.com


------ Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/ Want to unsubscribe? Send a note to crossgcc-unsubscribe@sourceware.org


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]