2012-10-16 Tom de Vries <tom@codesourcery.com>
* expr.c (move_by_pieces, move_by_pieces_ninsns, can_store_by_pieces) (store_by_pieces_1): Don't enter loop when no more data is left. From-SVN: r192514
This commit is contained in:
parent
7181e991b5
commit
f841b68397
2 changed files with 9 additions and 4 deletions
|
@ -1,3 +1,8 @@
|
|||
2012-10-16 Tom de Vries <tom@codesourcery.com>
|
||||
|
||||
* expr.c (move_by_pieces, move_by_pieces_ninsns, can_store_by_pieces)
|
||||
(store_by_pieces_1): Don't enter loop when no more data is left.
|
||||
|
||||
2012-10-16 Joern Rennecke <joern.rennecke@embecosm.com>
|
||||
|
||||
* loop-doloop.c (doloop_modify): Pass doloop_end pattern to
|
||||
|
|
|
@ -966,7 +966,7 @@ move_by_pieces (rtx to, rtx from, unsigned HOST_WIDE_INT len,
|
|||
/* First move what we can in the largest integer mode, then go to
|
||||
successively smaller modes. */
|
||||
|
||||
while (max_size > 1)
|
||||
while (max_size > 1 && data.len > 0)
|
||||
{
|
||||
enum machine_mode mode = widest_int_mode_for_size (max_size);
|
||||
|
||||
|
@ -1026,7 +1026,7 @@ move_by_pieces_ninsns (unsigned HOST_WIDE_INT l, unsigned int align,
|
|||
|
||||
align = alignment_for_piecewise_move (MOVE_MAX_PIECES, align);
|
||||
|
||||
while (max_size > 1)
|
||||
while (max_size > 1 && l > 0)
|
||||
{
|
||||
enum machine_mode mode;
|
||||
enum insn_code icode;
|
||||
|
@ -2417,7 +2417,7 @@ can_store_by_pieces (unsigned HOST_WIDE_INT len,
|
|||
{
|
||||
l = len;
|
||||
max_size = STORE_MAX_PIECES + 1;
|
||||
while (max_size > 1)
|
||||
while (max_size > 1 && l > 0)
|
||||
{
|
||||
mode = widest_int_mode_for_size (max_size);
|
||||
|
||||
|
@ -2612,7 +2612,7 @@ store_by_pieces_1 (struct store_by_pieces_d *data ATTRIBUTE_UNUSED,
|
|||
/* First store what we can in the largest integer mode, then go to
|
||||
successively smaller modes. */
|
||||
|
||||
while (max_size > 1)
|
||||
while (max_size > 1 && data->len > 0)
|
||||
{
|
||||
enum machine_mode mode = widest_int_mode_for_size (max_size);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue