public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/19307] New: ICE with -msse2 -mno-80387
@ 2005-01-07  9:53 uros at kss-loka dot si
  2005-01-07 14:05 ` [Bug target/19307] [4.0 Regression] " pinskia at gcc dot gnu dot org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: uros at kss-loka dot si @ 2005-01-07  9:53 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1529 bytes --]

This testcase:

double test (double a, double b) {
  double x;

  x = (a < b) ? a : 1.0;
  return x;
}

will ICE with '-O2 -mno-80387 -msse2':

cmove.c: In function âtestâ:
cmove.c:6: error: unrecognizable insn:
(insn 64 55 52 (parallel [
            (set (reg:XF 9 st(1))
                (reg:XF 8 st))
            (set (reg:XF 8 st)
                (reg:XF 9 st(1)))
        ]) -1 (nil)
    (nil))
cmove.c:6: internal compiler error: in insn_default_length, at insn-attrtab.c:408
Please submit a full bug report,

Without -msse2, there is no ICE, but code still uses FP regs.

test:
        pushl   %ebp
        movl    %esp, %ebp
        subl    $24, %esp
        fldl    16(%ebp)
        fstpl   8(%esp)
        fldl    8(%ebp)
        fstpl   (%esp)
        call    __ltdf2
        fldl    8(%ebp)
        testl   %eax, %eax
        jns     .L8
        leave
        ret
        .p2align 4,,7
.L8:
        fstp    %st(0)
        leave
        fld1
        .p2align 4,,2
        ret

-- 
           Summary: ICE with -msse2 -mno-80387
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: uros at kss-loka dot si
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: pentium4-pc-linux-gnu
  GCC host triplet: pentium4-pc-linux-gnu
GCC target triplet: pentium4-pc-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19307


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug target/19307] [4.0 Regression] ICE with -msse2 -mno-80387
  2005-01-07  9:53 [Bug target/19307] New: ICE with -msse2 -mno-80387 uros at kss-loka dot si
@ 2005-01-07 14:05 ` pinskia at gcc dot gnu dot org
  2005-01-10  0:52 ` pinskia at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-01-07 14:05 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-01-07 14:05 -------
Confirmed, it had worked with 4.0.0 20041124 and 3.4.0 so this is a regression.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
           Keywords|                            |ice-on-valid-code
      Known to fail|                            |4.0.0
      Known to work|                            |3.4.0
   Last reconfirmed|0000-00-00 00:00:00         |2005-01-07 14:05:02
               date|                            |
            Summary|ICE with -msse2 -mno-80387  |[4.0 Regression] ICE with -
                   |                            |msse2 -mno-80387
   Target Milestone|---                         |4.0.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19307


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug target/19307] [4.0 Regression] ICE with -msse2 -mno-80387
  2005-01-07  9:53 [Bug target/19307] New: ICE with -msse2 -mno-80387 uros at kss-loka dot si
  2005-01-07 14:05 ` [Bug target/19307] [4.0 Regression] " pinskia at gcc dot gnu dot org
@ 2005-01-10  0:52 ` pinskia at gcc dot gnu dot org
  2005-01-12  0:20 ` rth at gcc dot gnu dot org
  2005-01-12 12:43 ` uros at kss-loka dot si
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-01-10  0:52 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-01-10 00:52 -------
It also worked with 2004-12-11.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19307


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug target/19307] [4.0 Regression] ICE with -msse2 -mno-80387
  2005-01-07  9:53 [Bug target/19307] New: ICE with -msse2 -mno-80387 uros at kss-loka dot si
  2005-01-07 14:05 ` [Bug target/19307] [4.0 Regression] " pinskia at gcc dot gnu dot org
  2005-01-10  0:52 ` pinskia at gcc dot gnu dot org
@ 2005-01-12  0:20 ` rth at gcc dot gnu dot org
  2005-01-12 12:43 ` uros at kss-loka dot si
  3 siblings, 0 replies; 5+ messages in thread
From: rth at gcc dot gnu dot org @ 2005-01-12  0:20 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From rth at gcc dot gnu dot org  2005-01-12 00:19 -------
And it works with today's compiler too.

As for the use of the 80387 move instructions, even with -mno-80387,
this isn't a regression.  At least 3.2 did this as well.  One could
argue that -msoft-float should imply -mno-fp-ret-in-387, but it doesn't.
Changing it now would be an ABI change that I'm not interested in making,
considering the lack of use this option gets.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |WORKSFORME


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19307


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug target/19307] [4.0 Regression] ICE with -msse2 -mno-80387
  2005-01-07  9:53 [Bug target/19307] New: ICE with -msse2 -mno-80387 uros at kss-loka dot si
                   ` (2 preceding siblings ...)
  2005-01-12  0:20 ` rth at gcc dot gnu dot org
@ 2005-01-12 12:43 ` uros at kss-loka dot si
  3 siblings, 0 replies; 5+ messages in thread
From: uros at kss-loka dot si @ 2005-01-12 12:43 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From uros at kss-loka dot si  2005-01-12 12:43 -------
(In reply to comment #3)
> And it works with today's compiler too.

It works with '-O2 -mno-80387 -msse2 -mno-fp-ret-in-387', but without
-mno-fp-ret-in-387 it still fails. I think that the problem here is again SSE FP
compare that gets splitted to x87 compare, when the output value is returned in
x87 reg.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19307


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2005-01-12 12:43 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-01-07  9:53 [Bug target/19307] New: ICE with -msse2 -mno-80387 uros at kss-loka dot si
2005-01-07 14:05 ` [Bug target/19307] [4.0 Regression] " pinskia at gcc dot gnu dot org
2005-01-10  0:52 ` pinskia at gcc dot gnu dot org
2005-01-12  0:20 ` rth at gcc dot gnu dot org
2005-01-12 12:43 ` uros at kss-loka dot si

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).