Commit 3e626beb by Richard Henderson Committed by Richard Henderson

combine.c (simplify_shift_const): Bound shift count when combining shifts.

        * combine.c (simplify_shift_const): Bound shift count when
        combining shifts.

From-SVN: r35739
parent 8e7c93fe
2000-08-15 Richard Henderson <rth@cygnus.com>
* combine.c (simplify_shift_const): Bound shift count when
combining shifts.
Tue Aug 15 17:33:05 2000 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> Tue Aug 15 17:33:05 2000 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
* calls.c (ECF_SP_DEPRESSED): New macro. * calls.c (ECF_SP_DEPRESSED): New macro.
......
...@@ -9149,6 +9149,8 @@ simplify_shift_const (x, code, result_mode, varop, input_count) ...@@ -9149,6 +9149,8 @@ simplify_shift_const (x, code, result_mode, varop, input_count)
break; break;
count += first_count; count += first_count;
if (count >= GET_MODE_BITSIZE (shift_mode))
count = GET_MODE_BITSIZE (shift_mode) - 1;
varop = XEXP (varop, 0); varop = XEXP (varop, 0);
continue; continue;
} }
...@@ -9202,6 +9204,9 @@ simplify_shift_const (x, code, result_mode, varop, input_count) ...@@ -9202,6 +9204,9 @@ simplify_shift_const (x, code, result_mode, varop, input_count)
else else
count = signed_count; count = signed_count;
if (count >= GET_MODE_BITSIZE (shift_mode))
count = GET_MODE_BITSIZE (shift_mode) - 1;
varop = XEXP (varop, 0); varop = XEXP (varop, 0);
continue; continue;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment