public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/35616] New: Incorrect code while O2 compling
@ 2008-03-17 16:24 J dot Gorka at osmosys dot tv
2008-03-17 16:41 ` [Bug middle-end/35616] " pinskia at gcc dot gnu dot org
` (21 more replies)
0 siblings, 22 replies; 23+ messages in thread
From: J dot Gorka at osmosys dot tv @ 2008-03-17 16:24 UTC (permalink / raw)
To: gcc-bugs
While compling program below (3 files) with O2 or O3 option, code is generated
not properly (SF).
/******************************************************************************/
file 1:
gcc_bug.c
#include <stdio.h>
#include "function.h"
static void my_listener(
int a,
int b,
int c)
{
printf("It works!!!\n");
}
static struct data_t data;
int main()
{
data.listener = my_listener;
data.a = 11;
data.b = 22;
data.c = 33; /* with O2 compiling, function_calling_listener try call
function with address 33,
not my_listener address */
data.d = 44;
function_calling_listener(data);
return 0;
}
/******************************************************************************/
file 2:
function.h
typedef void (*listener_fun)(
int a,
int b,
int c);
struct data_t
{
int a;
listener_fun listener;
int b;
int c;
int d;
};
void function_calling_listener (struct data_t data);
/******************************************************************************/
file 3:
function.c
#include "function.h"
void function_calling_listener (struct data_t data)
{
data.listener(data.a, data.c, data.d);
}
/******************************************************************************/
GCC VERSION:
gcc --version
gcc (GCC) 4.1.2 20070626 (Red Hat 4.1.2-13)
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
--
Summary: Incorrect code while O2 compling
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: J dot Gorka at osmosys dot tv
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
@ 2008-03-17 16:41 ` pinskia at gcc dot gnu dot org
2008-03-17 17:13 ` J dot Gorka at osmosys dot tv
` (20 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-03-17 16:41 UTC (permalink / raw)
To: gcc-bugs
------- Comment #1 from pinskia at gcc dot gnu dot org 2008-03-17 16:40 -------
> gcc (GCC) 4.1.2 20070626 (Red Hat 4.1.2-13)
Please try 4.2.3 or 4.3.0. Also you should have reported this to RedHat first
as it is their modified compiler.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Component|c |middle-end
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
2008-03-17 16:41 ` [Bug middle-end/35616] " pinskia at gcc dot gnu dot org
@ 2008-03-17 17:13 ` J dot Gorka at osmosys dot tv
2008-03-18 7:58 ` J dot Gorka at osmosys dot tv
` (19 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: J dot Gorka at osmosys dot tv @ 2008-03-17 17:13 UTC (permalink / raw)
To: gcc-bugs
------- Comment #2 from J dot Gorka at osmosys dot tv 2008-03-17 17:12 -------
The same problem on that version. I don't think that is Red Hat specific
problem...
Using built-in specs.
Target: i486-linux-gnu
Configured with: ../src/configure -v
--enable-languages=c,c++,fortran,objc,obj-c++,treelang --prefix=/usr
--enable-shared --
Thread model: posix
gcc version 4.1.2 20061028 (prerelease) (Debian 4.1.1-19)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
2008-03-17 16:41 ` [Bug middle-end/35616] " pinskia at gcc dot gnu dot org
2008-03-17 17:13 ` J dot Gorka at osmosys dot tv
@ 2008-03-18 7:58 ` J dot Gorka at osmosys dot tv
2008-03-18 8:02 ` pinskia at gcc dot gnu dot org
` (18 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: J dot Gorka at osmosys dot tv @ 2008-03-18 7:58 UTC (permalink / raw)
To: gcc-bugs
------- Comment #3 from J dot Gorka at osmosys dot tv 2008-03-18 07:57 -------
Ok. Now version 4.3.0 from Debian. The same problem....
gcc-4.3 --version
gcc-4.3 (Debian 4.3.0-1) 4.3.1 20080309 (prerelease)
Copyright (C) 2008 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (2 preceding siblings ...)
2008-03-18 7:58 ` J dot Gorka at osmosys dot tv
@ 2008-03-18 8:02 ` pinskia at gcc dot gnu dot org
2008-03-18 8:18 ` J dot Gorka at osmosys dot tv
` (17 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-03-18 8:02 UTC (permalink / raw)
To: gcc-bugs
------- Comment #4 from pinskia at gcc dot gnu dot org 2008-03-18 08:01 -------
Can you include the contents of function.h, it seems to be missing ?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (3 preceding siblings ...)
2008-03-18 8:02 ` pinskia at gcc dot gnu dot org
@ 2008-03-18 8:18 ` J dot Gorka at osmosys dot tv
2008-03-18 10:52 ` [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] " rguenth at gcc dot gnu dot org
` (16 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: J dot Gorka at osmosys dot tv @ 2008-03-18 8:18 UTC (permalink / raw)
To: gcc-bugs
------- Comment #5 from J dot Gorka at osmosys dot tv 2008-03-18 08:17 -------
All is fine. My friend copy that program from here, compile on gcc-4.3 and give
me result that is in comment #3.... But ok, i copy one more time what is in
function.h file:
typedef void (*listener_fun)(
int a,
int b,
int c);
struct data_t
{
int a;
listener_fun listener;
int b;
int c;
int d;
};
void function_calling_listener (struct data_t data);
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (4 preceding siblings ...)
2008-03-18 8:18 ` J dot Gorka at osmosys dot tv
@ 2008-03-18 10:52 ` rguenth at gcc dot gnu dot org
2008-03-18 14:34 ` ubizjak at gmail dot com
` (15 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2008-03-18 10:52 UTC (permalink / raw)
To: gcc-bugs
------- Comment #6 from rguenth at gcc dot gnu dot org 2008-03-18 10:51 -------
This looks like a target issue.
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |matz at gcc dot gnu dot org
Status|UNCONFIRMED |NEW
Component|middle-end |target
Ever Confirmed|0 |1
GCC target triplet| |i?86-*-*
Keywords| |wrong-code
Known to fail| |3.4.0 4.0.4 4.1.3 4.4.0
Known to work| |3.3.6
Last reconfirmed|0000-00-00 00:00:00 |2008-03-18 10:51:19
date| |
Summary|Incorrect code while O2 |[4.1/4.2/4.3/4.4 Regression]
|compling |Incorrect code while O2
| |compling
Target Milestone|--- |4.1.3
Version|unknown |4.1.2
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (5 preceding siblings ...)
2008-03-18 10:52 ` [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] " rguenth at gcc dot gnu dot org
@ 2008-03-18 14:34 ` ubizjak at gmail dot com
2008-03-18 14:45 ` ubizjak at gmail dot com
` (14 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: ubizjak at gmail dot com @ 2008-03-18 14:34 UTC (permalink / raw)
To: gcc-bugs
------- Comment #7 from ubizjak at gmail dot com 2008-03-18 14:34 -------
asm dump with GCC: (GNU) 4.4.0 20080318 (experimental) and -O2
-fomit-frame-pointer:
function_calling_listener:
movl 20(%esp), %eax # data.d, data.d
movl 16(%esp), %ecx # data.c, data.c
movl %eax, 12(%esp) # data.d,
movl %ecx, 8(%esp) # data.c,
jmp *%ecx # data.c
-O0:
function_calling_listener:
pushl %ebx #
subl $24, %esp #,
movl 36(%esp), %ebx # data.listener, D.1190
movl 48(%esp), %eax # data.d, D.1191
movl 44(%esp), %edx # data.c, D.1192
movl 32(%esp), %ecx # data.a, D.1193
movl %eax, 8(%esp) # D.1191,
movl %edx, 4(%esp) # D.1192,
movl %ecx, (%esp) # D.1193,
call *%ebx # D.1190
addl $24, %esp #,
popl %ebx #
ret
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (6 preceding siblings ...)
2008-03-18 14:34 ` ubizjak at gmail dot com
@ 2008-03-18 14:45 ` ubizjak at gmail dot com
2008-03-18 14:54 ` rguenth at gcc dot gnu dot org
` (13 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: ubizjak at gmail dot com @ 2008-03-18 14:45 UTC (permalink / raw)
To: gcc-bugs
------- Comment #8 from ubizjak at gmail dot com 2008-03-18 14:45 -------
It works when function.c is compiled with -O2 -fno-optimize-sibling-calls.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (7 preceding siblings ...)
2008-03-18 14:45 ` ubizjak at gmail dot com
@ 2008-03-18 14:54 ` rguenth at gcc dot gnu dot org
2008-03-18 14:56 ` matz at gcc dot gnu dot org
` (12 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2008-03-18 14:54 UTC (permalink / raw)
To: gcc-bugs
------- Comment #9 from rguenth at gcc dot gnu dot org 2008-03-18 14:53 -------
The stack modifications before the sibcall look indeed interesting. Micha,
maybe you want to poke into this somewhat?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (8 preceding siblings ...)
2008-03-18 14:54 ` rguenth at gcc dot gnu dot org
@ 2008-03-18 14:56 ` matz at gcc dot gnu dot org
2008-03-18 15:02 ` ubizjak at gmail dot com
` (11 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: matz at gcc dot gnu dot org @ 2008-03-18 14:56 UTC (permalink / raw)
To: gcc-bugs
------- Comment #10 from matz at gcc dot gnu dot org 2008-03-18 14:55 -------
The tree dumps already look wrong. from .130t.final_cleanup:
function_calling_listener (data)
{
<bb 2>:
data (data.a, data.c, data.d) [tail call];
return;
}
Note how the function pointer is replaced with the whole "data" object. Huh?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (9 preceding siblings ...)
2008-03-18 14:56 ` matz at gcc dot gnu dot org
@ 2008-03-18 15:02 ` ubizjak at gmail dot com
2008-03-18 15:04 ` matz at gcc dot gnu dot org
` (10 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: ubizjak at gmail dot com @ 2008-03-18 15:02 UTC (permalink / raw)
To: gcc-bugs
------- Comment #11 from ubizjak at gmail dot com 2008-03-18 15:01 -------
cse1 pass somehow figures out that:
(insn 11 10 12 2 function.c:5 (set (reg/f:SI 61)
(mem/s/f/c:SI (plus:SI (reg/f:SI 16 argp)
(const_int 4 [0x4])) [4 data.listener+0 S4 A32])) 41 {*movsi_1}
(nil))
(call_insn/j 12 11 0 2 function.c:5 (call (mem:QI (reg/f:SI 61) [0 S1 A8])
(const_int 12 [0xc])) 423 {*sibcall_1} (nil)
(nil))
can be substituted with:
(insn 11 10 12 2 function.c:5 (set (reg/f:SI 61 [ data.listener ])
(reg:SI 59 [ data.c ])) 41 {*movsi_1} (nil))
(call_insn/j 12 11 0 2 function.c:5 (call (mem:QI (reg:SI 59 [ data.c ]) [0 S1
A
8])
(const_int 12 [0xc])) 423 {*sibcall_1} (nil)
(nil))
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (10 preceding siblings ...)
2008-03-18 15:02 ` ubizjak at gmail dot com
@ 2008-03-18 15:04 ` matz at gcc dot gnu dot org
2008-03-18 15:26 ` rguenth at gcc dot gnu dot org
` (9 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: matz at gcc dot gnu dot org @ 2008-03-18 15:04 UTC (permalink / raw)
To: gcc-bugs
------- Comment #12 from matz at gcc dot gnu dot org 2008-03-18 15:03 -------
Uros: the problem isn't cse. It's already expand which creates broken code
(it reads from and writes to (mem (plus (virtual-incoming-regs) (4)).
But it does that only because the input tree is completely wrong (TER breaks
this).
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (11 preceding siblings ...)
2008-03-18 15:04 ` matz at gcc dot gnu dot org
@ 2008-03-18 15:26 ` rguenth at gcc dot gnu dot org
2008-03-18 15:30 ` ubizjak at gmail dot com
` (8 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2008-03-18 15:26 UTC (permalink / raw)
To: gcc-bugs
------- Comment #13 from rguenth at gcc dot gnu dot org 2008-03-18 15:25 -------
Actually the trees are correct, just the dumping of function names in call
exprs
is "interesting". Still expand is the primary suspect here.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (12 preceding siblings ...)
2008-03-18 15:26 ` rguenth at gcc dot gnu dot org
@ 2008-03-18 15:30 ` ubizjak at gmail dot com
2008-03-18 15:38 ` matz at gcc dot gnu dot org
` (7 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: ubizjak at gmail dot com @ 2008-03-18 15:30 UTC (permalink / raw)
To: gcc-bugs
------- Comment #14 from ubizjak at gmail dot com 2008-03-18 15:30 -------
(In reply to comment #12)
> Uros: the problem isn't cse. It's already expand which creates broken code
> (it reads from and writes to (mem (plus (virtual-incoming-regs) (4)).
> But it does that only because the input tree is completely wrong (TER breaks
> this).
Yes, looking a bit more into the expand dump, it looks that gcc tries to fix
outgoing call stack by copying 'c' and 'd' into the position of 'listener' and
'b'. It accidentally overwrites 'listener' (and 'b', but this isn't used
anywhere). The code would work OK if 'listener' would be copied to a temporary
first.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (13 preceding siblings ...)
2008-03-18 15:30 ` ubizjak at gmail dot com
@ 2008-03-18 15:38 ` matz at gcc dot gnu dot org
2008-03-18 16:01 ` [Bug middle-end/35616] " matz at gcc dot gnu dot org
` (6 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: matz at gcc dot gnu dot org @ 2008-03-18 15:38 UTC (permalink / raw)
To: gcc-bugs
------- Comment #15 from matz at gcc dot gnu dot org 2008-03-18 15:37 -------
We can either force expanding the call address before the arguments (if
it overlaps with them) or simply validate the thing after the fact.
Validating seems a bit easier (and is in line with what is done already for
the expansion of overlapping arguments). Proof of concept patch:
Index: calls.c
===================================================================
--- calls.c (revision 133304)
+++ calls.c (working copy)
@@ -2756,8 +2756,15 @@ expand_call (tree exp, rtx target, int i
use_reg (&call_fusage, struct_value);
}
- funexp = prepare_call_address (funexp, static_chain_value,
+ {
+ rtx before_arg = get_last_insn ();
+
+ funexp = prepare_call_address (funexp, static_chain_value,
&call_fusage, reg_parm_seen, pass == 0);
+ if (pass == 0
+ && check_sibcall_argument_overlap (before_arg, 0, 0))
+ sibcall_failure = 1;
+ }
load_register_parameters (args, num_actuals, &call_fusage, flags,
pass == 0, &sibcall_failure);
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (14 preceding siblings ...)
2008-03-18 15:38 ` matz at gcc dot gnu dot org
@ 2008-03-18 16:01 ` matz at gcc dot gnu dot org
2008-03-18 17:27 ` rguenth at gcc dot gnu dot org
` (5 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: matz at gcc dot gnu dot org @ 2008-03-18 16:01 UTC (permalink / raw)
To: gcc-bugs
--
matz at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |matz at gcc dot gnu dot org
|dot org |
Status|NEW |ASSIGNED
Component|target |middle-end
Last reconfirmed|2008-03-18 10:51:19 |2008-03-18 16:00:52
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (15 preceding siblings ...)
2008-03-18 16:01 ` [Bug middle-end/35616] " matz at gcc dot gnu dot org
@ 2008-03-18 17:27 ` rguenth at gcc dot gnu dot org
2008-03-19 19:16 ` matz at gcc dot gnu dot org
` (4 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2008-03-18 17:27 UTC (permalink / raw)
To: gcc-bugs
--
rguenth at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P2
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (16 preceding siblings ...)
2008-03-18 17:27 ` rguenth at gcc dot gnu dot org
@ 2008-03-19 19:16 ` matz at gcc dot gnu dot org
2008-03-19 19:39 ` matz at gcc dot gnu dot org
` (3 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: matz at gcc dot gnu dot org @ 2008-03-19 19:16 UTC (permalink / raw)
To: gcc-bugs
------- Comment #16 from matz at gcc dot gnu dot org 2008-03-19 19:15 -------
Subject: Bug 35616
Author: matz
Date: Wed Mar 19 19:15:03 2008
New Revision: 133348
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=133348
Log:
PR middle-end/35616
* calls.c (expand_call): Check overlap of arguments with call
address for sibcalls.
* gcc.dg/pr35616.c: New test.
Added:
trunk/gcc/testsuite/gcc.dg/pr35616.c
Modified:
trunk/gcc/ChangeLog
trunk/gcc/calls.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] [4.1/4.2/4.3/4.4 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (17 preceding siblings ...)
2008-03-19 19:16 ` matz at gcc dot gnu dot org
@ 2008-03-19 19:39 ` matz at gcc dot gnu dot org
2008-03-19 19:41 ` [Bug middle-end/35616] [4.1/4.2 " matz at gcc dot gnu dot org
` (2 subsequent siblings)
21 siblings, 0 replies; 23+ messages in thread
From: matz at gcc dot gnu dot org @ 2008-03-19 19:39 UTC (permalink / raw)
To: gcc-bugs
------- Comment #17 from matz at gcc dot gnu dot org 2008-03-19 19:38 -------
Subject: Bug 35616
Author: matz
Date: Wed Mar 19 19:37:48 2008
New Revision: 133350
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=133350
Log:
Backport from mainline:
PR middle-end/35616
* calls.c (expand_call): Check overlap of arguments with call
address for sibcalls.
* gcc.dg/pr35616.c: New test.
Added:
branches/gcc-4_3-branch/gcc/testsuite/gcc.dg/pr35616.c
- copied unchanged from r133348, trunk/gcc/testsuite/gcc.dg/pr35616.c
Modified:
branches/gcc-4_3-branch/gcc/ChangeLog
branches/gcc-4_3-branch/gcc/calls.c
branches/gcc-4_3-branch/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] [4.1/4.2 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (18 preceding siblings ...)
2008-03-19 19:39 ` matz at gcc dot gnu dot org
@ 2008-03-19 19:41 ` matz at gcc dot gnu dot org
2008-07-04 22:40 ` [Bug middle-end/35616] [4.2 " jsm28 at gcc dot gnu dot org
2009-03-31 15:26 ` jsm28 at gcc dot gnu dot org
21 siblings, 0 replies; 23+ messages in thread
From: matz at gcc dot gnu dot org @ 2008-03-19 19:41 UTC (permalink / raw)
To: gcc-bugs
------- Comment #18 from matz at gcc dot gnu dot org 2008-03-19 19:40 -------
trunk and 4.3 are fixed.
--
matz at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|matz at gcc dot gnu dot org |unassigned at gcc dot gnu
| |dot org
Status|ASSIGNED |NEW
Known to fail|3.4.0 4.0.4 4.1.3 4.4.0 |3.4.0 4.0.4 4.1.3
Priority|P2 |P4
Summary|[4.1/4.2/4.3/4.4 Regression]|[4.1/4.2 Regression]
|Incorrect code while O2 |Incorrect code while O2
|compling |compling
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] [4.2 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (19 preceding siblings ...)
2008-03-19 19:41 ` [Bug middle-end/35616] [4.1/4.2 " matz at gcc dot gnu dot org
@ 2008-07-04 22:40 ` jsm28 at gcc dot gnu dot org
2009-03-31 15:26 ` jsm28 at gcc dot gnu dot org
21 siblings, 0 replies; 23+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2008-07-04 22:40 UTC (permalink / raw)
To: gcc-bugs
------- Comment #19 from jsm28 at gcc dot gnu dot org 2008-07-04 22:40 -------
Closing 4.1 branch.
--
jsm28 at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Summary|[4.1/4.2 Regression] |[4.2 Regression] Incorrect
|Incorrect code while O2 |code while O2 compling
|compling |
Target Milestone|4.1.3 |4.2.5
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
* [Bug middle-end/35616] [4.2 Regression] Incorrect code while O2 compling
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
` (20 preceding siblings ...)
2008-07-04 22:40 ` [Bug middle-end/35616] [4.2 " jsm28 at gcc dot gnu dot org
@ 2009-03-31 15:26 ` jsm28 at gcc dot gnu dot org
21 siblings, 0 replies; 23+ messages in thread
From: jsm28 at gcc dot gnu dot org @ 2009-03-31 15:26 UTC (permalink / raw)
To: gcc-bugs
------- Comment #20 from jsm28 at gcc dot gnu dot org 2009-03-31 15:26 -------
Closing 4.2 branch, fixed for 4.3.1 and 4.4.
--
jsm28 at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Known to fail|3.4.0 4.0.4 4.1.3 4.3.0 |3.4.0 4.0.4 4.1.3 4.3.0
| |4.2.5
Resolution| |FIXED
Target Milestone|4.2.5 |4.3.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35616
^ permalink raw reply [flat|nested] 23+ messages in thread
end of thread, other threads:[~2009-03-31 15:26 UTC | newest]
Thread overview: 23+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-03-17 16:24 [Bug c/35616] New: Incorrect code while O2 compling J dot Gorka at osmosys dot tv
2008-03-17 16:41 ` [Bug middle-end/35616] " pinskia at gcc dot gnu dot org
2008-03-17 17:13 ` J dot Gorka at osmosys dot tv
2008-03-18 7:58 ` J dot Gorka at osmosys dot tv
2008-03-18 8:02 ` pinskia at gcc dot gnu dot org
2008-03-18 8:18 ` J dot Gorka at osmosys dot tv
2008-03-18 10:52 ` [Bug target/35616] [4.1/4.2/4.3/4.4 Regression] " rguenth at gcc dot gnu dot org
2008-03-18 14:34 ` ubizjak at gmail dot com
2008-03-18 14:45 ` ubizjak at gmail dot com
2008-03-18 14:54 ` rguenth at gcc dot gnu dot org
2008-03-18 14:56 ` matz at gcc dot gnu dot org
2008-03-18 15:02 ` ubizjak at gmail dot com
2008-03-18 15:04 ` matz at gcc dot gnu dot org
2008-03-18 15:26 ` rguenth at gcc dot gnu dot org
2008-03-18 15:30 ` ubizjak at gmail dot com
2008-03-18 15:38 ` matz at gcc dot gnu dot org
2008-03-18 16:01 ` [Bug middle-end/35616] " matz at gcc dot gnu dot org
2008-03-18 17:27 ` rguenth at gcc dot gnu dot org
2008-03-19 19:16 ` matz at gcc dot gnu dot org
2008-03-19 19:39 ` matz at gcc dot gnu dot org
2008-03-19 19:41 ` [Bug middle-end/35616] [4.1/4.2 " matz at gcc dot gnu dot org
2008-07-04 22:40 ` [Bug middle-end/35616] [4.2 " jsm28 at gcc dot gnu dot org
2009-03-31 15:26 ` jsm28 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).