summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2002-06-17 21:44:06 +0000
committerAndrew Cagney <cagney@redhat.com>2002-06-17 21:44:06 +0000
commit1a158c52aa6cd9b661ce1dd851558a6e529bb045 (patch)
treea5edb3b30d69b78299261ee9198ef66bd79930db
parent0cb5e3bfe2e713c7dabb962a3e5e6c5c6b8f6c01 (diff)
downloadgdb-1a158c52aa6cd9b661ce1dd851558a6e529bb045.tar.gz
* gen.c (gen_entry_expand_opcode): Initialize ``value'' to -1 and
``t'' to NULL. * igen.c (main): Add default case to switch. * gen-icache.c (print_icache_extraction): Ditto.
-rw-r--r--sim/igen/ChangeLog7
-rw-r--r--sim/igen/gen-icache.c2
-rw-r--r--sim/igen/gen.c4
-rw-r--r--sim/igen/igen.c2
4 files changed, 13 insertions, 2 deletions
diff --git a/sim/igen/ChangeLog b/sim/igen/ChangeLog
index b693544775b..8ef6284daa7 100644
--- a/sim/igen/ChangeLog
+++ b/sim/igen/ChangeLog
@@ -1,5 +1,12 @@
2002-06-17 Andrew Cagney <cagney@redhat.com>
+ * gen.c (gen_entry_expand_opcode): Initialize ``value'' to -1 and
+ ``t'' to NULL.
+ * igen.c (main): Add default case to switch.
+ * gen-icache.c (print_icache_extraction): Ditto.
+
+2002-06-17 Andrew Cagney <cagney@redhat.com>
+
* Makefile.in (BUILD_CFLAGS): Remove -O0.
2002-06-16 Andrew Cagney <ac131313@redhat.com>
diff --git a/sim/igen/gen-icache.c b/sim/igen/gen-icache.c
index 88d5d412288..5ec1e73bad7 100644
--- a/sim/igen/gen-icache.c
+++ b/sim/igen/gen-icache.c
@@ -132,6 +132,8 @@ print_icache_extraction (lf *file,
else
return;
break;
+ default:
+ abort (); /* Bad switch. */
}
/* For the type, default to a simple unsigned */
diff --git a/sim/igen/gen.c b/sim/igen/gen.c
index 7c24b46813f..156c929a052 100644
--- a/sim/igen/gen.c
+++ b/sim/igen/gen.c
@@ -1025,9 +1025,9 @@ gen_entry_expand_opcode (gen_entry *table,
}
case insn_field_cond_field:
{
- int value;
+ int value = -1;
opcode_bits *bit;
- gen_entry *t;
+ gen_entry *t = NULL;
/* Try to find a value for the
conditional by looking back through
the previously defined bits for one
diff --git a/sim/igen/igen.c b/sim/igen/igen.c
index 1399d30a306..717c0c6a75e 100644
--- a/sim/igen/igen.c
+++ b/sim/igen/igen.c
@@ -1277,6 +1277,8 @@ main (int argc,
case 'S':
name = &names->suffix;
break;
+ default:
+ abort (); /* Bad switch. */
}
name->u = strdup (chp);
name->l = strdup (chp);