https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70509
--- Comment #4 from Zdenek Sojka <zsojka at seznam dot cz> --- (In reply to Marc Glisse from comment #3) > Rereading this a few years later, I have no idea why I used that type. > bitsize_int would make more sense... I've already tried this: --- gcc/tree-ssa-forwprop.c (revision 234698) +++ gcc/tree-ssa-forwprop.c (working copy) @@ -1773,7 +1773,7 @@ if (code == VEC_PERM_EXPR) { - tree p, m, index, tem; + tree p, m, tem; unsigned nelts; m = gimple_assign_rhs3 (def_stmt); if (TREE_CODE (m) != VECTOR_CST) @@ -1790,9 +1790,8 @@ p = gimple_assign_rhs2 (def_stmt); idx -= nelts; } - index = build_int_cst (TREE_TYPE (TREE_TYPE (m)), idx * size); tem = build3 (BIT_FIELD_REF, TREE_TYPE (op), - unshare_expr (p), op1, index); + unshare_expr (p), op1, bitsize_int(idx * size)); gimple_assign_set_rhs1 (stmt, tem); fold_stmt (gsi); update_stmt (gsi_stmt (*gsi)); x86_64 bootstrap finished (the code is likely not triggered), regtest running.