summaryrefslogtreecommitdiff
path: root/src/arch/mips
diff options
context:
space:
mode:
authorGabe Black <gblack@eecs.umich.edu>2007-01-25 01:13:56 -0500
committerGabe Black <gblack@eecs.umich.edu>2007-01-25 01:13:56 -0500
commit5407a6bc3223aacbb3f243327b62550e5773c292 (patch)
tree2851592e4f682e25072cd08f7d082bb47e74022c /src/arch/mips
parent5f50dfa5d037e56e73c68f4c087491f57b52f677 (diff)
downloadgem5-5407a6bc3223aacbb3f243327b62550e5773c292.tar.xz
Fixed a warning that was breaking compilation.
--HG-- extra : convert_revision : 007e83ab452849ce527fe252148e7a1dc423c850
Diffstat (limited to 'src/arch/mips')
-rw-r--r--src/arch/mips/isa/decoder.isa6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/arch/mips/isa/decoder.isa b/src/arch/mips/isa/decoder.isa
index 12f36c449..99c9e1604 100644
--- a/src/arch/mips/isa/decoder.isa
+++ b/src/arch/mips/isa/decoder.isa
@@ -156,14 +156,16 @@ decode OPCODE_HI default Unknown::unknown() {
format HiLoOp {
0x0: mult({{ int64_t val = Rs.sd * Rt.sd; }});
0x1: multu({{ uint64_t val = Rs.ud * Rt.ud; }});
- 0x2: div({{ int64_t val;
+ 0x2: div({{ //Initialized to placate g++
+ int64_t val = 0;
if (Rt.sd != 0) {
int64_t hi = Rs.sd % Rt.sd;
int64_t lo = Rs.sd / Rt.sd;
val = (hi << 32) | lo;
}
}});
- 0x3: divu({{ uint64_t val;
+ 0x3: divu({{ //Initialized to placate g++
+ uint64_t val = 0;
if (Rt.ud != 0) {
uint64_t hi = Rs.ud % Rt.ud;
uint64_t lo = Rs.ud / Rt.ud;