[Bug testsuite/107338] new test case gcc.dg/vect/vect-bitfield-read-7.c in r13-3413-ge10ca9544632db fails

avieira at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Oct 21 10:59:24 GMT 2022


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107338

--- Comment #3 from avieira at gcc dot gnu.org ---
Hi Kewen,

I believe you are right. I was waiting for a powerpc machine in the board farm,
but I suspect I can reproduce this with an aarch64 BE target and I should be
able to confirm.

But your reasoning seems valid to me. Because of the widening the shift_n
becomes 32-shift_n-mask_width, but the start of the bitfield didn't move by
widening the container, so it is still 16 - shift_n - mask_width bits away from
the start of the container.

Moving the calculation before the widening seems like the neatest solution to
me, there's no point in keeping the old type around I think.

Do you want to produce a patch for this, seeing you solved it?


More information about the Gcc-bugs mailing list