This is the mail archive of the gcc-prs@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]
Other format: [Raw text]

c/5160: gcc 3.0.2 ICE on Alpha in extract_insn, at recog.c:2218



>Number:         5160
>Category:       c
>Synopsis:       gcc 3.0.2 ICE on Alpha in extract_insn, at recog.c:2218
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          ice-on-legal-code
>Submitter-Id:   net
>Arrival-Date:   Tue Dec 18 19:36:00 PST 2001
>Closed-Date:
>Last-Modified:
>Originator:     Tom Holroyd
>Release:        3.0.2
>Organization:
Kansai Advanced Research Center
>Environment:
System: Linux holly 2.4.14 #2 Tue Nov 6 12:10:19 JST 2001 alpha unknown
Architecture: alpha

	
host: alphaev67-unknown-linux-gnu
build: alphaev67-unknown-linux-gnu
target: alphaev67-unknown-linux-gnu
configured with: ../gcc-3.0.2/configure --disable-nls

>Description:

The following code (in file gccbug.c):

void moo(void)
{
	int i, c, m;
	float x, y;

	for (i = 0; i < c; i++) {
		m = 0;
		if (x + y < 0.) m |= 1;
		if (m) x = 1.;
	}
}

produces:

% gcc -O2 -ffast-math -c gccbug.c
gccbug.c: In function `moo':
gccbug.c:11: Unrecognizable insn:
(insn 89 28 90 (set (reg:DF 86)
	(ge:DF (reg:DF 76)
	    (const_double:DF (cc0) 0 [0x0] 0 [0x0] [0]))) -1 (insn_list 28 (nil))
    (expr_list:REG_DEAD (reg:DF 76)
	(nil)))
gccbug.c:11: Internal compiler error in extract_insn, at recog.c:2218
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.

This code was originally from Mesa-4.0.2; this error causes Mesa to fail
to build on Alpha.  I have the latest binutils.

GNU ld version 2.11.2 (with BFD 2.11.2)

>How-To-Repeat:
As above.
>Fix:
Removing -ffast-math fixes it, or using -O1.  Changing almost anything in
the above code makes the error go away, including removing the "|", making
the "<" into a "==", changing the "1." to a "0.", removing lines, etc.
This is about as minimal as I could make it.
>Release-Note:
>Audit-Trail:
>Unformatted:


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