https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115538
Bug ID: 115538 Summary: wrong-code with SLP vectorization of conversions Product: gcc Version: 15.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: rguenth at gcc dot gnu.org Target Milestone: --- When using SLP vectorizable_conversion does /* Supportable by target? */ switch (modifier) { case NONE: ... /* Check if the intermediate type can hold OP0's range. When converting from float to integer this is not necessary because values that do not fit the (smaller) target type are unspecified anyway. */ if (demotion && float_expr_p) { wide_int op_min_value, op_max_value; if (!vect_get_range_info (op0, &op_min_value, &op_max_value)) break; if (cvt_type == NULL_TREE || (wi::min_precision (op_max_value, SIGNED) > TYPE_PRECISION (cvt_type)) || (wi::min_precision (op_min_value, SIGNED) > TYPE_PRECISION (cvt_type))) continue; but that uses op0 from the representative (or error_mark_node in case of a VEC_PERM_EXPR SLP operand). No testcase yet.