How to make GCC M68k using base registers to access data and bss

20 Views Asked by At

I want to make re-entrant code that is stored in ROM and have the access to .data and .bss areas through the use of base registers.

Prior to activate the code, the content of the data and bss registers are set by the activating function referring to the designated RAM area as well as is done for the stack pointer. (Copying of initialized data must be done by the code itself). This make is possible to to have multiple instantiations of the data with only one instance of the code in ROM.

Is there an option in the GCC m68k (cross) compiler to make code re-entrant in a way that is desired above.

0

There are 0 best solutions below