diff options
author | iximeow <me@iximeow.net> | 2021-03-21 01:21:11 -0700 |
---|---|---|
committer | iximeow <me@iximeow.net> | 2021-03-21 01:21:55 -0700 |
commit | 68e719a30e989d6580f8077cb9afa5af3ddffa9a (patch) | |
tree | a80ad3342eb7408138c6632ff918688aa2f4ed08 /test | |
parent | a493b4d267c4fb6a042cf071301c8885196b4a91 (diff) |
add tdx
decoder flag to come
Diffstat (limited to 'test')
-rw-r--r-- | test/long_mode/mod.rs | 24 |
1 files changed, 17 insertions, 7 deletions
diff --git a/test/long_mode/mod.rs b/test/long_mode/mod.rs index b024103..3e8a307 100644 --- a/test/long_mode/mod.rs +++ b/test/long_mode/mod.rs @@ -607,13 +607,15 @@ fn test_sse3() { test_instr(&[0xf2, 0x0f, 0x12, 0xcf], "movddup xmm1, xmm7"); test_instr(&[0xf2, 0x4f, 0x0f, 0x12, 0xcf], "movddup xmm9, xmm15"); - test_instr(&[0x66, 0x0f, 0x01, 0xc8], "monitor"); - test_instr(&[0xf2, 0x0f, 0x01, 0xc8], "monitor"); - test_instr(&[0xf3, 0x0f, 0x01, 0xc8], "monitor"); - - test_instr(&[0x66, 0x0f, 0x01, 0xc9], "mwait"); - test_instr(&[0xf2, 0x0f, 0x01, 0xc9], "mwait"); - test_instr(&[0xf3, 0x0f, 0x01, 0xc9], "mwait"); + test_instr(&[0x0f, 0x01, 0xc8], "monitor"); + test_invalid(&[0x66, 0x0f, 0x01, 0xc8]); + test_invalid(&[0xf3, 0x0f, 0x01, 0xc8]); + test_invalid(&[0xf2, 0x0f, 0x01, 0xc8]); + + test_instr(&[0x0f, 0x01, 0xc9], "mwait"); + test_invalid(&[0x66, 0x0f, 0x01, 0xc9]); + test_invalid(&[0xf2, 0x0f, 0x01, 0xc9]); + test_invalid(&[0xf3, 0x0f, 0x01, 0xc9]); } #[test] @@ -2335,3 +2337,11 @@ fn test_gfni() { test_display(&[0x66, 0x36, 0x0f, 0x3a, 0xce, 0x8c, 0x56, 0x9e, 0x82, 0xd1, 0xbe, 0xad], "gf2p8affineqb xmm1, [rsi + rdx * 2 - 0x412e7d62], 0xad"); test_display(&[0x66, 0x4e, 0x0f, 0x38, 0xcf, 0x1c, 0x54], "gf2p8mulb xmm11, [rsp + r10 * 2]"); } + +#[test] +fn test_tdx() { + test_display(&[0x66, 0x0f, 0x01, 0xcc], "tdcall"); + test_display(&[0x66, 0x0f, 0x01, 0xcd], "seamret"); + test_display(&[0x66, 0x0f, 0x01, 0xce], "seamops"); + test_display(&[0x66, 0x0f, 0x01, 0xcf], "seamcall"); +} |