public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug optimization/12039] New: [tree-ssa] [unit-at-a-time] does not mark static variable as used.
@ 2003-08-23 3:25 pinskia at gcc dot gnu dot org
2003-08-23 3:26 ` [Bug optimization/12039] " pinskia at gcc dot gnu dot org
` (5 more replies)
0 siblings, 6 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-08-23 3:25 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12039
Summary: [tree-ssa] [unit-at-a-time] does not mark static
variable as used.
Product: gcc
Version: tree-ssa
Status: UNCONFIRMED
Keywords: wrong-code
Severity: critical
Priority: P2
Component: optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pinskia at gcc dot gnu dot org
CC: gcc-bugs at gcc dot gnu dot org
Compile the following code (derived from GCC) with -O2 -funit-at-a-time:
static void record_insn_name(int code)
{
static int last_real_code = 0;
last_real_code = code;
}
int main(void)
{
record_insn_name(4);
return 0;
}
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug optimization/12039] [tree-ssa] [unit-at-a-time] does not mark static variable as used.
2003-08-23 3:25 [Bug optimization/12039] New: [tree-ssa] [unit-at-a-time] does not mark static variable as used pinskia at gcc dot gnu dot org
@ 2003-08-23 3:26 ` pinskia at gcc dot gnu dot org
2003-08-30 0:51 ` pinskia at gcc dot gnu dot org
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-08-23 3:26 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12039
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2003-08-23 03:26:39
date| |
Target Milestone|--- |tree-ssa
------- Additional Comments From pinskia at gcc dot gnu dot org 2003-08-23 03:26 -------
Forwarded from <http://gcc.gnu.org/ml/gcc/2003-08/msg01215.html> so confirming as I
could confirm this on the tree-ssa (20030822).
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug optimization/12039] [tree-ssa] [unit-at-a-time] does not mark static variable as used.
2003-08-23 3:25 [Bug optimization/12039] New: [tree-ssa] [unit-at-a-time] does not mark static variable as used pinskia at gcc dot gnu dot org
2003-08-23 3:26 ` [Bug optimization/12039] " pinskia at gcc dot gnu dot org
@ 2003-08-30 0:51 ` pinskia at gcc dot gnu dot org
2003-08-31 3:33 ` judd dot jenne at charter dot net
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-08-30 0:51 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12039
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P2 |P1
------- Additional Comments From pinskia at gcc dot gnu dot org 2003-08-30 00:51 -------
There has been two other reports of this one already, one for c++ and another one for c, if I had
time I would look at it but I having bootstrap problems again and I am working on a paper now
that has to be done by Saturday night.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug optimization/12039] [tree-ssa] [unit-at-a-time] does not mark static variable as used.
2003-08-23 3:25 [Bug optimization/12039] New: [tree-ssa] [unit-at-a-time] does not mark static variable as used pinskia at gcc dot gnu dot org
2003-08-23 3:26 ` [Bug optimization/12039] " pinskia at gcc dot gnu dot org
2003-08-30 0:51 ` pinskia at gcc dot gnu dot org
@ 2003-08-31 3:33 ` judd dot jenne at charter dot net
2003-09-19 19:54 ` pinskia at gcc dot gnu dot org
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: judd dot jenne at charter dot net @ 2003-08-31 3:33 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12039
------- Additional Comments From judd dot jenne at charter dot net 2003-08-31 03:33 -------
[Brought in from gcc mailing list.]
Andrew,
First of all, thank you for looking into this.
I produced these using an ssa compiler from the last few hours. I hope this helps.
I used something like -fdump-tree-all. I didn't include dumps that
seemed identical to those prior.
It seems that rewrite_out_of_ssa() seems a likely culprit from examining
dumps .dce and .optimized.
Off Topic:
[snipped]
Various Files:
// tc1.c
static int
foo(int n) {
static int yy = 0;
yy = n;
return yy;
}
int
main(void)
{
int pp;
pp = foo(3);
return pp;
}
// tc1.c.t02.original
;; Function foo (foo)
;; enabled by -tree-original
{
static int yy = 0;
yy = n;
return <return-value> = yy;
}
;; Function main (main)
;; enabled by -tree-original
{
int pp;
pp = foo(3);
return <return-value> = pp;
}
// tc1.c.t03.generic
;; Function foo (foo)
foo (n)
{
static int yy = 0;
yy = n;
return yy;;
}
;; Function main (main)
main ()
{
int T.1;
int pp;
T.1 = foo (3);
pp = T.1;
return pp;;
}
// tc1.c.t05.gimple
;; Function main (main)
main ()
{
int retval.2;
int T.1;
int pp;
{
int n;
int <UVecb0>;
n = 3;
{
static int yy = 0;
yy = n;
{
<UVecb0> = yy;
goto <ULec40>;;
};
};
<ULec40>:;;
retval.2 = <UVecb0>;
};
T.1 = retval.2;
pp = T.1;
return pp;;
}
// tc1.c.t09.ssa
;; Function main (main)
main ()
{
int retval.2;
int T.1;
int pp;
{
int n;
int <UVecb0>;
n_1 = 3;
{
static int yy = 0;
yy = 3;
<UVecb0>_4 = 3;
goto <ULec40>;;
};
<ULec40>:;;
retval.2_5 = 3;
};
T.1_6 = 3;
pp_7 = 3;
return 3;;
}
// tc1.c.t13.pre
;; Function main (main)
main ()
{
int retval.2;
int T.1;
int pp;
{
int n;
int <UVecb0>;
(void)0;
{
static int yy = 0;
yy = 3;
(void)0;
goto <ULec40>;;
};
<ULec40>:;;
(void)0;
};
(void)0;
(void)0;
return 3;;
}
// tc1.c.t17.optimized
;; Function main (main)
main ()
{
{
yy = 3;
<ULec40>:;;
};
return 3;;
}
Judd
[snipped]
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug optimization/12039] [tree-ssa] [unit-at-a-time] does not mark static variable as used.
2003-08-23 3:25 [Bug optimization/12039] New: [tree-ssa] [unit-at-a-time] does not mark static variable as used pinskia at gcc dot gnu dot org
` (2 preceding siblings ...)
2003-08-31 3:33 ` judd dot jenne at charter dot net
@ 2003-09-19 19:54 ` pinskia at gcc dot gnu dot org
2003-10-17 18:49 ` pinskia at gcc dot gnu dot org
2003-10-17 22:43 ` pinskia at gcc dot gnu dot org
5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-09-19 19:54 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12039
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |gerald at pfeifer dot com
------- Additional Comments From pinskia at gcc dot gnu dot org 2003-09-19 19:17 -------
*** Bug 12342 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug optimization/12039] [tree-ssa] [unit-at-a-time] does not mark static variable as used.
2003-08-23 3:25 [Bug optimization/12039] New: [tree-ssa] [unit-at-a-time] does not mark static variable as used pinskia at gcc dot gnu dot org
` (3 preceding siblings ...)
2003-09-19 19:54 ` pinskia at gcc dot gnu dot org
@ 2003-10-17 18:49 ` pinskia at gcc dot gnu dot org
2003-10-17 22:43 ` pinskia at gcc dot gnu dot org
5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-10-17 18:49 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12039
------- Additional Comments From pinskia at gcc dot gnu dot org 2003-10-17 18:48 -------
Most likely fixed by, I will check once I compile the compiler with this patch applied:
Branch: tree-ssa-20020619-branch
Changes by: hubicka@gcc.gnu.org 2003-10-17 18:34:04
Modified files:
gcc : ChangeLog.tree-ssa tree-cfg.c
Log message:
* tree-cfg.c (remove_useless_stmts_and_vars_bind): Fix handling of
static variables.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug optimization/12039] [tree-ssa] [unit-at-a-time] does not mark static variable as used.
2003-08-23 3:25 [Bug optimization/12039] New: [tree-ssa] [unit-at-a-time] does not mark static variable as used pinskia at gcc dot gnu dot org
` (4 preceding siblings ...)
2003-10-17 18:49 ` pinskia at gcc dot gnu dot org
@ 2003-10-17 22:43 ` pinskia at gcc dot gnu dot org
5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-10-17 22:43 UTC (permalink / raw)
To: gcc-bugs
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12039
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
------- Additional Comments From pinskia at gcc dot gnu dot org 2003-10-17 22:42 -------
Was fixed by the patch so closing.
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2003-10-17 22:42 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-23 3:25 [Bug optimization/12039] New: [tree-ssa] [unit-at-a-time] does not mark static variable as used pinskia at gcc dot gnu dot org
2003-08-23 3:26 ` [Bug optimization/12039] " pinskia at gcc dot gnu dot org
2003-08-30 0:51 ` pinskia at gcc dot gnu dot org
2003-08-31 3:33 ` judd dot jenne at charter dot net
2003-09-19 19:54 ` pinskia at gcc dot gnu dot org
2003-10-17 18:49 ` pinskia at gcc dot gnu dot org
2003-10-17 22:43 ` 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).