|
Hello,
I have a question regarding the -fPIC option of GCC. I would like to compile a piece of code and place it somewhere inside the SAM7 flash, where the code should run no matter on which internal flash address it is placed.
My understanding is that the -fPIC option generates code, which is position independent. This can therefore be place on any location inside the SAM7 flash. But how is the .data section treated? Is this also position independent, meaning can I also place this in any section of the SAM7 RAM?
If this is the case, I surely have to tell the "code" on which offset inside the RAM the .data section starts. How do I do this?
Thanks, Bas
|