Re: how to parse the special define

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



bb c <chenbenbin@xxxxxxxxx> writes:

>      Yes, Gcc don't suport it now. Could we use the pragma to set the
> variable attribute and handle the attribute at backend to asm?

I suppose that would be possible, although just using a variable
attribute would be simpler if you don't have existing code.

>       "The usual way to put a variable at a specific memory address
> would be to use an attribute to put the variable in a specific section
> and to use a linker script to put that section at a specific address."
>
>        Could you tell me how to use the variable attribute to put the
> varibable to a specific section? Thanks.

In

http://gcc.gnu.org/onlinedocs/gcc-4.5.2/gcc/Variable-Attributes.html#Variable-Attributes

search for section ("section-name").

Ian


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux