public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4
@ 2005-01-25 17:15 michael dot schwingen at lancom dot de
  2005-01-25 17:16 ` [Bug rtl-optimization/19627] " michael dot schwingen at lancom dot de
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: michael dot schwingen at lancom dot de @ 2005-01-25 17:15 UTC (permalink / raw)
  To: gcc-bugs

gcc generates wrong code on the test case when called with
/opt/cgcc-3.4.3-20050125/bin/sh-elf-gcc -m4 -S -Os -fomit-frame-pointer test2.c

Adding -fno-if-conversion2 creates working code. It seems that the code that
modifies the stack pointer to make space for function arguments is shifted
across a branch to a point where some paths through the function end up with a
wrong stack pointer at the end.

Attached: test2.c, test2.s, test2.c.27.flow2, test2.c.29.ce3

-- 
           Summary: if-conversion2 generates wrong code / crash on SH4
           Product: gcc
           Version: 3.4.3
            Status: UNCONFIRMED
          Severity: critical
          Priority: P2
         Component: rtl-optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: michael dot schwingen at lancom dot de
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: unknown-i686-linux
  GCC host triplet: unknown-i686-linux
GCC target triplet: unknown-sh-elf


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


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

* [Bug rtl-optimization/19627] if-conversion2 generates wrong code / crash on SH4
  2005-01-25 17:15 [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4 michael dot schwingen at lancom dot de
@ 2005-01-25 17:16 ` michael dot schwingen at lancom dot de
  2005-01-25 17:17 ` michael dot schwingen at lancom dot de
                   ` (7 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: michael dot schwingen at lancom dot de @ 2005-01-25 17:16 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From michael dot schwingen at lancom dot de  2005-01-25 17:15 -------
Created an attachment (id=8063)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=8063&action=view)
C source code


-- 


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


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

