vpcomb
Vector Packed Compare Byte
Compares bytes using immediate condition.
Pseudocode Operation
for i in 0 to 15:
byte_a ← xmm2[i*8 : i*8+7]
byte_b ← xmm3[i*8 : i*8+7]
result ← evaluate_condition(byte_a, byte_b, imm8)
xmm1[i*8 : i*8+7] ← result ? 0xFF : 0x00
Example
Encoding
Operands
-
dest
128-bit XMM SIMD register -
src1
128-bit XMM SIMD register -
src2
128-bit XMM SIMD register or Memory operand -
src3
8-bit signed immediate
Related
More in XOP
Reference
Instruction Forms
| Opcode | Instruction | Op/En | 64/32-bit Mode | CPUID | Description |
|---|---|---|---|---|---|
| 8F RXB.08 0.src1.0.00 CC /r ib | VPCOMB xmm1, xmm2, xmm3/mem128, imm8 |
Description
Signed Bytes Compares corresponding packed signed bytes in the first and second sources and writes the result of each comparison in the corresponding byte of the destination. The result of each comparison is an 8bit value of all 1s (TRUE) or all 0s (FALSE). There are four operands: VPCOMB dest, src1, src2, imm8 The destination (dest) is an XMM registers specified by ModRM.reg. When the comparison results are written to the destination XMM register, bits [255:128] of the corresponding YMM register are cleared. The first source (src1) is an XMM register specified by the XOP.vvvv field and the second source (src2) is either an XMM register or a 128-bit memory location specified by the ModRM.r/m field. The comparison type is specified by bits [2:0] of the immediate-byte operand (imm8). Each type has an alias mnemonic to facilitate coding.
imm8[2:0] Comparison Mnemonic 000 Less Than VPCOMLTB 001 Less Than or Equal VPCOMLEB 010 Greater Than VPCOMGTB 011 Greater Than or Equal VPCOMGEB 100 Equal VPCOMEQB 101 Not Equal VPCOMNEQB 110 False VPCOMFALSEB 111 True VPCOMTRUEB