* [Bug c++/13312] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
@ 2003-12-05 6:34 ` Steve at Zook dot com
2003-12-05 6:39 ` [Bug target/13312] " pinskia at gcc dot gnu dot org
` (9 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Steve at Zook dot com @ 2003-12-05 6:34 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From Steve at Zook dot com 2003-12-05 06:34 -------
Created an attachment (id=5283)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=5283&action=view)
A C++ preprocessed source file to demonstrate the bug
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug target/13312] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
2003-12-05 6:34 ` [Bug c++/13312] " Steve at Zook dot com
@ 2003-12-05 6:39 ` pinskia at gcc dot gnu dot org
2004-01-18 17:55 ` [Bug target/13312] [m68k] " dhazeghi at yahoo dot com
` (8 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-12-05 6:39 UTC (permalink / raw)
To: gcc-bugs
--
What |Removed |Added
----------------------------------------------------------------------------
Component|c++ |target
Keywords| |wrong-code
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug target/13312] [m68k] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
2003-12-05 6:34 ` [Bug c++/13312] " Steve at Zook dot com
2003-12-05 6:39 ` [Bug target/13312] " pinskia at gcc dot gnu dot org
@ 2004-01-18 17:55 ` dhazeghi at yahoo dot com
2004-01-19 5:05 ` bernie at develer dot com
` (7 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: dhazeghi at yahoo dot com @ 2004-01-18 17:55 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From dhazeghi at yahoo dot com 2004-01-18 17:54 -------
Bernardo, you frequently build for this target. Would you mind commenting on
this report? Thanks.
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |bernie at develer dot com
Summary|C++ produces stack frame |[m68k] C++ produces stack
|damaging code for Coldfire |frame damaging code for
| |Coldfire
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug target/13312] [m68k] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
` (2 preceding siblings ...)
2004-01-18 17:55 ` [Bug target/13312] [m68k] " dhazeghi at yahoo dot com
@ 2004-01-19 5:05 ` bernie at develer dot com
2004-01-21 17:00 ` dhazeghi at yahoo dot com
` (6 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: bernie at develer dot com @ 2004-01-19 5:05 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bernie at develer dot com 2004-01-19 05:05 -------
I've tried to reproduce this problem with:
- GCC 3.4 (20040114) + Andreas cc0 patch
- GCC 3.3.3 (20031222) + my ColdFire/uClinux patch set
In both cases, the generated code seems to be correct, assuming
I'm looking at the same variable:
GCC 3.4:
move.w %d0,-2(%a6)
[...]
clr.l %d0
move.w -2(%a6),%d0
add.l %d0,88(%a5)
move.w 94(%a5),%d0
GCC 3.3.3:
move.w %d0,-6(%a6)
[...]
clr.l %d0
move.w -6(%a6),%d0
add.l %d0,88(%a4)
move.w 94(%a4),%d0
Please test with the latest 3_3-branch snapshot. If you
still see the problem, try applying all these patches in
the given order:
http://www.develer.com/uclinux/uclinux-tools-20031230/gcc-3.3.2-coldfire-targets.patch
http://www.develer.com/uclinux/uclinux-tools-20031230/gcc-3.3.2-coldfire-frame.patch
http://www.develer.com/uclinux/uclinux-tools-20031230/gcc-3.3.2-uclinux-idshlib.patch
http://www.develer.com/uclinux/uclinux-tools-20031230/gcc-3.3.2-uclinux-thunk.patch
http://www.develer.com/uclinux/uclinux-tools-20031230/gcc-3.3.2-uclinux-specs.patch
http://www.develer.com/uclinux/uclinux-tools-20031230/gcc-3.3.2-coldfire-omitfrmptr.patch
The uClinux patches are not relevant to you, but you need
them in order to apply dependent ColdFire patches.
If any of these patches fixes the problem for you, I'll prepare
a standalone version that applies to 3_3-branch and submit it
for this PR.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug target/13312] [m68k] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
` (3 preceding siblings ...)
2004-01-19 5:05 ` bernie at develer dot com
@ 2004-01-21 17:00 ` dhazeghi at yahoo dot com
2004-01-24 7:08 ` Steve at Zook dot com
` (5 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: dhazeghi at yahoo dot com @ 2004-01-21 17:00 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From dhazeghi at yahoo dot com 2004-01-21 17:00 -------
Stepehen, would it be possible for you to check 3.3 branch with the patches Bernie mentioned to
see if this is still present? Thanks.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |WAITING
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug target/13312] [m68k] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
` (4 preceding siblings ...)
2004-01-21 17:00 ` dhazeghi at yahoo dot com
@ 2004-01-24 7:08 ` Steve at Zook dot com
2004-01-25 5:01 ` Steve at Zook dot com
` (4 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Steve at Zook dot com @ 2004-01-24 7:08 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From Steve at Zook dot com 2004-01-24 07:08 -------
gcc-3.3-20040119 both with and without Bernardo's patches produces the bug. I
shall try gcc-3.4-20040121.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug target/13312] [m68k] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
` (5 preceding siblings ...)
2004-01-24 7:08 ` Steve at Zook dot com
@ 2004-01-25 5:01 ` Steve at Zook dot com
2004-01-25 9:59 ` bernie at develer dot com
` (3 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: Steve at Zook dot com @ 2004-01-25 5:01 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From Steve at Zook dot com 2004-01-25 05:01 -------
I built gcc-3.4-20040121. It took a little doing because newlib-1.11.0 (the
revision I've been using) had a bunch of fatal compile errors that I had to
fixup (apperently the 3.4 compile is pickier about certain things). The same
problem persists.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug target/13312] [m68k] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
` (6 preceding siblings ...)
2004-01-25 5:01 ` Steve at Zook dot com
@ 2004-01-25 9:59 ` bernie at develer dot com
2004-01-29 3:31 ` dhazeghi at yahoo dot com
` (2 subsequent siblings)
10 siblings, 0 replies; 12+ messages in thread
From: bernie at develer dot com @ 2004-01-25 9:59 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bernie at develer dot com 2004-01-25 09:59 -------
Subject: Re: [m68k] C++ produces stack frame damaging code
for Coldfire
Steve at Zook dot com wrote:
> ------- Additional Comments From Steve at Zook dot com 2004-01-25 05:01 -------
> I built gcc-3.4-20040121. It took a little doing because newlib-1.11.0 (the
> revision I've been using) had a bunch of fatal compile errors that I had to
> fixup (apperently the 3.4 compile is pickier about certain things). The same
> problem persists.
Please submit patches to the newlib guys.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug target/13312] [m68k] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
` (7 preceding siblings ...)
2004-01-25 9:59 ` bernie at develer dot com
@ 2004-01-29 3:31 ` dhazeghi at yahoo dot com
2004-01-29 13:38 ` bernie at develer dot com
2004-06-10 8:03 ` bernie at develer dot com
10 siblings, 0 replies; 12+ messages in thread
From: dhazeghi at yahoo dot com @ 2004-01-29 3:31 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From dhazeghi at yahoo dot com 2004-01-29 03:31 -------
Okay confirmed then. Hopefully somebody'll look at this though...
--
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2004-01-29 03:31:33
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug target/13312] [m68k] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
` (8 preceding siblings ...)
2004-01-29 3:31 ` dhazeghi at yahoo dot com
@ 2004-01-29 13:38 ` bernie at develer dot com
2004-06-10 8:03 ` bernie at develer dot com
10 siblings, 0 replies; 12+ messages in thread
From: bernie at develer dot com @ 2004-01-29 13:38 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bernie at develer dot com 2004-01-29 13:38 -------
I'll hopefully have some time to analyze this regression
along with a few other m68k target bugs after the next week.
Of course, I wouldn't mind if sombody else can fix it
before I do :-)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug target/13312] [m68k] C++ produces stack frame damaging code for Coldfire
2003-12-05 6:31 [Bug c++/13312] New: C++ produces stack frame damaging code for Coldfire Steve at Zook dot com
` (9 preceding siblings ...)
2004-01-29 13:38 ` bernie at develer dot com
@ 2004-06-10 8:03 ` bernie at develer dot com
10 siblings, 0 replies; 12+ messages in thread
From: bernie at develer dot com @ 2004-06-10 8:03 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From bernie at develer dot com 2004-06-10 08:03 -------
This patch does indeed fix the bug:
http://gcc.gnu.org/ml/gcc/2004-05/msg01357.html
2004-05-27 Peter Jakubek <peter@laseranimation.com>
* reload.c (find_reloads): force reload for pseudo registers on big
endian machines.
The generated code to increment the word at -2(a6) with the
patch applied looks like this:
move.w -2(%a6),%d7
moveq #1,%d4
add.l %d4,%d7
move.w %d7,-2(%a6)
jbra .L122
*** This bug has been marked as a duplicate of 8309 ***
--
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |DUPLICATE
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13312
^ permalink raw reply [flat|nested] 12+ messages in thread