FEX/unittests/ASM/VEX/pext.asm
Ryan Houdek edad24479b unittests: Support skipping unit tests based on host feature support
For these unit tests we no longer need to put them in the disabled tests
file. Instead it will be skipped if the host doesn't support the feature
required.
2022-08-14 20:04:26 -07:00

26 lines
408 B
NASM

%ifdef CONFIG
{
"RegData": {
"RAX": "0x12345678",
"RBX": "0xFF00FFF0",
"RCX": "0x00012567",
"RDX": "0x1234567812345678",
"RSI": "0xFF00FF00FF00FF00",
"RDI": "0x12561256"
},
"HostFeatures": ["BMI2"]
}
%endif
; 32-bit
mov eax, 0x12345678
mov ebx, 0xFF00FFF0
pext ecx, eax, ebx
; 64-bit
mov rdx, 0x1234567812345678
mov rsi, 0xFF00FF00FF00FF00
pext rdi, rdx, rsi
hlt