aboutsummaryrefslogtreecommitdiff
path: root/sim/v850
diff options
context:
space:
mode:
authorJim Wilson <wilson@tuliptree.org>1997-09-16 01:45:23 +0000
committerJim Wilson <wilson@tuliptree.org>1997-09-16 01:45:23 +0000
commit5262de21672329804caaa818272c4ddbf83a2ad3 (patch)
tree3ded685b85c03f21382b76aa5ffa93c60187a662 /sim/v850
parentd30a2be45d6518c9de3aba98b75b5552880cb524 (diff)
downloadgdb-5262de21672329804caaa818272c4ddbf83a2ad3.zip
gdb-5262de21672329804caaa818272c4ddbf83a2ad3.tar.gz
gdb-5262de21672329804caaa818272c4ddbf83a2ad3.tar.bz2
* simops.c (Multiply64): Don't store into register zero.
Diffstat (limited to 'sim/v850')
-rw-r--r--sim/v850/ChangeLog6
-rw-r--r--sim/v850/simops.c7
2 files changed, 11 insertions, 2 deletions
diff --git a/sim/v850/ChangeLog b/sim/v850/ChangeLog
index 2785dc9..0bb4d55 100644
--- a/sim/v850/ChangeLog
+++ b/sim/v850/ChangeLog
@@ -1,3 +1,9 @@
+start-sanitize-v850e
+Mon Sep 15 18:44:05 1997 Jim Wilson <wilson@cygnus.com>
+
+ * simops.c (Multiply64): Don't store into register zero.
+
+start-sanitize-v850e
Tue Sep 16 09:02:00 1997 Andrew Cagney <cagney@b1.cygnus.com>
* Makefile.in (semantics.o): Add dependency.
diff --git a/sim/v850/simops.c b/sim/v850/simops.c
index c4ecdc4..2cc54e4 100644
--- a/sim/v850/simops.c
+++ b/sim/v850/simops.c
@@ -414,8 +414,11 @@ Multiply64 (boolean sign, unsigned long op0)
RdLo += 1;
}
- State.regs[ OP[1] ] = RdLo;
- State.regs[ OP[2] >> 11 ] = RdHi;
+ /* Don't store into register 0. */
+ if (OP[1])
+ State.regs[ OP[1] ] = RdLo;
+ if (OP[2] >> 11)
+ State.regs[ OP[2] >> 11 ] = RdHi;
return;
}