aboutsummaryrefslogtreecommitdiff
path: root/sim
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2011-03-15 20:04:04 +0000
committerMike Frysinger <vapier@gentoo.org>2011-03-15 20:04:04 +0000
commitc9329594d491d5e2c3c2f59bb8c6e833910022b4 (patch)
treece2265ac90d908a459cc099079d4941d051f6b23 /sim
parentf3df5b084eb26745b433ab9ea47e6ecff3b864ba (diff)
downloadgdb-c9329594d491d5e2c3c2f59bb8c6e833910022b4.zip
gdb-c9329594d491d5e2c3c2f59bb8c6e833910022b4.tar.gz
gdb-c9329594d491d5e2c3c2f59bb8c6e833910022b4.tar.bz2
sim: bfin: handle saturation with fract multiplications
The saturation behavior with fract modes differs from non-fract modes. Signed-off-by: Robin Getz <robin.getz@analog.com> Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'sim')
-rw-r--r--sim/bfin/ChangeLog4
-rw-r--r--sim/bfin/bfin-sim.c2
2 files changed, 6 insertions, 0 deletions
diff --git a/sim/bfin/ChangeLog b/sim/bfin/ChangeLog
index 8065fad..bdc7690 100644
--- a/sim/bfin/ChangeLog
+++ b/sim/bfin/ChangeLog
@@ -1,3 +1,7 @@
+2010-03-15 Robin Getz <robin.getz@analog.com>
+
+ * bfin-sim.c (extract_mult): Handle M_IU.
+
2011-03-05 Mike Frysinger <vapier@gentoo.org>
* Makefile.in, TODO, aclocal.m4, bfin-sim.c, bfin-sim.h,
diff --git a/sim/bfin/bfin-sim.c b/sim/bfin/bfin-sim.c
index 6d9361e..f70526b 100644
--- a/sim/bfin/bfin-sim.c
+++ b/sim/bfin/bfin-sim.c
@@ -1479,6 +1479,8 @@ extract_mult (SIM_CPU *cpu, bu64 res, int mmod, int MM,
case 0:
case M_IS:
return saturate_s32 (res, overflow);
+ case M_IU:
+ return saturate_u32 (res, overflow);
case M_FU:
if (MM)
return saturate_s32 (res, overflow);