gcc 2.95.2 PPC code generation bug(New version!)
Ralph Schmidt
laire@basis.owl.de
Tue May 2 05:39:00 GMT 2000
You wrote:
> At 12:11 02.05.00, Ralph Schmidt wrote:
>
> >You wrote: > > Yes, that looks OK, but in fact I did quote Ralph
> >incorrectly, he wrote: > > int result = ({ > struct test mytest; > { >
> >int testi; > testi = func (&mytest); > testi; > } > }); > > which
> >compiles, but is no valid statement expression... >
> >
> >Franz...if it's no valid statement expression explain me why it works
> >99.999% of the time for ppc and 100% for 68k.
> >
>
> Optimization? Stack layout? Luck? There are a number of reasons this could
> happen if you are relying on undefined behaviour.
>
I tested it right now on the small test case and on x mui classes and you
were right.......not that i really understand the effect though.
If the result of this inline would be undefined it wouldn't only fail with this
special case, so i think it's better to understand the cause exactly instead
of skipping it because a workaround is found.
Regards
---
Ralph Schmidt,laire@popmail.owl.de(private),NextMail welcome
More information about the Gcc-bugs
mailing list