struct copying error

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

 



hello,

I am writing a new backend for sparc with gcc-4.0.1, and I've
completely rewritten these backend files.



however, I have a vicious bug, and I can't find anything describing
that in the manuals



this is the code - pretty easy -

typedef struct tA

{

int x;

int y;

int z;





}A;



A a,b;

void foo(void)

{



a.x = 1;

a.y = 2;

a.z = 3;

//bug here

b = a;

// bug here

}



when copying structs the compiler seems to be stuck in an endless loop,

my question is to which RTL insns do the assignment struct operator is
converted, so I can easily fix this up.



if it doesn't concerning RTL, then how could I find out where does the
compiler is looping?





P.S.

when working with only two data types in the struct (int x, and int y)
this bug does not occur. perhaps it is some kind of alignment bug?

thanks.

omer

--
Omer Medan
omer.medan@xxxxxxxxx

[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