Bug 19496 - [4.0 Regression] ICE in gcc.c-torture/execute/ieee/fp-cmp-8.c for x86_64 and i686 with -msse2 -mfpmath=sse
Summary: [4.0 Regression] ICE in gcc.c-torture/execute/ieee/fp-cmp-8.c for x86_64 and ...
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: target (show other bugs)
Version: 4.0.0
: P2 normal
Target Milestone: 4.0.0
Assignee: Richard Henderson
URL:
Keywords: ice-on-valid-code, ssemmx
Depends on:
Blocks:
 
Reported: 2005-01-18 08:44 UTC by Uroš Bizjak
Modified: 2005-01-18 15:42 UTC (History)
1 user (show)

See Also:
Host:
Target: x86_64-*, i686-*
Build:
Known to work:
Known to fail:
Last reconfirmed: 2005-01-18 09:18:20


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Uroš Bizjak 2005-01-18 08:44:40 UTC
Hello!

gcc -msse2 -O1 -mfpmath=sse -da fp-cmp-8f.c 
In file included from fp-cmp-8f.c:2:
fp-cmp-8.c: In function âtest_islessgreaterâ:
fp-cmp-8.c:71: internal compiler error: in ix86_expand_fp_movcc, at
config/i386/i386.c:9813

The problem is that ltgt is not a valid sse_comparison_operator and gcc_assert()
is triggered in i386.c:

(jump_insn 13 12 18 0 (set (pc)
        (if_then_else (ltgt (reg:CCFPU 17 flags)
                (const_int 0 [0x0]))
            (label_ref 20)
            (pc))) 338 {*jcc_1} (nil)
    (expr_list:REG_BR_PROB (const_int 6700 [0x1a2c])
        (nil)))

Uros.
Comment 1 GCC Commits 2005-01-18 11:08:49 UTC
Subject: Bug 19496

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	rth@gcc.gnu.org	2005-01-18 11:08:33

Modified files:
	gcc            : ChangeLog 
	gcc/config/i386: i386.c 

Log message:
	PR target/19496
	* config/i386/i386.c (ix86_expand_fp_movcc): Fail for LTGT and UNEQ.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.7172&r2=2.7173
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/i386/i386.c.diff?cvsroot=gcc&r1=1.779&r2=1.780

Comment 2 Andrew Pinski 2005-01-18 15:42:11 UTC
Fixed.