This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: gcc miscompiles gcj @ -O2



Bryce McKinlay writes:

> Then all is well. It also works fine if compiled with an older
> compiler, such as Red Hat's 2.96 or anything earlier. The diff
> between the asm output is as follows. Note how the exit_block call
> is made later in the "broken" method.

I once did the same thing turning the tree code check code off, I got
much less assembly, and I just noticed an extra stack slot allocated
for the local variable, and saw the returned value stored in the local
before the local got transfered back in the structure's field. I
didn't get a chance to single step through both version of the code.

I'll try that again if I get a chance to.

./A

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]