[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [microblaze-uclinux] microblaze-uclinux-elf2flt bug with static initializers
Andrei -
These may be of some help:
http://www.itee.uq.edu.au/~listarch/microblaze-uclinux/archive/2009/05/msg00298.html
http://www.itee.uq.edu.au/~listarch/microblaze-uclinux/archive/2009/06/msg00002.html
Regards,
------------------------------------------------------------------------
Steven J. Magnani "I claim this network for MARS!
www.digidescorp.com Earthling, return my space modulator!"
#include <standard.disclaimer>
-----Original Message-----
From: Andrei Terechko <andrei@xxxxxxxxxxxxxxxxx>
Reply-to: microblaze-uclinux@xxxxxxxxxxxxxx
To: microblaze-uclinux@xxxxxxxxxxxxxx
Cc: John Linn <linnj@xxxxxxxxxx>
Subject: [microblaze-uclinux] microblaze-uclinux-elf2flt bug with static
initializers
Date: Mon, 22 Jun 2009 16:05:07 +0200
Hello,
We've encountered a problem with static initializers in the
microblaze-uclinux-elf2flt tool from PetaLinux 0.20 Build -rc1 050607,
svn revision 5150.
In the following code snippet two arrays w_0[] and r_0[] reside in .bss,
and two other arrays w[] and r[] in .data:
int w_0; /* .bss */
int r_0; /* .bss */
int *w[] = {&w_0}; /* .data */
int *r[] = {&r_0}; /* .data */
The arrays from .data are initialized with pointers to the arrays
in .bss. However, the r[] array gets initialized wrongly as can be seen
by running the attached C program. Essentially, elf2flt seems to assign
a wrong pointer to an array element with a static initializer, if the
pointer refers to a symbol from a different ELF section.
Is there any chance this issue can be solved in the elf2flt? Thanks in
advance!
Best regards,
Andrei Terechko
___________________________
microblaze-uclinux mailing list
microblaze-uclinux@xxxxxxxxxxxxxx
Project Home Page : http://www.itee.uq.edu.au/~jwilliams/mblaze-uclinux
Mailing List Archive : http://www.itee.uq.edu.au/~listarch/microblaze-uclinux/