public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/40301] New: [4.3 regression] SH: miscompile with -O2 -fPIC
@ 2009-05-30 3:36 sugioka at itonet dot co dot jp
2009-05-30 3:39 ` [Bug target/40301] " sugioka at itonet dot co dot jp
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: sugioka at itonet dot co dot jp @ 2009-05-30 3:36 UTC (permalink / raw)
To: gcc-bugs
'perl-5.10.0' build with gcc-4.3.[234] segfaults due to wrong code.
Reproduce with cross compiler : sh-linux-gcc -m4 -O2 -g -fPIC -S perl.i
Problematic part of generated code is as follows.
(segfaults at source line 5182.)
.loc 1 5179 0
mov.l @(32,r14),r0 <-- r0 is loaded here
.L2504:
mov.w .L2314,r3
add r0,r3
mov.l @(24,r3),r1
mov.l r1,@(28,r3)
.loc 1 5180 0
mov.w .L2315,r1
add r0,r1
.loc 1 5181 0
mov.w .L2316,r0 <-- r0 is clobberd
.loc 1 5180 0
mov.l r1,@(36,r3)
.loc 1 5181 0
mov.l @(36,r3),r2
mov.l @(r0,r14),r1
mov.l r1,@(20,r2)
.loc 1 5182 0
mov.w .L2317,r1
mov.l @(r0,r1),r0 <-- segfaults here (wrong r0)
and #4,r0
tst r0,r0
--
Summary: [4.3 regression] SH: miscompile with -O2 -fPIC
Product: gcc
Version: 4.3.4
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: target
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: sugioka at itonet dot co dot jp
GCC build triplet: sh4-unknown-linux-gnu
GCC host triplet: sh4-unknown-linux-gnu
GCC target triplet: sh4-unknown-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40301
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug target/40301] [4.3 regression] SH: miscompile with -O2 -fPIC
2009-05-30 3:36 [Bug target/40301] New: [4.3 regression] SH: miscompile with -O2 -fPIC sugioka at itonet dot co dot jp
@ 2009-05-30 3:39 ` sugioka at itonet dot co dot jp
2009-05-30 7:12 ` kkojima at gcc dot gnu dot org
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: sugioka at itonet dot co dot jp @ 2009-05-30 3:39 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from sugioka at itonet dot co dot jp 2009-05-30 03:39 -------
Created an attachment (id=17934)
--> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=17934&action=view)
preprocessed code
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40301
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug target/40301] [4.3 regression] SH: miscompile with -O2 -fPIC
2009-05-30 3:36 [Bug target/40301] New: [4.3 regression] SH: miscompile with -O2 -fPIC sugioka at itonet dot co dot jp
2009-05-30 3:39 ` [Bug target/40301] " sugioka at itonet dot co dot jp
@ 2009-05-30 7:12 ` kkojima at gcc dot gnu dot org
2009-05-30 9:50 ` rguenth at gcc dot gnu dot org
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: kkojima at gcc dot gnu dot org @ 2009-05-30 7:12 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from kkojima at gcc dot gnu dot org 2009-05-30 07:12 -------
It seems that gcc-4.3 hits PR30807 again for SH. Could you try
Christian's patch in the audit trail #2 of 30807 or Joern's
patch in the URL suggested at #4?
--
kkojima at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
Keywords| |wrong-code
Priority|P3 |P4
Last reconfirmed|0000-00-00 00:00:00 |2009-05-30 07:12:02
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40301
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug target/40301] [4.3 regression] SH: miscompile with -O2 -fPIC
2009-05-30 3:36 [Bug target/40301] New: [4.3 regression] SH: miscompile with -O2 -fPIC sugioka at itonet dot co dot jp
2009-05-30 3:39 ` [Bug target/40301] " sugioka at itonet dot co dot jp
2009-05-30 7:12 ` kkojima at gcc dot gnu dot org
@ 2009-05-30 9:50 ` rguenth at gcc dot gnu dot org
2009-05-30 15:55 ` sugioka at itonet dot co dot jp
2009-05-30 22:57 ` [Bug rtl-optimization/40301] SH: 4.3 " kkojima at gcc dot gnu dot org
4 siblings, 0 replies; 6+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2009-05-30 9:50 UTC (permalink / raw)
To: gcc-bugs
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Target Milestone|--- |4.3.4
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40301
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug target/40301] [4.3 regression] SH: miscompile with -O2 -fPIC
2009-05-30 3:36 [Bug target/40301] New: [4.3 regression] SH: miscompile with -O2 -fPIC sugioka at itonet dot co dot jp
` (2 preceding siblings ...)
2009-05-30 9:50 ` rguenth at gcc dot gnu dot org
@ 2009-05-30 15:55 ` sugioka at itonet dot co dot jp
2009-05-30 22:57 ` [Bug rtl-optimization/40301] SH: 4.3 " kkojima at gcc dot gnu dot org
4 siblings, 0 replies; 6+ messages in thread
From: sugioka at itonet dot co dot jp @ 2009-05-30 15:55 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from sugioka at itonet dot co dot jp 2009-05-30 15:55 -------
Thanks for your reply.
I tried Christian's patch and Joern's patch on x86 cross distcc environment.
Both of them worked for my case.
Thanks.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40301
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug rtl-optimization/40301] SH: 4.3 miscompile with -O2 -fPIC
2009-05-30 3:36 [Bug target/40301] New: [4.3 regression] SH: miscompile with -O2 -fPIC sugioka at itonet dot co dot jp
` (3 preceding siblings ...)
2009-05-30 15:55 ` sugioka at itonet dot co dot jp
@ 2009-05-30 22:57 ` kkojima at gcc dot gnu dot org
4 siblings, 0 replies; 6+ messages in thread
From: kkojima at gcc dot gnu dot org @ 2009-05-30 22:57 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from kkojima at gcc dot gnu dot org 2009-05-30 22:56 -------
Thanks for confirmation. Then this is a duplicate of PR30807
and a long standing problem of postreload and not a regression.
The problem is that we have no handy test cases for trunk.
Every time this pops up only on older releases and is latent
on mainline at that time. I'll try again to get a test case
on trunk.
*** This bug has been marked as a duplicate of 30807 ***
--
kkojima at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Component|target |rtl-optimization
Resolution| |DUPLICATE
Summary|[4.3 regression] SH: |SH: 4.3 miscompile with -O2
|miscompile with -O2 -fPIC |-fPIC
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40301
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2009-05-30 22:57 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-05-30 3:36 [Bug target/40301] New: [4.3 regression] SH: miscompile with -O2 -fPIC sugioka at itonet dot co dot jp
2009-05-30 3:39 ` [Bug target/40301] " sugioka at itonet dot co dot jp
2009-05-30 7:12 ` kkojima at gcc dot gnu dot org
2009-05-30 9:50 ` rguenth at gcc dot gnu dot org
2009-05-30 15:55 ` sugioka at itonet dot co dot jp
2009-05-30 22:57 ` [Bug rtl-optimization/40301] SH: 4.3 " kkojima 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).