* [Bug rtl-optimization/19627] if-conversion2 generates wrong code / crash on SH4
  2005-01-25 17:15 [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4 michael dot schwingen at lancom dot de
  2005-01-25 17:16 ` [Bug rtl-optimization/19627] " michael dot schwingen at lancom dot de
@ 2005-01-25 17:17 ` michael dot schwingen at lancom dot de
  2005-01-25 17:18 ` pinskia at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: michael dot schwingen at lancom dot de @ 2005-01-25 17:17 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From michael dot schwingen at lancom dot de  2005-01-25 17:17 -------
Created an attachment (id=8066)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=8066&action=view)
first wrong RTL


-- 


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


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

* [Bug rtl-optimization/19627] if-conversion2 generates wrong code / crash on SH4
  2005-01-25 17:15 [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4 michael dot schwingen at lancom dot de
                   ` (2 preceding siblings ...)
  2005-01-25 17:18 ` pinskia at gcc dot gnu dot org
@ 2005-01-25 17:18 ` michael dot schwingen at lancom dot de
  2005-01-25 17:21 ` michael dot schwingen at lancom dot de
                   ` (4 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: michael dot schwingen at lancom dot de @ 2005-01-25 17:18 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From michael dot schwingen at lancom dot de  2005-01-25 17:16 -------
Created an attachment (id=8064)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=8064&action=view)
assembler output containing wrong code


-- 


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


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

* [Bug rtl-optimization/19627] if-conversion2 generates wrong code / crash on SH4
  2005-01-25 17:15 [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4 michael dot schwingen at lancom dot de
  2005-01-25 17:16 ` [Bug rtl-optimization/19627] " michael dot schwingen at lancom dot de
  2005-01-25 17:17 ` michael dot schwingen at lancom dot de
@ 2005-01-25 17:18 ` pinskia at gcc dot gnu dot org
  2005-01-25 17:18 ` michael dot schwingen at lancom dot de
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-01-25 17:18 UTC (permalink / raw)
  To: gcc-bugs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|critical                    |normal
  GCC build triplet|unknown-i686-linux          |
   GCC host triplet|unknown-i686-linux          |
 GCC target triplet|unknown-sh-elf              |sh-elf
           Keywords|                            |ice-on-valid-code, wrong-
                   |                            |code


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


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

* [Bug rtl-optimization/19627] if-conversion2 generates wrong code / crash on SH4
  2005-01-25 17:15 [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4 michael dot schwingen at lancom dot de
                   ` (3 preceding siblings ...)
  2005-01-25 17:18 ` michael dot schwingen at lancom dot de
@ 2005-01-25 17:21 ` michael dot schwingen at lancom dot de
  2005-02-24 22:40 ` amylaar at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: michael dot schwingen at lancom dot de @ 2005-01-25 17:21 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From michael dot schwingen at lancom dot de  2005-01-25 17:17 -------
Created an attachment (id=8065)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=8065&action=view)
last correct RTL 


-- 


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


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

* [Bug rtl-optimization/19627] if-conversion2 generates wrong code / crash on SH4
  2005-01-25 17:15 [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4 michael dot schwingen at lancom dot de
                   ` (4 preceding siblings ...)
  2005-01-25 17:21 ` michael dot schwingen at lancom dot de
@ 2005-02-24 22:40 ` amylaar at gcc dot gnu dot org
  2005-02-24 22:51 ` amylaar at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 10+ messages in thread
From: amylaar at gcc dot gnu dot org @ 2005-02-24 22:40 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From amylaar at gcc dot gnu dot org  2005-02-24 18:44 -------
STack management appears sane when using gcc 4.0.0 20050224 .

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to work|                            |4.0.0


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


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

* [Bug rtl-optimization/19627] if-conversion2 generates wrong code / crash on SH4
  2005-01-25 17:15 [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4 michael dot schwingen at lancom dot de
                   ` (5 preceding siblings ...)
  2005-02-24 22:40 ` amylaar at gcc dot gnu dot org
@ 2005-02-24 22:51 ` amylaar at gcc dot gnu dot org
  2005-02-25  1:05 ` amylaar at gcc dot gnu dot org
  2005-07-31  2:38 ` pinskia at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: amylaar at gcc dot gnu dot org @ 2005-02-24 22:51 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From amylaar at gcc dot gnu dot org  2005-02-24 18:56 -------
3.4.4 20050125 shows the problem.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
      Known to fail|                            |3.4.4
   Last reconfirmed|0000-00-00 00:00:00         |2005-02-24 18:56:31
               date|                            |


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


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

* [Bug rtl-optimization/19627] if-conversion2 generates wrong code / crash on SH4
  2005-01-25 17:15 [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4 michael dot schwingen at lancom dot de
                   ` (6 preceding siblings ...)
  2005-02-24 22:51 ` amylaar at gcc dot gnu dot org
@ 2005-02-25  1:05 ` amylaar at gcc dot gnu dot org
  2005-07-31  2:38 ` pinskia at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: amylaar at gcc dot gnu dot org @ 2005-02-25  1:05 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From amylaar at gcc dot gnu dot org  2005-02-24 20:31 -------
A patch is here:
http://gcc.gnu.org/ml/gcc-patches/2004-04/msg01280.html

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |joern dot rennecke at st dot
                   |                            |com, mark at codesourcery
                   |                            |dot com
           Keywords|                            |patch


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


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

* [Bug rtl-optimization/19627] if-conversion2 generates wrong code / crash on SH4
  2005-01-25 17:15 [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4 michael dot schwingen at lancom dot de
                   ` (7 preceding siblings ...)
  2005-02-25  1:05 ` amylaar at gcc dot gnu dot org
@ 2005-07-31  2:38 ` pinskia at gcc dot gnu dot org
  8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-07-31  2:38 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2005-07-31 02:35 -------
Fixed in 4.0.0.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|---                         |4.0.0


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


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

end of thread, other threads:[~2005-07-31  2:35 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-01-25 17:15 [Bug rtl-optimization/19627] New: if-conversion2 generates wrong code / crash on SH4 michael dot schwingen at lancom dot de
2005-01-25 17:16 ` [Bug rtl-optimization/19627] " michael dot schwingen at lancom dot de
2005-01-25 17:17 ` michael dot schwingen at lancom dot de
2005-01-25 17:18 ` pinskia at gcc dot gnu dot org
2005-01-25 17:18 ` michael dot schwingen at lancom dot de
2005-01-25 17:21 ` michael dot schwingen at lancom dot de
2005-02-24 22:40 ` amylaar at gcc dot gnu dot org
2005-02-24 22:51 ` amylaar at gcc dot gnu dot org
2005-02-25  1:05 ` amylaar at gcc dot gnu dot org
2005-07-31  2:38 ` pinskia at gcc dot gnu dot org

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).