[][src]Macro safe_arch::blend_i32_m128i

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

Blends the i32 lanes in $a and $b into a single value.

  • The blend is controlled by an immediate mask value (an i32).
  • For each lane 0..=3, use 0 if you want that lane of the output to be from $a and use 1 if you want that lane of the output to be from $b.
let a = m128i::from([10, 20, 30, 40]);
let b = m128i::from([100, 200, 300, 400]);
//
let c: [i32; 4] = blend_i32_m128i!(a, b, 0b0110).into();
assert_eq!(c, [10, 200, 300, 40]);