summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorghazi <ghazi@138bc75d-0d04-0410-961f-82ee72b054a4>2002-08-10 12:30:34 +0000
committerghazi <ghazi@138bc75d-0d04-0410-961f-82ee72b054a4>2002-08-10 12:30:34 +0000
commitd90b3d04fca5bcaf406e6e3747b11c8a9295c42b (patch)
treee3ee20c06e269902b68b2a5e3e336d2a0081cd5f
parent7fe54e4877c20ac320940f73f98e0d4b69f26b2c (diff)
downloadppe42-gcc-d90b3d04fca5bcaf406e6e3747b11c8a9295c42b.tar.gz
ppe42-gcc-d90b3d04fca5bcaf406e6e3747b11c8a9295c42b.zip
* emit-rtl.c (emit_jump_insn_before, emit_call_insn_before,
emit_jump_insn): Fix uninitialized variable. * gcov.c (init_line_info): Likewise. * genautomata.c (transform_3): Add braces around ambiguous else. * ifcvt.c (cond_exec_process_insns): Mark parameter with ATTRIBUTE_UNUSED. * ra-build.c (parts_to_webs_1): Fix uninitialized variable. * regrename.c (copyprop_hardreg_forward): Fix uninitialized variable. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@56182 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog11
-rw-r--r--gcc/emit-rtl.c6
-rw-r--r--gcc/gcov.c2
-rw-r--r--gcc/genautomata.c24
-rw-r--r--gcc/ifcvt.c2
-rw-r--r--gcc/ra-build.c2
-rw-r--r--gcc/regrename.c2
7 files changed, 31 insertions, 18 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 787ae7a527a..02b40fc4de7 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,16 @@
2002-08-10 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+ * emit-rtl.c (emit_jump_insn_before, emit_call_insn_before,
+ emit_jump_insn): Fix uninitialized variable.
+ * gcov.c (init_line_info): Likewise.
+ * genautomata.c (transform_3): Add braces around ambiguous
+ else.
+ * ifcvt.c (cond_exec_process_insns): Mark parameter with
+ ATTRIBUTE_UNUSED.
+ * ra-build.c (parts_to_webs_1): Fix uninitialized variable.
+ * regrename.c (copyprop_hardreg_forward): Fix uninitialized
+ variable.
+
* gengtype.c (write_gc_structure_fields): Avoid signed/unsigned
warnings in output files.
diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c
index d8689243e98..cf138d37259 100644
--- a/gcc/emit-rtl.c
+++ b/gcc/emit-rtl.c
@@ -3974,7 +3974,7 @@ rtx
emit_jump_insn_before (x, before)
rtx x, before;
{
- rtx insn, last;
+ rtx insn, last = NULL_RTX;
#ifdef ENABLE_RTL_CHECKING
if (before == NULL_RTX)
@@ -4021,7 +4021,7 @@ rtx
emit_call_insn_before (x, before)
rtx x, before;
{
- rtx last, insn;
+ rtx last = NULL_RTX, insn;
#ifdef ENABLE_RTL_CHECKING
if (before == NULL_RTX)
@@ -4506,7 +4506,7 @@ rtx
emit_jump_insn (x)
rtx x;
{
- rtx last, insn;
+ rtx last = NULL_RTX, insn;
switch (GET_CODE (x))
{
diff --git a/gcc/gcov.c b/gcc/gcov.c
index 2c526088635..a9658b26755 100644
--- a/gcc/gcov.c
+++ b/gcc/gcov.c
@@ -1308,7 +1308,7 @@ init_line_info (line_info, total, maxlineno)
char *ptr = bb_data;
long count;
long line_num;
- struct line_info *line_ptr; /* line info ptr. */
+ struct line_info *line_ptr = 0; /* line info ptr. */
memset (&function, 0, sizeof (function));
if (output_function_summary)
diff --git a/gcc/genautomata.c b/gcc/genautomata.c
index 08f81734574..9fd1e836d89 100644
--- a/gcc/genautomata.c
+++ b/gcc/genautomata.c
@@ -4983,17 +4983,19 @@ transform_3 (regexp)
max_seq_length = 0;
if (regexp->mode == rm_allof)
for (i = 0; i < REGEXP_ALLOF (regexp)->regexps_num; i++)
- if (REGEXP_ALLOF (regexp)->regexps [i]->mode == rm_sequence)
- {
- seq = REGEXP_ALLOF (regexp)->regexps [i];
- if (max_seq_length < REGEXP_SEQUENCE (seq)->regexps_num)
- max_seq_length = REGEXP_SEQUENCE (seq)->regexps_num;
- }
- else if (REGEXP_ALLOF (regexp)->regexps [i]->mode != rm_unit)
- {
- max_seq_length = 0;
- break;
- }
+ {
+ if (REGEXP_ALLOF (regexp)->regexps [i]->mode == rm_sequence)
+ {
+ seq = REGEXP_ALLOF (regexp)->regexps [i];
+ if (max_seq_length < REGEXP_SEQUENCE (seq)->regexps_num)
+ max_seq_length = REGEXP_SEQUENCE (seq)->regexps_num;
+ }
+ else if (REGEXP_ALLOF (regexp)->regexps [i]->mode != rm_unit)
+ {
+ max_seq_length = 0;
+ break;
+ }
+ }
if (max_seq_length != 0)
{
if (max_seq_length == 1 || REGEXP_ALLOF (regexp)->regexps_num <= 1)
diff --git a/gcc/ifcvt.c b/gcc/ifcvt.c
index db7140a6998..82660be612d 100644
--- a/gcc/ifcvt.c
+++ b/gcc/ifcvt.c
@@ -224,7 +224,7 @@ block_fallthru (bb)
static int
cond_exec_process_insns (ce_info, start, end, test, prob_val, mod_ok)
- ce_if_block_t *ce_info; /* if block information */
+ ce_if_block_t *ce_info ATTRIBUTE_UNUSED; /* if block information */
rtx start; /* first insn to look at */
rtx end; /* last insn to look at */
rtx test; /* conditional execution test */
diff --git a/gcc/ra-build.c b/gcc/ra-build.c
index a7351f20037..87683cb9c02 100644
--- a/gcc/ra-build.c
+++ b/gcc/ra-build.c
@@ -1815,7 +1815,7 @@ parts_to_webs_1 (df, copy_webs, all_refs)
webnum = 0;
for (i = 0; i < def_id + use_id; i++)
{
- struct web *web, *subweb;
+ struct web *subweb, *web = 0; /* Initialize web to silence warnings. */
struct web_part *wp = &web_parts[i];
struct ref *ref = wp->ref;
unsigned int ref_id;
diff --git a/gcc/regrename.c b/gcc/regrename.c
index 62629f0a4cb..5a80a90eb83 100644
--- a/gcc/regrename.c
+++ b/gcc/regrename.c
@@ -1780,7 +1780,7 @@ copyprop_hardreg_forward ()
{
struct value_data *all_vd;
bool need_refresh;
- basic_block bb, bbp;
+ basic_block bb, bbp = 0;
need_refresh = false;
OpenPOWER on IntegriCloud