MCPcopy Create free account
hub / github.com/defold/defold / spmd_ternaryi

Function spmd_ternaryi

engine/dlib/src/basis/encoder/cppspmd_sse.h:1432–1432  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1430
1431CPPSPMD_FORCE_INLINE vfloat spmd_ternaryf(const vbool& cond, const vfloat& a, const vfloat& b) { return vfloat{ blendv_mask_ps(b.m_value, a.m_value, _mm_castsi128_ps(cond.m_value)) }; }
1432CPPSPMD_FORCE_INLINE vint spmd_ternaryi(const vbool& cond, const vint& a, const vint& b) { return vint{ blendv_mask_epi32(b.m_value, a.m_value, cond.m_value) }; }
1433
1434CPPSPMD_FORCE_INLINE vfloat sqrt(const vfloat& v) { return vfloat{ _mm_sqrt_ps(v.m_value) }; }
1435CPPSPMD_FORCE_INLINE vfloat abs(const vfloat& v) { return vfloat{ _mm_andnot_ps(_mm_set1_ps(-0.0f), v.m_value) }; }

Callers 6

get_randiMethod · 0.85
CPPSPMD_DECLFunction · 0.85
mod_epi32Function · 0.85
vuint_shift_rightFunction · 0.85

Calls 1

blendv_mask_epi32Function · 0.85

Tested by

no test coverage detected