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

--- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> ---
So vectorizable_operation correctly says target_support_p == false and then
goes
on with

      target_support_p = (optab_handler (optab, vec_mode)
                          != CODE_FOR_nothing);
    }

  bool using_emulated_vectors_p = vect_emulated_vector_p (vectype);
  if (!target_support_p)
    {
      if (dump_enabled_p ())
        dump_printf_loc (MSG_MISSED_OPTIMIZATION, vect_location,
                         "op not supported by target.\n");
      /* Check only during analysis.  */
      if (maybe_ne (GET_MODE_SIZE (vec_mode), UNITS_PER_WORD)
          || (!vec_stmt && !vect_can_vectorize_without_simd_p (code)))
        return false;
      if (dump_enabled_p ())
        dump_printf_loc (MSG_NOTE, vect_location,
                         "proceeding using word mode.\n");
      using_emulated_vectors_p = true;

using emulated (word-mode) vectors.  In the end it will still emit code
using v2si types which will have V2SImode.  For those it will rely on
vector lowering to perform this very lowering.

So the vectorization works as desired and the lowering as well.  But I agree
the diagnostic in this case is questionable.

Reply via email to