https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82228
--- Comment #1 from rsandifo at gcc dot gnu.org <rsandifo at gcc dot gnu.org> --- I think the problem is that I put the calculation too early. It should be after the !STMT_VINFO_RELEVANT_P check instead. The loop we're trying to vectorise is: <bb 60> [0.93%] [count: INV]: # ih_720 = PHI <_81(62), 1(59)> _1610 = (integer(kind=8)) ih_720; _1611 = _1610 + -1; pretmp_1612 = IMAGPART_EXPR <*elem1_425(D)[_1611]>; pretmp_1613 = REALPART_EXPR <*elem1_425(D)[_1611]>; sl$real_356 = reciptmp_97 * pretmp_1608; sl$imag_207 = reciptmp_97 * pretmp_1606; _286 = reciptmp_97 * pretmp_1613; _768 = reciptmp_97 * pretmp_1612; REALPART_EXPR <*sl1_426(D)[_1611]> = _286; IMAGPART_EXPR <*sl1_426(D)[_1611]> = _768; _81 = ih_720 + 1; if (_81 > _421) goto <bb 61>; [15.00%] [count: INV] else goto <bb 62>; [85.00%] [count: INV] where sl$real_356 and sl$imag_207 are not relevant (their inputs are defined outside the loop and the only users are outside the loop). I'll commit a patch to do that if it survives testing.