https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105591
--- Comment #4 from Zdenek Sojka <zsojka at seznam dot cz> --- (In reply to Richard Biener from comment #1) > Confirmed. The offset is very large negative, built by simplify_bitfield_ref > here: > > 2416 tem = build3 (BIT_FIELD_REF, TREE_TYPE (op), > 2417 p, op1, bitsize_int (idx * elem_size)); > (gdb) p idx > $11 = 13704120150654661628 > > because we have a non-sensical permute: > > x_4 = VEC_PERM_EXPR <u_3(D), u_3(D), { 13704120150654661630, 0 }>; > > some sanity checking in simplify_bitfield_ref might be in order. Rejecting > the __builtin_shuffle might be another option, it's surely going to cause > issues elsewhere. Indeed I am triggering probably related failures elsewhere: testcase-min0.i:54:5: error: invalid position or size operand to 'bit_field_ref' 54 | int main(void) | ^~~~ _66 = BIT_FIELD_REF <{ 2305807824841605120, 18446462598732840960, 65535, 268431360, 65535, 68718428160, 18446181123756130304, 72056494526300160 }, 64, 0xfffffffffffffffff0a1a0c0f3732940>; testcase-min0.i:54:5: error: position plus size exceeds size of referenced object in 'bit_field_ref' _89 = BIT_FIELD_REF <{ 2305807824841605120, 18446462598732840960, 65535, 268431360, 65535, 68718428160, 18446181123756130304, 72056494526300160 }, 64, 5392423424>; ...