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

--- Comment #1 from Matthias Kretz (Vir) <mkretz at gcc dot gnu.org> ---
It seems '__is_same' is not the problem here. New test case
(https://compiler-explorer.com/z/fsoc3hzMK):

---------------------------------------------------
template <typename _Tp, typename _Up>
  constexpr bool same_size_v = sizeof(_Tp) == sizeof(_Up);

template <typename _Tp>
  using _Vp [[gnu::vector_size(16)]] = _Tp;

static_assert(sizeof(_Vp<float>) == 16);
static_assert(not same_size_v<float, _Vp<float>>);

template <typename _Tp>
  struct Test
  {
    static_assert(sizeof(_Vp<_Tp>) == 16);
    static_assert(not same_size_v<_Vp<float>, float>);
    static_assert(not same_size_v<_Vp<float>, _Tp>);
    static_assert(not same_size_v<_Vp<_Tp>, _Tp>); // <- this fails
  };

Test<float> x;
---------------------------------------------------

So something strange is happening with _Vp<_Tp> inside Test<float>.

Reply via email to