aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorDavid Edelsohn <edelsohn@gnu.org>1999-06-28 03:09:43 +0000
committerJeff Law <law@gcc.gnu.org>1999-06-27 21:09:43 -0600
commitc8e7fe5816daf76be09c8d969b3235d7e4400ad4 (patch)
tree3615061d92b2f48261f61ecaf23eb95316cc7279 /gcc
parent8119eca6ff984a7cd8c2b0887d8a529a3c69a2fb (diff)
downloadgcc-c8e7fe5816daf76be09c8d969b3235d7e4400ad4.zip
gcc-c8e7fe5816daf76be09c8d969b3235d7e4400ad4.tar.gz
gcc-c8e7fe5816daf76be09c8d969b3235d7e4400ad4.tar.bz2
* expmed.c (expand_divmod): Ensure unsigned value fits in reg_note.
From-SVN: r27796
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog4
-rw-r--r--gcc/expmed.c4
2 files changed, 7 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 0426f63..9683347 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,7 @@
+Mon Jun 28 04:07:27 1999 David Edelsohn <edelsohn@gnu.org>
+
+ * expmed.c (expand_divmod): Ensure unsigned value fits in reg_note.
+
Sun Jun 27 02:39:08 1999 Richard Henderson <rth@cygnus.com>
* jump.c (jump_optimize_1): Validate the cmov copy to a temporary.
diff --git a/gcc/expmed.c b/gcc/expmed.c
index dc6382c..ffe16fe 100644
--- a/gcc/expmed.c
+++ b/gcc/expmed.c
@@ -3246,7 +3246,9 @@ expand_divmod (rem_flag, code, mode, op0, op1, target, unsignedp)
insn = get_last_insn ();
if (insn != last
&& (set = single_set (insn)) != 0
- && SET_DEST (set) == quotient)
+ && SET_DEST (set) == quotient
+ && abs_d < ((unsigned HOST_WIDE_INT) 1
+ << (HOST_BITS_PER_WIDE_INT - 1)))
set_unique_reg_note (insn,
REG_EQUAL,
gen_rtx_DIV (compute_mode,