diff --git a/instrs.txt b/instrs.txt index 45a3512..a141f2f 100644 --- a/instrs.txt +++ b/instrs.txt @@ -464,7 +464,7 @@ F3.0fbd RM GP GP - - LZCNT USE66 0fc0 MR GP GP - - XADD SIZE_8 LOCK 0fc1 MR GP GP - - XADD LOCK NP.0fc3/m MR MEM GP - - MOVNTI -NP.0fc7/1m M MEMZ - - - CMPXCHGD LOCK INSTR_WIDTH +0fc7/1m M MEMZ - - - CMPXCHGD LOCK IGN66 INSTR_WIDTH 0fc8+ O GP - - - BSWAP 0fff RM GP GP - - UD0 # diff --git a/tests/test_decode.c b/tests/test_decode.c index b0a4181..0c574b4 100644 --- a/tests/test_decode.c +++ b/tests/test_decode.c @@ -83,7 +83,13 @@ main(int argc, char** argv) TEST64("\x66\x90", "nop"); TEST32("\x0f\xc7\x0f", "cmpxchg8b qword ptr [edi]"); TEST64("\x0f\xc7\x0f", "cmpxchg8b qword ptr [rdi]"); + TEST32("\x66\x0f\xc7\x0f", "cmpxchg8b qword ptr [edi]"); // 66h is ignored + TEST64("\x66\x0f\xc7\x0f", "cmpxchg8b qword ptr [rdi]"); // 66h is ignored TEST64("\x48\x0f\xc7\x0f", "cmpxchg16b xmmword ptr [rdi]"); + TEST32("\xf2\x0f\xc7\x0f", "cmpxchg8b qword ptr [edi]"); + TEST64("\xf2\x0f\xc7\x0f", "cmpxchg8b qword ptr [rdi]"); + TEST32("\xf3\x0f\xc7\x0f", "cmpxchg8b qword ptr [edi]"); + TEST64("\xf3\x0f\xc7\x0f", "cmpxchg8b qword ptr [rdi]"); TEST("\x66", "PARTIAL"); TEST("\xf0", "PARTIAL"); TEST("\x0f", "PARTIAL");