On 3/29/18 9:35 AM, Alan Modra wrote: > On Thu, Nov 16, 2017 at 03:27:01PM +0000, Tamar Christina wrote: >> --- a/gcc/expr.c >> +++ b/gcc/expr.c >> @@ -2769,7 +2769,9 @@ copy_blkmode_to_reg (machine_mode mode, tree src) >> >> n_regs = (bytes + UNITS_PER_WORD - 1) / UNITS_PER_WORD; >> dst_words = XALLOCAVEC (rtx, n_regs); >> - bitsize = MIN (TYPE_ALIGN (TREE_TYPE (src)), BITS_PER_WORD); >> + bitsize = BITS_PER_WORD; >> + if (targetm.slow_unaligned_access (word_mode, TYPE_ALIGN (TREE_TYPE >> (src)))) >> + bitsize = MIN (TYPE_ALIGN (TREE_TYPE (src)), BITS_PER_WORD); >> >> /* Copy the structure BITSIZE bits at a time. */ >> for (bitpos = 0, xbitpos = padding_correction; > > I believe this patch is wrong. Please revert. See the PR84762 testcase.
I'm seeing this patch cause an error too on different test case: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85123#c2 I've closed PR85123 as a dup of PR84762, even though the test case in PR84762 is failing for -m32 while the test case in PR85123 is failing for -m64, since they're both caused by the same bug. Peter