Thread View: gnu.g++.bug
1 messages
1 total messages
Started by "Douglas C. Schmidt"
Tue, 29 Nov 1988 22:12
program kills g++ 1.27 on sparc
Author: "Douglas C. Schmidt"
Date: Tue, 29 Nov 1988 22:12
Date: Tue, 29 Nov 1988 22:12
46 lines
1717 bytes
1717 bytes
Hi,
The following short program causes a segmentation violation on the
sun 4 when compiled with the -O option with g++ 1.27.
----------------------------------------
/* kills sparc with -O */
typedef struct _XRegion *Region;
typedef struct {
short x, y;
unsigned short width, height;
} XRectangle;
static Region HighlightRegion()
{
static Region outerRegion = 0, innerRegion, emptyRegion;
XRectangle rect;
rect.x = rect.y = 0;
XUnionRectWithRegion( &rect, emptyRegion, innerRegion );
XSubtractRegion( outerRegion, innerRegion, outerRegion );
return outerRegion;
}
----------------------------------------
Here is the diagnostic:
----------------------------------------
g++ version 1.27.0
echo use .cc filename extension!
use .cc filename extension!
/usr/public/lib/g++/gcc-cpp+ -v -undef -D__GNU__ -D__GNUG__ -Dsparc
-Dsun -Dunix -D__OPTIMIZE__ -+ crash-bug.1.31.c /tmp/cca05565.cpp
GNU CPP version 1.27.0
/usr/public/lib/g++/gcc-c++ /tmp/cca05565.cpp -quiet -dumpbase
crash-bug.1.31.c -O -version -o /tmp/cca05565.s
crash-bug.1.31.c:15: Segmentation violation
/usr/public/g++: Program c++ got fatal signal 11.
----------------------------------------
Doug
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads