This is the mail archive of the gcc-bugs@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: Bad code from egcs-1.1b


Hi Gary,

did you get any response on your report? I couldn't find anything in the
archives.
I would like to have a fix in egcs-1.1.1 for this problem, cause I assume
this causes the mouse select bug with qt-1.4x, which also affects the x86
people.

Or is there already a fix in the mainline for this? (you'll need a small
patch to rtlanal.c I posted last week to bootstrap on powerpc-linux).

Franz.



At 08:41 28.09.98 , Gary Thomas wrote:
>I've finally tracked down the code-gen problems with EGCS-1.1b.
>It seems that it's possible to have a piece of code that creates
>an object, with appropriate error handling setup code, that does
>not destroy the object or clean up the error handler on exit.
>
>On the PowerPC (at least) this has very serious side effects.  In
>particular, the error handler objects are on the stack which has
>now been popped away.  When the next error handler create/cleanup
>runs it accesses invalid stack locations and the program fails
>miserably.
>
>I've attached a very small C++ program along with the generated
>assembly code.  The assembly has been hand edited with some "###(n)"
>comments to help you associate the C++ code with the assembly.
>I don't know of a way to write a test case that can properly test
>this, sorry.
>
>Details:
>
>/opt/egcs/lib/gcc-lib/powerpc-unknown-linux-gnulibc1/egcs-2.91.57/specs
>gcc version egcs-2.91.57 19980901 (egcs-1.1 release)
>
>g++ -O2 -Wall -fno-inline -S bug2.cpp
>
>
>I'll try another configuration (Linux/x86) today to see if it has
>similar problems.
>
>
>



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