[][src]Macro safe_arch::insert_m128i_to_m256i

macro_rules! insert_m128i_to_m256i {
    ($a:expr, $b:expr, $imm:expr) => { ... };
}
This is supported with target feature avx only.

Inserts an m128i to an m256i at the high or low position.

  • First arg: the m256i register to insert to
  • Second arg: the m128i register to be inserted
  • Third arg: 0 or 1 to target either the low or high half for insertion.
let a = m256i::from([0_i32; 8]);
let b: [i32; 8] =
  insert_m128i_to_m256i!(a, m128i::from([1, 2, 3, 4]), 1).into();
assert_eq!(b, [0, 0, 0, 0, 1, 2, 3, 4]);