Add _mm512_set1_epi64.

This commit is contained in:
Henry de Valence 2019-02-04 18:08:13 -08:00 committed by gnzlbg
parent 386420307a
commit 012db4342b
2 changed files with 11 additions and 0 deletions

View file

@ -191,3 +191,7 @@ simd_ty!(i32x16[i32]:
i32, i32, i32, i32, i32, i32, i32, i32
| x0, x1, x2, x3, x4, x5, x6, x7,
x8, x9, x10, x11, x12, x13, x14, x15);
simd_ty!(i64x8[i64]:
i64, i64, i64, i64, i64, i64, i64, i64
| x0, x1, x2, x3, x4, x5, x6, x7);

View file

@ -87,6 +87,13 @@ pub unsafe fn _mm512_setr_epi32(
mem::transmute(r)
}
/// Broadcast 64-bit integer `a` to all elements of `dst`.
#[inline]
#[target_feature(enable = "avx512f")]
pub unsafe fn _mm512_set1_epi64(a: i64) -> __m512i {
mem::transmute(i64x8::splat(a))
}
#[cfg(test)]
mod tests {
use std;