N. Coesel wrote:
Sergey,
Isn't it possible to use the already existing 'section' attribute?
Yes, it's possible. New attribute works just like section attribute with the one
exception - it creates unique named section
fardata.<variable_name>/.fartext.<func_name> if
-fdata-sections/-ffunction-sections compiler option passed. It is necessary for
linker garbage collection (--gc-sections option). You can achieve the same
behavior with 'section' attribute selecting unique names manually for each
variable/func.
That
would be more consistent since you are putting variables in a kind of
different memory region. It would also keep code portable to other platforms.
Nico Coesel
At 11:45 25-1-2009 +0200, you wrote:
Hello everyone
I'm working on >64K support in mspgcc now. I think I could commit my
results into repository next
week. I decided to place functions and constants into upper memory via
__attribute__ (and I did it,
it works). I need your help in choosing the name of this attribute. Which
is the best? :
__attribute__((__uppermem__))
__attribute__((__far__))
__attribute__((__highmem__))
Or, maybe, other one?
Usage:
__attribute__((__uppermem__)) cons char * UpperText = "Hello";
__attribute__((__uppermem__)) void TestFunc(void)
{
for(;;);
}
--
Regards,
Sergey A. Borshch mailto: [email protected]
SB ELDI ltd. Riga, Latvia