The function move_by_pieces in expr.c enters to endless loop when the backend defines the sizes of all data types to be the same size (aka CHAR_TYPE_SIZE = SHORT_TYPE_SIZE = INT_TYPE_SIZE = anyvalue …).
The loop itself occurs in this code section -
while (max_size > 1)
for (tmode = GET_CLASS_NARROWEST_MODE (MODE_INT);
tmode != VOIDmode; tmode = GET_MODE_WIDER_MODE (tmode))
if (GET_MODE_SIZE (tmode) < max_size)
mode = tmode;
if (mode == VOIDmode)
icode = mov_optab->handlers[(int) mode].insn_code;
if (icode != CODE_FOR_nothing && align >= GET_MODE_ALIGNMENT (mode))
move_by_pieces_1 (GEN_FCN (icode), mode, &data);
max_size = GET_MODE_SIZE (mode);
The idea here is to decrease the sizes of copying insn, or something like that,
But what if it isn’t decreasing?
Created attachment 23422 [details]
Fixes problem (resubmit, lost due to collision)
(In reply to comment #1)
> Created attachment 23422 [details]
> Fixes problem (resubmit, lost due to collision)
Sorry, bugzilla confused me, this attachment was intended for 42722.