Add x86 SIMD band

This commit is contained in:
Andrew Brown
2019-09-30 11:44:31 -07:00
parent 96d51cb1e8
commit 4cdc1e76a4
3 changed files with 24 additions and 1 deletions

View File

@@ -1973,8 +1973,13 @@ pub(crate) fn define<'defs>(
e.enc_32_64_maybe_isap(imul, rec_fa.opcodes(opcodes), *isap);
}
// SIMD bor
// SIMD logical operations
for ty in ValueType::all_lane_types().filter(allowed_simd_type) {
// band
let band = band.bind(vector(ty, sse_vector_size));
e.enc_32_64(band, rec_fa.opcodes(&PAND));
// bor
let bor = bor.bind(vector(ty, sse_vector_size));
e.enc_32_64(bor, rec_fa.nonrex().opcodes(&POR));
}

View File

@@ -263,6 +263,9 @@ pub static PADDUSB: [u8; 3] = [0x66, 0x0f, 0xdc];
/// Add packed unsigned word integers from xmm2/m128 and xmm1 saturate the results (SSE).
pub static PADDUSW: [u8; 3] = [0x66, 0x0f, 0xdd];
/// Bitwise AND of xmm2/m128 and xmm1 (SSE2).
pub static PAND: [u8; 3] = [0x66, 0x0f, 0xdb];
/// Compare packed data for equal (SSE2).
pub static PCMPEQB: [u8; 3] = [0x66, 0x0f, 0x74];