add gather_base_offsets32_i16
This commit is contained in:
@@ -3140,6 +3140,19 @@ __gather_base_offsets32_i8(uint8_t *base, uint32_t scale, __vec16_i32 offsets,
|
||||
return ret;
|
||||
}
|
||||
|
||||
static FORCEINLINE __vec16_i16
|
||||
__gather_base_offsets32_i16(uint8_t *base, uint32_t scale, __vec16_i32 offsets,
|
||||
__vec16_i1 mask) {
|
||||
// (iw): need to temporarily store as int because gathers can only return ints.
|
||||
__vec16_i32 tmp = _mm512_mask_i32extgather_epi32(_mm512_undefined_epi32(), mask, offsets, base,
|
||||
_MM_UPCONV_EPI32_SINT16, scale,
|
||||
_MM_HINT_NONE);
|
||||
// now, downconverting to chars into temporary char vector
|
||||
__vec16_i16 ret;
|
||||
_mm512_extstore_epi32(ret.v,tmp,_MM_DOWNCONV_EPI32_SINT16,_MM_HINT_NONE);
|
||||
return ret;
|
||||
}
|
||||
|
||||
static FORCEINLINE __vec16_i32
|
||||
__gather_base_offsets32_i32(uint8_t *base, uint32_t scale, __vec16_i32 offsets,
|
||||
__vec16_i1 mask) {
|
||||
|
||||
Reference in New Issue
Block a user