Placing variables at a specific location (address) using microblaze GCC

  • Follow


Hello,

I am trying to figure out the ins and outs of the MB-GCC compiler. I am
not familiar with how to place variable at specific locations in
memory. I have used the #pragma directive with other compilers to nail
down variables to specific locations in memory.

Any help would be appreciated. I think that it may also be neccessary
to create another section in memory using the linker. ie .text or .bss
etc.

Thanks in adavance.

Jeremy

0
Reply jweese (3) 6/7/2005 12:34:14 PM

Specify a new section for your variables, and add this section to your
linker script with the fixed address.

E.g.:
int fixed_data __attribute__ ((section ("YOURSECTION"))) = 0;

0
Reply Zolee 6/7/2005 4:01:11 PM


Thank you for your reply, I did finally find this information.

0
Reply JW 6/7/2005 7:40:13 PM

2 Replies
233 Views

(page loaded in 1.028 seconds)

Similiar Articles:









7/21/2012 10:29:37 PM


Reply: