mirror of
https://github.com/g-truc/glm.git
synced 2025-04-07 22:40:17 +00:00
Specialized SIMD == and != operators
This commit is contained in:
parent
a9fefc7300
commit
9c6de96669
1 changed files with 18 additions and 0 deletions
|
@ -204,6 +204,24 @@ namespace detail
|
|||
}
|
||||
};
|
||||
# endif
|
||||
|
||||
template <precision P>
|
||||
struct compute_vec4_equal<float, P, false, 32>
|
||||
{
|
||||
static bool call(tvec4<float, P> const & v1, tvec4<float, P> const & v2)
|
||||
{
|
||||
return _mm_movemask_ps(_mm_cmpeq_ps(v1.data, v2.data)) != 0;
|
||||
}
|
||||
};
|
||||
|
||||
template <precision P>
|
||||
struct compute_vec4_nequal<float, P, false, 32>
|
||||
{
|
||||
static bool call(tvec4<float, P> const & v1, tvec4<float, P> const & v2)
|
||||
{
|
||||
return _mm_movemask_ps(_mm_cmpneq_ps(v1.data, v2.data)) != 0;
|
||||
}
|
||||
};
|
||||
}//namespace detail
|
||||
|
||||
# if !GLM_HAS_DEFAULTED_FUNCTIONS
|
||||
|
|
Loading…
Add table
Reference in a new issue