mirror of
https://github.com/bitdefender/bddisasm.git
synced 2024-12-22 05:58:07 +00:00
rsbddisasm: Update bindings
This commit is contained in:
parent
f53cbc51e2
commit
727c87ecc4
@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "bddisasm-sys"
|
name = "bddisasm-sys"
|
||||||
version = "0.3.0"
|
version = "0.4.0"
|
||||||
authors = ["Cristi Anichitei <ianichitei@bitdefender.com>"]
|
authors = ["Cristi Anichitei <ianichitei@bitdefender.com>"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
links = "bddisasm"
|
links = "bddisasm"
|
||||||
|
@ -1,5 +1,15 @@
|
|||||||
# bddisasm changelog
|
# bddisasm changelog
|
||||||
|
|
||||||
|
## 0.3.1
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
- support for new Intel ISA, per Intel Architecture Instruction Set Extensions and Future Features document #319433-049 (June 2023): AVX-NNI-INT16, SHA512, SM3, SM4, TSE.
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- `Mnemonic`, `IsaSet`, and `Category` use all caps for the enum variants
|
||||||
|
|
||||||
## 0.3.0
|
## 0.3.0
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
@ -14,7 +14,7 @@ categories = ["api-bindings", "hardware-support"]
|
|||||||
keywords = ["disassembler", "decoder", "x86", "amd64", "x86_64"]
|
keywords = ["disassembler", "decoder", "x86", "amd64", "x86_64"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
bddisasm-sys = { version = "0.3.0", path = "../bddisasm-sys" }
|
bddisasm-sys = { version = "0.4.0", path = "../bddisasm-sys" }
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
std = []
|
std = []
|
||||||
|
@ -34,7 +34,7 @@ use bddisasm::{DecodedInstruction, DecodeMode, Mnemonic};
|
|||||||
let code = vec![0x31, 0xc0];
|
let code = vec![0x31, 0xc0];
|
||||||
match DecodedInstruction::decode(&code, DecodeMode::Bits32) {
|
match DecodedInstruction::decode(&code, DecodeMode::Bits32) {
|
||||||
Ok(ins) => {
|
Ok(ins) => {
|
||||||
assert_eq!(ins.mnemonic(), Mnemonic::Xor);
|
assert_eq!(ins.mnemonic(), Mnemonic::XOR);
|
||||||
println!("{}", ins);
|
println!("{}", ins);
|
||||||
},
|
},
|
||||||
Err(err) => println!("Unable to decode: {}", err),
|
Err(err) => println!("Unable to decode: {}", err),
|
||||||
|
@ -26,14 +26,14 @@ impl Context {
|
|||||||
let operands = ins.operands();
|
let operands = ins.operands();
|
||||||
|
|
||||||
match ins.mnemonic() {
|
match ins.mnemonic() {
|
||||||
Mnemonic::Mov => {
|
Mnemonic::MOV => {
|
||||||
self.set_operand_value(&operands[0], self.get_operand_value(&operands[1])?)?
|
self.set_operand_value(&operands[0], self.get_operand_value(&operands[1])?)?
|
||||||
}
|
}
|
||||||
Mnemonic::Inc => self.set_operand_value(
|
Mnemonic::INC => self.set_operand_value(
|
||||||
&operands[0],
|
&operands[0],
|
||||||
self.get_operand_value(&operands[0])?.wrapping_add(1),
|
self.get_operand_value(&operands[0])?.wrapping_add(1),
|
||||||
)?,
|
)?,
|
||||||
Mnemonic::Dec => self.set_operand_value(
|
Mnemonic::DEC => self.set_operand_value(
|
||||||
&operands[0],
|
&operands[0],
|
||||||
self.get_operand_value(&operands[0])?.wrapping_sub(1),
|
self.get_operand_value(&operands[0])?.wrapping_sub(1),
|
||||||
)?,
|
)?,
|
||||||
|
@ -598,13 +598,13 @@ impl DecodedInstruction {
|
|||||||
///
|
///
|
||||||
/// let ins =
|
/// let ins =
|
||||||
/// DecodedInstruction::decode(&[0x50], DecodeMode::Bits64)?;
|
/// DecodedInstruction::decode(&[0x50], DecodeMode::Bits64)?;
|
||||||
/// assert_eq!(ins.mnemonic(), Mnemonic::Push);
|
/// assert_eq!(ins.mnemonic(), Mnemonic::PUSH);
|
||||||
/// assert_eq!(ins.op_mode(), OperandSize::OpSize32);
|
/// assert_eq!(ins.op_mode(), OperandSize::OpSize32);
|
||||||
/// assert_eq!(ins.effective_op_mode(), OperandSize::OpSize64);
|
/// assert_eq!(ins.effective_op_mode(), OperandSize::OpSize64);
|
||||||
///
|
///
|
||||||
/// let ins =
|
/// let ins =
|
||||||
/// DecodedInstruction::decode(&[0x48, 0x50], DecodeMode::Bits64)?;
|
/// DecodedInstruction::decode(&[0x48, 0x50], DecodeMode::Bits64)?;
|
||||||
/// assert_eq!(ins.mnemonic(), Mnemonic::Push);
|
/// assert_eq!(ins.mnemonic(), Mnemonic::PUSH);
|
||||||
/// assert_eq!(ins.op_mode(), OperandSize::OpSize64);
|
/// assert_eq!(ins.op_mode(), OperandSize::OpSize64);
|
||||||
/// assert_eq!(ins.effective_op_mode(), OperandSize::OpSize64);
|
/// assert_eq!(ins.effective_op_mode(), OperandSize::OpSize64);
|
||||||
/// # Ok(())
|
/// # Ok(())
|
||||||
@ -1237,7 +1237,7 @@ impl DecodedInstruction {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Get the second immediate. Used mainly for [`Mnemonic::Enter`](Mnemonic::Enter).
|
/// Get the second immediate. Used mainly for [`Mnemonic::ENTER`](Mnemonic::ENTER).
|
||||||
#[inline]
|
#[inline]
|
||||||
pub fn immediate2(&self) -> Option<u8> {
|
pub fn immediate2(&self) -> Option<u8> {
|
||||||
if self.has_imm2() {
|
if self.has_imm2() {
|
||||||
@ -1550,7 +1550,7 @@ mod tests {
|
|||||||
fn decode() {
|
fn decode() {
|
||||||
let code = vec![0xb8, 0x00, 0x00, 0x00, 0x00];
|
let code = vec![0xb8, 0x00, 0x00, 0x00, 0x00];
|
||||||
let ins = DecodedInstruction::decode(&code, DecodeMode::Bits32).expect("Unable to decode");
|
let ins = DecodedInstruction::decode(&code, DecodeMode::Bits32).expect("Unable to decode");
|
||||||
assert_eq!(ins.instruction, Mnemonic::Mov);
|
assert_eq!(ins.instruction, Mnemonic::MOV);
|
||||||
assert_eq!(ins.bytes(), code);
|
assert_eq!(ins.bytes(), code);
|
||||||
assert_eq!(format!("{}", ins), "MOV eax, 0x00000000");
|
assert_eq!(format!("{}", ins), "MOV eax, 0x00000000");
|
||||||
}
|
}
|
||||||
@ -1560,7 +1560,7 @@ mod tests {
|
|||||||
let code = b"\x48\x8b\x05\xf9\xff\xff\xff";
|
let code = b"\x48\x8b\x05\xf9\xff\xff\xff";
|
||||||
let ins = DecodedInstruction::decode_with_ip(code, DecodeMode::Bits64, 0x100)
|
let ins = DecodedInstruction::decode_with_ip(code, DecodeMode::Bits64, 0x100)
|
||||||
.expect("Unable to decode");
|
.expect("Unable to decode");
|
||||||
assert_eq!(ins.instruction, Mnemonic::Mov);
|
assert_eq!(ins.instruction, Mnemonic::MOV);
|
||||||
assert_eq!(ins.bytes(), code);
|
assert_eq!(ins.bytes(), code);
|
||||||
assert_eq!(format!("{}", ins), "MOV rax, qword ptr [rel 0x100]");
|
assert_eq!(format!("{}", ins), "MOV rax, qword ptr [rel 0x100]");
|
||||||
}
|
}
|
||||||
|
@ -223,11 +223,11 @@ mod tests {
|
|||||||
let mut decoder = Decoder::new(&code, DecodeMode::Bits64, 0x1000);
|
let mut decoder = Decoder::new(&code, DecodeMode::Bits64, 0x1000);
|
||||||
let expected: Vec<Result<(Mnemonic, &str, &[u8]), DecodeError>> = vec![
|
let expected: Vec<Result<(Mnemonic, &str, &[u8]), DecodeError>> = vec![
|
||||||
Ok((
|
Ok((
|
||||||
Mnemonic::Mov,
|
Mnemonic::MOV,
|
||||||
"MOV eax, 0x00000000",
|
"MOV eax, 0x00000000",
|
||||||
&[0xb8, 0x00, 0x00, 0x00, 0x00],
|
&[0xb8, 0x00, 0x00, 0x00, 0x00],
|
||||||
)),
|
)),
|
||||||
Ok((Mnemonic::Mov, "MOV rdi, rcx", &[0x48, 0x8b, 0xf9])),
|
Ok((Mnemonic::MOV, "MOV rdi, rcx", &[0x48, 0x8b, 0xf9])),
|
||||||
Err(DecodeError::InvalidEncoding),
|
Err(DecodeError::InvalidEncoding),
|
||||||
Err(DecodeError::BufferTooSmall),
|
Err(DecodeError::BufferTooSmall),
|
||||||
];
|
];
|
||||||
@ -255,11 +255,11 @@ mod tests {
|
|||||||
let decoder = Decoder::new(&code, DecodeMode::Bits64, 0x1000);
|
let decoder = Decoder::new(&code, DecodeMode::Bits64, 0x1000);
|
||||||
let expected: Vec<Result<(Mnemonic, &str, &[u8]), DecodeError>> = vec![
|
let expected: Vec<Result<(Mnemonic, &str, &[u8]), DecodeError>> = vec![
|
||||||
Ok((
|
Ok((
|
||||||
Mnemonic::Mov,
|
Mnemonic::MOV,
|
||||||
"MOV eax, 0x00000000",
|
"MOV eax, 0x00000000",
|
||||||
&[0xb8, 0x00, 0x00, 0x00, 0x00],
|
&[0xb8, 0x00, 0x00, 0x00, 0x00],
|
||||||
)),
|
)),
|
||||||
Ok((Mnemonic::Mov, "MOV rdi, rcx", &[0x48, 0x8b, 0xf9])),
|
Ok((Mnemonic::MOV, "MOV rdi, rcx", &[0x48, 0x8b, 0xf9])),
|
||||||
Err(DecodeError::InvalidEncoding),
|
Err(DecodeError::InvalidEncoding),
|
||||||
Err(DecodeError::BufferTooSmall),
|
Err(DecodeError::BufferTooSmall),
|
||||||
];
|
];
|
||||||
|
@ -9,116 +9,120 @@ use core::convert::TryFrom;
|
|||||||
|
|
||||||
/// Instruction category.
|
/// Instruction category.
|
||||||
#[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)]
|
#[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)]
|
||||||
|
#[allow(non_camel_case_types)]
|
||||||
pub enum Category {
|
pub enum Category {
|
||||||
I3dnow,
|
I3DNOW,
|
||||||
Aes,
|
AES,
|
||||||
Aeskl,
|
AESKL,
|
||||||
Amx,
|
AMX,
|
||||||
Arith,
|
ARITH,
|
||||||
Avx,
|
AVX,
|
||||||
Avx2,
|
AVX2,
|
||||||
Avx2gather,
|
AVX2GATHER,
|
||||||
Avx512,
|
AVX512,
|
||||||
Avx512bf16,
|
AVX512BF16,
|
||||||
Avx512fp16,
|
AVX512FP16,
|
||||||
Avx512vbmi,
|
AVX512VBMI,
|
||||||
Avx512vp2intersect,
|
AVX512VP2INTERSECT,
|
||||||
Avxifma,
|
AVXIFMA,
|
||||||
Avxneconvert,
|
AVXNECONVERT,
|
||||||
Avxvnni,
|
AVXVNNI,
|
||||||
Avxvnniint8,
|
AVXVNNIINT16,
|
||||||
Bitbyte,
|
AVXVNNIINT8,
|
||||||
Blend,
|
BITBYTE,
|
||||||
Bmi1,
|
BLEND,
|
||||||
Bmi2,
|
BMI1,
|
||||||
Broadcast,
|
BMI2,
|
||||||
Call,
|
BROADCAST,
|
||||||
Cet,
|
CALL,
|
||||||
Cldemote,
|
CET,
|
||||||
Cmov,
|
CLDEMOTE,
|
||||||
Cmpccxadd,
|
CMOV,
|
||||||
Compress,
|
CMPCCXADD,
|
||||||
CondBr,
|
COMPRESS,
|
||||||
Conflict,
|
COND_BR,
|
||||||
Convert,
|
CONFLICT,
|
||||||
Dataxfer,
|
CONVERT,
|
||||||
Decimal,
|
DATAXFER,
|
||||||
Enqcmd,
|
DECIMAL,
|
||||||
Expand,
|
ENQCMD,
|
||||||
Flagop,
|
EXPAND,
|
||||||
Fma4,
|
FLAGOP,
|
||||||
Fred,
|
FMA4,
|
||||||
Gather,
|
GATHER,
|
||||||
Gfni,
|
GFNI,
|
||||||
Hreset,
|
HRESET,
|
||||||
I386,
|
I386,
|
||||||
Ifma,
|
IFMA,
|
||||||
Interrupt,
|
INTERRUPT,
|
||||||
Io,
|
IO,
|
||||||
Iostringop,
|
IOSTRINGOP,
|
||||||
Kl,
|
KL,
|
||||||
Kmask,
|
KMASK,
|
||||||
Knl,
|
KNL,
|
||||||
Lkgs,
|
LKGS,
|
||||||
Logic,
|
LOGIC,
|
||||||
Logical,
|
LOGICAL,
|
||||||
LogicalFp,
|
LOGICAL_FP,
|
||||||
Lwp,
|
LWP,
|
||||||
Lzcnt,
|
LZCNT,
|
||||||
Misc,
|
MISC,
|
||||||
Mmx,
|
MMX,
|
||||||
Movdir64b,
|
MOVDIR64B,
|
||||||
Movdiri,
|
MOVDIRI,
|
||||||
Mpx,
|
MPX,
|
||||||
Nop,
|
NOP,
|
||||||
Padlock,
|
PADLOCK,
|
||||||
Pclmulqdq,
|
PCLMULQDQ,
|
||||||
Pconfig,
|
PCONFIG,
|
||||||
Pop,
|
POP,
|
||||||
Prefetch,
|
PREFETCH,
|
||||||
Ptwrite,
|
PTWRITE,
|
||||||
Push,
|
PUSH,
|
||||||
Raoint,
|
RAOINT,
|
||||||
Rdpid,
|
RDPID,
|
||||||
Rdrand,
|
RDRAND,
|
||||||
Rdseed,
|
RDSEED,
|
||||||
Rdwrfsgs,
|
RDWRFSGS,
|
||||||
Ret,
|
RET,
|
||||||
Rotate,
|
ROTATE,
|
||||||
Scatter,
|
SCATTER,
|
||||||
Segop,
|
SEGOP,
|
||||||
Semaphore,
|
SEMAPHORE,
|
||||||
Sgx,
|
SGX,
|
||||||
Sha,
|
SHA,
|
||||||
Shift,
|
SHA512,
|
||||||
Smap,
|
SHIFT,
|
||||||
Sse,
|
SM3,
|
||||||
Sse2,
|
SM4,
|
||||||
Stringop,
|
SMAP,
|
||||||
Sttni,
|
SSE,
|
||||||
Syscall,
|
SSE2,
|
||||||
Sysret,
|
STRINGOP,
|
||||||
System,
|
STTNI,
|
||||||
Tdx,
|
SYSCALL,
|
||||||
Ud,
|
SYSRET,
|
||||||
Uintr,
|
SYSTEM,
|
||||||
UncondBr,
|
TDX,
|
||||||
Unknown,
|
UD,
|
||||||
Vaes,
|
UINTR,
|
||||||
Vfma,
|
UNCOND_BR,
|
||||||
Vfmaps,
|
UNKNOWN,
|
||||||
Vnni,
|
VAES,
|
||||||
Vnniw,
|
VFMA,
|
||||||
Vpclmulqdq,
|
VFMAPS,
|
||||||
Vpopcnt,
|
VNNI,
|
||||||
Vtx,
|
VNNIW,
|
||||||
Waitpkg,
|
VPCLMULQDQ,
|
||||||
Wbnoinvd,
|
VPOPCNT,
|
||||||
Widenop,
|
VTX,
|
||||||
WideKl,
|
WAITPKG,
|
||||||
X87Alu,
|
WBNOINVD,
|
||||||
Xop,
|
WIDENOP,
|
||||||
Xsave,
|
WIDE_KL,
|
||||||
|
X87_ALU,
|
||||||
|
XOP,
|
||||||
|
XSAVE,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[doc(hidden)]
|
#[doc(hidden)]
|
||||||
@ -128,114 +132,118 @@ impl TryFrom<ffi::ND_INS_CATEGORY> for Category {
|
|||||||
fn try_from(value: ffi::ND_INS_CATEGORY) -> Result<Self, Self::Error> {
|
fn try_from(value: ffi::ND_INS_CATEGORY) -> Result<Self, Self::Error> {
|
||||||
match value {
|
match value {
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_INVALID => Err(DecodeError::InternalError(value as u64)),
|
ffi::_ND_INS_TYPE::ND_CAT_INVALID => Err(DecodeError::InternalError(value as u64)),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_3DNOW => Ok(Category::I3dnow),
|
ffi::_ND_INS_TYPE::ND_CAT_3DNOW => Ok(Category::I3DNOW),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AES => Ok(Category::Aes),
|
ffi::_ND_INS_TYPE::ND_CAT_AES => Ok(Category::AES),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AESKL => Ok(Category::Aeskl),
|
ffi::_ND_INS_TYPE::ND_CAT_AESKL => Ok(Category::AESKL),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AMX => Ok(Category::Amx),
|
ffi::_ND_INS_TYPE::ND_CAT_AMX => Ok(Category::AMX),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_ARITH => Ok(Category::Arith),
|
ffi::_ND_INS_TYPE::ND_CAT_ARITH => Ok(Category::ARITH),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVX => Ok(Category::Avx),
|
ffi::_ND_INS_TYPE::ND_CAT_AVX => Ok(Category::AVX),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVX2 => Ok(Category::Avx2),
|
ffi::_ND_INS_TYPE::ND_CAT_AVX2 => Ok(Category::AVX2),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVX2GATHER => Ok(Category::Avx2gather),
|
ffi::_ND_INS_TYPE::ND_CAT_AVX2GATHER => Ok(Category::AVX2GATHER),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVX512 => Ok(Category::Avx512),
|
ffi::_ND_INS_TYPE::ND_CAT_AVX512 => Ok(Category::AVX512),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVX512BF16 => Ok(Category::Avx512bf16),
|
ffi::_ND_INS_TYPE::ND_CAT_AVX512BF16 => Ok(Category::AVX512BF16),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVX512FP16 => Ok(Category::Avx512fp16),
|
ffi::_ND_INS_TYPE::ND_CAT_AVX512FP16 => Ok(Category::AVX512FP16),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVX512VBMI => Ok(Category::Avx512vbmi),
|
ffi::_ND_INS_TYPE::ND_CAT_AVX512VBMI => Ok(Category::AVX512VBMI),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVX512VP2INTERSECT => Ok(Category::Avx512vp2intersect),
|
ffi::_ND_INS_TYPE::ND_CAT_AVX512VP2INTERSECT => Ok(Category::AVX512VP2INTERSECT),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVXIFMA => Ok(Category::Avxifma),
|
ffi::_ND_INS_TYPE::ND_CAT_AVXIFMA => Ok(Category::AVXIFMA),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVXNECONVERT => Ok(Category::Avxneconvert),
|
ffi::_ND_INS_TYPE::ND_CAT_AVXNECONVERT => Ok(Category::AVXNECONVERT),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVXVNNI => Ok(Category::Avxvnni),
|
ffi::_ND_INS_TYPE::ND_CAT_AVXVNNI => Ok(Category::AVXVNNI),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_AVXVNNIINT8 => Ok(Category::Avxvnniint8),
|
ffi::_ND_INS_TYPE::ND_CAT_AVXVNNIINT16 => Ok(Category::AVXVNNIINT16),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_BITBYTE => Ok(Category::Bitbyte),
|
ffi::_ND_INS_TYPE::ND_CAT_AVXVNNIINT8 => Ok(Category::AVXVNNIINT8),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_BLEND => Ok(Category::Blend),
|
ffi::_ND_INS_TYPE::ND_CAT_BITBYTE => Ok(Category::BITBYTE),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_BMI1 => Ok(Category::Bmi1),
|
ffi::_ND_INS_TYPE::ND_CAT_BLEND => Ok(Category::BLEND),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_BMI2 => Ok(Category::Bmi2),
|
ffi::_ND_INS_TYPE::ND_CAT_BMI1 => Ok(Category::BMI1),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_BROADCAST => Ok(Category::Broadcast),
|
ffi::_ND_INS_TYPE::ND_CAT_BMI2 => Ok(Category::BMI2),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_CALL => Ok(Category::Call),
|
ffi::_ND_INS_TYPE::ND_CAT_BROADCAST => Ok(Category::BROADCAST),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_CET => Ok(Category::Cet),
|
ffi::_ND_INS_TYPE::ND_CAT_CALL => Ok(Category::CALL),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_CLDEMOTE => Ok(Category::Cldemote),
|
ffi::_ND_INS_TYPE::ND_CAT_CET => Ok(Category::CET),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_CMOV => Ok(Category::Cmov),
|
ffi::_ND_INS_TYPE::ND_CAT_CLDEMOTE => Ok(Category::CLDEMOTE),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_CMPCCXADD => Ok(Category::Cmpccxadd),
|
ffi::_ND_INS_TYPE::ND_CAT_CMOV => Ok(Category::CMOV),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_COMPRESS => Ok(Category::Compress),
|
ffi::_ND_INS_TYPE::ND_CAT_CMPCCXADD => Ok(Category::CMPCCXADD),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_COND_BR => Ok(Category::CondBr),
|
ffi::_ND_INS_TYPE::ND_CAT_COMPRESS => Ok(Category::COMPRESS),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_CONFLICT => Ok(Category::Conflict),
|
ffi::_ND_INS_TYPE::ND_CAT_COND_BR => Ok(Category::COND_BR),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_CONVERT => Ok(Category::Convert),
|
ffi::_ND_INS_TYPE::ND_CAT_CONFLICT => Ok(Category::CONFLICT),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_DATAXFER => Ok(Category::Dataxfer),
|
ffi::_ND_INS_TYPE::ND_CAT_CONVERT => Ok(Category::CONVERT),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_DECIMAL => Ok(Category::Decimal),
|
ffi::_ND_INS_TYPE::ND_CAT_DATAXFER => Ok(Category::DATAXFER),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_ENQCMD => Ok(Category::Enqcmd),
|
ffi::_ND_INS_TYPE::ND_CAT_DECIMAL => Ok(Category::DECIMAL),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_EXPAND => Ok(Category::Expand),
|
ffi::_ND_INS_TYPE::ND_CAT_ENQCMD => Ok(Category::ENQCMD),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_FLAGOP => Ok(Category::Flagop),
|
ffi::_ND_INS_TYPE::ND_CAT_EXPAND => Ok(Category::EXPAND),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_FMA4 => Ok(Category::Fma4),
|
ffi::_ND_INS_TYPE::ND_CAT_FLAGOP => Ok(Category::FLAGOP),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_GATHER => Ok(Category::Gather),
|
ffi::_ND_INS_TYPE::ND_CAT_FMA4 => Ok(Category::FMA4),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_GFNI => Ok(Category::Gfni),
|
ffi::_ND_INS_TYPE::ND_CAT_GATHER => Ok(Category::GATHER),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_HRESET => Ok(Category::Hreset),
|
ffi::_ND_INS_TYPE::ND_CAT_GFNI => Ok(Category::GFNI),
|
||||||
|
ffi::_ND_INS_TYPE::ND_CAT_HRESET => Ok(Category::HRESET),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_I386 => Ok(Category::I386),
|
ffi::_ND_INS_TYPE::ND_CAT_I386 => Ok(Category::I386),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_IFMA => Ok(Category::Ifma),
|
ffi::_ND_INS_TYPE::ND_CAT_IFMA => Ok(Category::IFMA),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_INTERRUPT => Ok(Category::Interrupt),
|
ffi::_ND_INS_TYPE::ND_CAT_INTERRUPT => Ok(Category::INTERRUPT),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_IO => Ok(Category::Io),
|
ffi::_ND_INS_TYPE::ND_CAT_IO => Ok(Category::IO),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_IOSTRINGOP => Ok(Category::Iostringop),
|
ffi::_ND_INS_TYPE::ND_CAT_IOSTRINGOP => Ok(Category::IOSTRINGOP),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_KL => Ok(Category::Kl),
|
ffi::_ND_INS_TYPE::ND_CAT_KL => Ok(Category::KL),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_KMASK => Ok(Category::Kmask),
|
ffi::_ND_INS_TYPE::ND_CAT_KMASK => Ok(Category::KMASK),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_KNL => Ok(Category::Knl),
|
ffi::_ND_INS_TYPE::ND_CAT_KNL => Ok(Category::KNL),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_LKGS => Ok(Category::Lkgs),
|
ffi::_ND_INS_TYPE::ND_CAT_LKGS => Ok(Category::LKGS),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_LOGIC => Ok(Category::Logic),
|
ffi::_ND_INS_TYPE::ND_CAT_LOGIC => Ok(Category::LOGIC),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_LOGICAL => Ok(Category::Logical),
|
ffi::_ND_INS_TYPE::ND_CAT_LOGICAL => Ok(Category::LOGICAL),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_LOGICAL_FP => Ok(Category::LogicalFp),
|
ffi::_ND_INS_TYPE::ND_CAT_LOGICAL_FP => Ok(Category::LOGICAL_FP),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_LWP => Ok(Category::Lwp),
|
ffi::_ND_INS_TYPE::ND_CAT_LWP => Ok(Category::LWP),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_LZCNT => Ok(Category::Lzcnt),
|
ffi::_ND_INS_TYPE::ND_CAT_LZCNT => Ok(Category::LZCNT),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_MISC => Ok(Category::Misc),
|
ffi::_ND_INS_TYPE::ND_CAT_MISC => Ok(Category::MISC),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_MMX => Ok(Category::Mmx),
|
ffi::_ND_INS_TYPE::ND_CAT_MMX => Ok(Category::MMX),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_MOVDIR64B => Ok(Category::Movdir64b),
|
ffi::_ND_INS_TYPE::ND_CAT_MOVDIR64B => Ok(Category::MOVDIR64B),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_MOVDIRI => Ok(Category::Movdiri),
|
ffi::_ND_INS_TYPE::ND_CAT_MOVDIRI => Ok(Category::MOVDIRI),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_MPX => Ok(Category::Mpx),
|
ffi::_ND_INS_TYPE::ND_CAT_MPX => Ok(Category::MPX),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_NOP => Ok(Category::Nop),
|
ffi::_ND_INS_TYPE::ND_CAT_NOP => Ok(Category::NOP),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_PADLOCK => Ok(Category::Padlock),
|
ffi::_ND_INS_TYPE::ND_CAT_PADLOCK => Ok(Category::PADLOCK),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_PCLMULQDQ => Ok(Category::Pclmulqdq),
|
ffi::_ND_INS_TYPE::ND_CAT_PCLMULQDQ => Ok(Category::PCLMULQDQ),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_PCONFIG => Ok(Category::Pconfig),
|
ffi::_ND_INS_TYPE::ND_CAT_PCONFIG => Ok(Category::PCONFIG),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_POP => Ok(Category::Pop),
|
ffi::_ND_INS_TYPE::ND_CAT_POP => Ok(Category::POP),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_PREFETCH => Ok(Category::Prefetch),
|
ffi::_ND_INS_TYPE::ND_CAT_PREFETCH => Ok(Category::PREFETCH),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_PTWRITE => Ok(Category::Ptwrite),
|
ffi::_ND_INS_TYPE::ND_CAT_PTWRITE => Ok(Category::PTWRITE),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_PUSH => Ok(Category::Push),
|
ffi::_ND_INS_TYPE::ND_CAT_PUSH => Ok(Category::PUSH),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_RAOINT => Ok(Category::Raoint),
|
ffi::_ND_INS_TYPE::ND_CAT_RAOINT => Ok(Category::RAOINT),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_RDPID => Ok(Category::Rdpid),
|
ffi::_ND_INS_TYPE::ND_CAT_RDPID => Ok(Category::RDPID),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_RDRAND => Ok(Category::Rdrand),
|
ffi::_ND_INS_TYPE::ND_CAT_RDRAND => Ok(Category::RDRAND),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_RDSEED => Ok(Category::Rdseed),
|
ffi::_ND_INS_TYPE::ND_CAT_RDSEED => Ok(Category::RDSEED),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_RDWRFSGS => Ok(Category::Rdwrfsgs),
|
ffi::_ND_INS_TYPE::ND_CAT_RDWRFSGS => Ok(Category::RDWRFSGS),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_RET => Ok(Category::Ret),
|
ffi::_ND_INS_TYPE::ND_CAT_RET => Ok(Category::RET),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_ROTATE => Ok(Category::Rotate),
|
ffi::_ND_INS_TYPE::ND_CAT_ROTATE => Ok(Category::ROTATE),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SCATTER => Ok(Category::Scatter),
|
ffi::_ND_INS_TYPE::ND_CAT_SCATTER => Ok(Category::SCATTER),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SEGOP => Ok(Category::Segop),
|
ffi::_ND_INS_TYPE::ND_CAT_SEGOP => Ok(Category::SEGOP),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SEMAPHORE => Ok(Category::Semaphore),
|
ffi::_ND_INS_TYPE::ND_CAT_SEMAPHORE => Ok(Category::SEMAPHORE),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SGX => Ok(Category::Sgx),
|
ffi::_ND_INS_TYPE::ND_CAT_SGX => Ok(Category::SGX),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SHA => Ok(Category::Sha),
|
ffi::_ND_INS_TYPE::ND_CAT_SHA => Ok(Category::SHA),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SHIFT => Ok(Category::Shift),
|
ffi::_ND_INS_TYPE::ND_CAT_SHA512 => Ok(Category::SHA512),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SMAP => Ok(Category::Smap),
|
ffi::_ND_INS_TYPE::ND_CAT_SHIFT => Ok(Category::SHIFT),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SSE => Ok(Category::Sse),
|
ffi::_ND_INS_TYPE::ND_CAT_SM3 => Ok(Category::SM3),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SSE2 => Ok(Category::Sse2),
|
ffi::_ND_INS_TYPE::ND_CAT_SM4 => Ok(Category::SM4),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_STRINGOP => Ok(Category::Stringop),
|
ffi::_ND_INS_TYPE::ND_CAT_SMAP => Ok(Category::SMAP),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_STTNI => Ok(Category::Sttni),
|
ffi::_ND_INS_TYPE::ND_CAT_SSE => Ok(Category::SSE),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SYSCALL => Ok(Category::Syscall),
|
ffi::_ND_INS_TYPE::ND_CAT_SSE2 => Ok(Category::SSE2),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SYSRET => Ok(Category::Sysret),
|
ffi::_ND_INS_TYPE::ND_CAT_STRINGOP => Ok(Category::STRINGOP),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_SYSTEM => Ok(Category::System),
|
ffi::_ND_INS_TYPE::ND_CAT_STTNI => Ok(Category::STTNI),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_TDX => Ok(Category::Tdx),
|
ffi::_ND_INS_TYPE::ND_CAT_SYSCALL => Ok(Category::SYSCALL),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_UD => Ok(Category::Ud),
|
ffi::_ND_INS_TYPE::ND_CAT_SYSRET => Ok(Category::SYSRET),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_UINTR => Ok(Category::Uintr),
|
ffi::_ND_INS_TYPE::ND_CAT_SYSTEM => Ok(Category::SYSTEM),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_UNCOND_BR => Ok(Category::UncondBr),
|
ffi::_ND_INS_TYPE::ND_CAT_TDX => Ok(Category::TDX),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_UNKNOWN => Ok(Category::Unknown),
|
ffi::_ND_INS_TYPE::ND_CAT_UD => Ok(Category::UD),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_VAES => Ok(Category::Vaes),
|
ffi::_ND_INS_TYPE::ND_CAT_UINTR => Ok(Category::UINTR),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_VFMA => Ok(Category::Vfma),
|
ffi::_ND_INS_TYPE::ND_CAT_UNCOND_BR => Ok(Category::UNCOND_BR),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_VFMAPS => Ok(Category::Vfmaps),
|
ffi::_ND_INS_TYPE::ND_CAT_UNKNOWN => Ok(Category::UNKNOWN),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_VNNI => Ok(Category::Vnni),
|
ffi::_ND_INS_TYPE::ND_CAT_VAES => Ok(Category::VAES),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_VNNIW => Ok(Category::Vnniw),
|
ffi::_ND_INS_TYPE::ND_CAT_VFMA => Ok(Category::VFMA),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_VPCLMULQDQ => Ok(Category::Vpclmulqdq),
|
ffi::_ND_INS_TYPE::ND_CAT_VFMAPS => Ok(Category::VFMAPS),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_VPOPCNT => Ok(Category::Vpopcnt),
|
ffi::_ND_INS_TYPE::ND_CAT_VNNI => Ok(Category::VNNI),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_VTX => Ok(Category::Vtx),
|
ffi::_ND_INS_TYPE::ND_CAT_VNNIW => Ok(Category::VNNIW),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_WAITPKG => Ok(Category::Waitpkg),
|
ffi::_ND_INS_TYPE::ND_CAT_VPCLMULQDQ => Ok(Category::VPCLMULQDQ),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_WBNOINVD => Ok(Category::Wbnoinvd),
|
ffi::_ND_INS_TYPE::ND_CAT_VPOPCNT => Ok(Category::VPOPCNT),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_WIDENOP => Ok(Category::Widenop),
|
ffi::_ND_INS_TYPE::ND_CAT_VTX => Ok(Category::VTX),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_WIDE_KL => Ok(Category::WideKl),
|
ffi::_ND_INS_TYPE::ND_CAT_WAITPKG => Ok(Category::WAITPKG),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_X87_ALU => Ok(Category::X87Alu),
|
ffi::_ND_INS_TYPE::ND_CAT_WBNOINVD => Ok(Category::WBNOINVD),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_XOP => Ok(Category::Xop),
|
ffi::_ND_INS_TYPE::ND_CAT_WIDENOP => Ok(Category::WIDENOP),
|
||||||
ffi::_ND_INS_TYPE::ND_CAT_XSAVE => Ok(Category::Xsave),
|
ffi::_ND_INS_TYPE::ND_CAT_WIDE_KL => Ok(Category::WIDE_KL),
|
||||||
|
ffi::_ND_INS_TYPE::ND_CAT_X87_ALU => Ok(Category::X87_ALU),
|
||||||
|
ffi::_ND_INS_TYPE::ND_CAT_XOP => Ok(Category::XOP),
|
||||||
|
ffi::_ND_INS_TYPE::ND_CAT_XSAVE => Ok(Category::XSAVE),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -9,134 +9,140 @@ use core::convert::TryFrom;
|
|||||||
|
|
||||||
/// ISA set.
|
/// ISA set.
|
||||||
#[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)]
|
#[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)]
|
||||||
|
#[allow(non_camel_case_types)]
|
||||||
pub enum IsaSet {
|
pub enum IsaSet {
|
||||||
I3dnow,
|
I3DNOW,
|
||||||
Adx,
|
ADX,
|
||||||
Aes,
|
AES,
|
||||||
Amd,
|
AMD,
|
||||||
Amxbf16,
|
AMXBF16,
|
||||||
AmxComplex,
|
AMXCOMPLEX,
|
||||||
Amxfp16,
|
AMXFP16,
|
||||||
Amxint8,
|
AMXINT8,
|
||||||
Amxtile,
|
AMXTILE,
|
||||||
Avx,
|
AVX,
|
||||||
Avx2,
|
AVX2,
|
||||||
Avx2gather,
|
AVX2GATHER,
|
||||||
Avx5124fmaps,
|
AVX5124FMAPS,
|
||||||
Avx5124vnniw,
|
AVX5124VNNIW,
|
||||||
Avx512bf16,
|
AVX512BF16,
|
||||||
Avx512bitalg,
|
AVX512BITALG,
|
||||||
Avx512bw,
|
AVX512BW,
|
||||||
Avx512cd,
|
AVX512CD,
|
||||||
Avx512dq,
|
AVX512DQ,
|
||||||
Avx512er,
|
AVX512ER,
|
||||||
Avx512f,
|
AVX512F,
|
||||||
Avx512fp16,
|
AVX512FP16,
|
||||||
Avx512ifma,
|
AVX512IFMA,
|
||||||
Avx512pf,
|
AVX512PF,
|
||||||
Avx512vbmi,
|
AVX512VBMI,
|
||||||
Avx512vbmi2,
|
AVX512VBMI2,
|
||||||
Avx512vnni,
|
AVX512VNNI,
|
||||||
Avx512vp2intersect,
|
AVX512VP2INTERSECT,
|
||||||
Avx512vpopcntdq,
|
AVX512VPOPCNTDQ,
|
||||||
Avxifma,
|
AVXIFMA,
|
||||||
Avxneconvert,
|
AVXNECONVERT,
|
||||||
Avxvnni,
|
AVXVNNI,
|
||||||
Avxvnniint8,
|
AVXVNNIINT16,
|
||||||
Bmi1,
|
AVXVNNIINT8,
|
||||||
Bmi2,
|
BMI1,
|
||||||
CetIbt,
|
BMI2,
|
||||||
CetSs,
|
CET_IBT,
|
||||||
Cldemote,
|
CET_SS,
|
||||||
Clfsh,
|
CLDEMOTE,
|
||||||
Clfshopt,
|
CLFSH,
|
||||||
Clwb,
|
CLFSHOPT,
|
||||||
Clzero,
|
CLWB,
|
||||||
Cmpccxadd,
|
CLZERO,
|
||||||
Cmpxchg16b,
|
CMPCCXADD,
|
||||||
Cyrix,
|
CMPXCHG16B,
|
||||||
CyrixSmm,
|
CYRIX,
|
||||||
Enqcmd,
|
CYRIX_SMM,
|
||||||
F16c,
|
ENQCMD,
|
||||||
Fma,
|
F16C,
|
||||||
Fma4,
|
FMA,
|
||||||
Fred,
|
FMA4,
|
||||||
Fxsave,
|
FRED,
|
||||||
Gfni,
|
FXSAVE,
|
||||||
Hreset,
|
GFNI,
|
||||||
|
HRESET,
|
||||||
I186,
|
I186,
|
||||||
I286prot,
|
I286PROT,
|
||||||
I286real,
|
I286REAL,
|
||||||
I386,
|
I386,
|
||||||
I486,
|
I486,
|
||||||
I486real,
|
I486REAL,
|
||||||
I64,
|
I64,
|
||||||
I86,
|
I86,
|
||||||
Invlpgb,
|
INVLPGB,
|
||||||
Invpcid,
|
INVPCID,
|
||||||
Kl,
|
KL,
|
||||||
Lkgs,
|
LKGS,
|
||||||
Longmode,
|
LONGMODE,
|
||||||
Lwp,
|
LWP,
|
||||||
Lzcnt,
|
LZCNT,
|
||||||
Mcommit,
|
MCOMMIT,
|
||||||
Mmx,
|
MMX,
|
||||||
Movbe,
|
MOVBE,
|
||||||
Movdir64b,
|
MOVDIR64B,
|
||||||
Movdiri,
|
MOVDIRI,
|
||||||
Mpx,
|
MPX,
|
||||||
Msrlist,
|
MSRLIST,
|
||||||
Mwaitt,
|
MWAITT,
|
||||||
Pause,
|
PAUSE,
|
||||||
Pclmulqdq,
|
PCLMULQDQ,
|
||||||
Pconfig,
|
PCONFIG,
|
||||||
Pentiumreal,
|
PENTIUMREAL,
|
||||||
Pku,
|
PKU,
|
||||||
Popcnt,
|
POPCNT,
|
||||||
Ppro,
|
PPRO,
|
||||||
Prefetchiti,
|
PREFETCHITI,
|
||||||
PrefetchNop,
|
PREFETCH_NOP,
|
||||||
Ptwrite,
|
PTWRITE,
|
||||||
Raoint,
|
RAOINT,
|
||||||
Rdpid,
|
RDPID,
|
||||||
Rdpmc,
|
RDPMC,
|
||||||
Rdpru,
|
RDPRU,
|
||||||
Rdrand,
|
RDRAND,
|
||||||
Rdseed,
|
RDSEED,
|
||||||
Rdtscp,
|
RDTSCP,
|
||||||
Rdwrfsgs,
|
RDWRFSGS,
|
||||||
Serialize,
|
SERIALIZE,
|
||||||
Sgx,
|
SGX,
|
||||||
Sha,
|
SHA,
|
||||||
Smap,
|
SHA512,
|
||||||
Smx,
|
SM3,
|
||||||
Snp,
|
SM4,
|
||||||
Sse,
|
SMAP,
|
||||||
Sse2,
|
SMX,
|
||||||
Sse3,
|
SNP,
|
||||||
Sse4,
|
SSE,
|
||||||
Sse42,
|
SSE2,
|
||||||
Sse4a,
|
SSE3,
|
||||||
Ssse3,
|
SSE4,
|
||||||
Svm,
|
SSE42,
|
||||||
Tbm,
|
SSE4A,
|
||||||
Tdx,
|
SSSE3,
|
||||||
Tsx,
|
SVM,
|
||||||
Tsxldtrk,
|
TBM,
|
||||||
Ud,
|
TDX,
|
||||||
Uintr,
|
TSE,
|
||||||
Unknown,
|
TSX,
|
||||||
Vaes,
|
TSXLDTRK,
|
||||||
Vpclmulqdq,
|
UD,
|
||||||
Vtx,
|
UINTR,
|
||||||
Waitpkg,
|
UNKNOWN,
|
||||||
Wbnoinvd,
|
VAES,
|
||||||
Wrmsrns,
|
VPCLMULQDQ,
|
||||||
|
VTX,
|
||||||
|
WAITPKG,
|
||||||
|
WBNOINVD,
|
||||||
|
WRMSRNS,
|
||||||
X87,
|
X87,
|
||||||
Xop,
|
XOP,
|
||||||
Xsave,
|
XSAVE,
|
||||||
Xsavec,
|
XSAVEC,
|
||||||
Xsaves,
|
XSAVES,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[doc(hidden)]
|
#[doc(hidden)]
|
||||||
@ -146,133 +152,138 @@ impl TryFrom<ffi::ND_INS_SET> for IsaSet {
|
|||||||
fn try_from(value: ffi::ND_INS_SET) -> Result<Self, Self::Error> {
|
fn try_from(value: ffi::ND_INS_SET) -> Result<Self, Self::Error> {
|
||||||
match value {
|
match value {
|
||||||
ffi::_ND_INS_SET::ND_SET_INVALID => Err(DecodeError::InternalError(value as u64)),
|
ffi::_ND_INS_SET::ND_SET_INVALID => Err(DecodeError::InternalError(value as u64)),
|
||||||
ffi::_ND_INS_SET::ND_SET_3DNOW => Ok(IsaSet::I3dnow),
|
ffi::_ND_INS_SET::ND_SET_3DNOW => Ok(IsaSet::I3DNOW),
|
||||||
ffi::_ND_INS_SET::ND_SET_ADX => Ok(IsaSet::Adx),
|
ffi::_ND_INS_SET::ND_SET_ADX => Ok(IsaSet::ADX),
|
||||||
ffi::_ND_INS_SET::ND_SET_AES => Ok(IsaSet::Aes),
|
ffi::_ND_INS_SET::ND_SET_AES => Ok(IsaSet::AES),
|
||||||
ffi::_ND_INS_SET::ND_SET_AMD => Ok(IsaSet::Amd),
|
ffi::_ND_INS_SET::ND_SET_AMD => Ok(IsaSet::AMD),
|
||||||
ffi::_ND_INS_SET::ND_SET_AMXBF16 => Ok(IsaSet::Amxbf16),
|
ffi::_ND_INS_SET::ND_SET_AMXBF16 => Ok(IsaSet::AMXBF16),
|
||||||
ffi::_ND_INS_SET::ND_SET_AMXCOMPLEX => Ok(IsaSet::AmxComplex),
|
ffi::_ND_INS_SET::ND_SET_AMXCOMPLEX => Ok(IsaSet::AMXCOMPLEX),
|
||||||
ffi::_ND_INS_SET::ND_SET_AMXFP16 => Ok(IsaSet::Amxfp16),
|
ffi::_ND_INS_SET::ND_SET_AMXFP16 => Ok(IsaSet::AMXFP16),
|
||||||
ffi::_ND_INS_SET::ND_SET_AMXINT8 => Ok(IsaSet::Amxint8),
|
ffi::_ND_INS_SET::ND_SET_AMXINT8 => Ok(IsaSet::AMXINT8),
|
||||||
ffi::_ND_INS_SET::ND_SET_AMXTILE => Ok(IsaSet::Amxtile),
|
ffi::_ND_INS_SET::ND_SET_AMXTILE => Ok(IsaSet::AMXTILE),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX => Ok(IsaSet::Avx),
|
ffi::_ND_INS_SET::ND_SET_AVX => Ok(IsaSet::AVX),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX2 => Ok(IsaSet::Avx2),
|
ffi::_ND_INS_SET::ND_SET_AVX2 => Ok(IsaSet::AVX2),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX2GATHER => Ok(IsaSet::Avx2gather),
|
ffi::_ND_INS_SET::ND_SET_AVX2GATHER => Ok(IsaSet::AVX2GATHER),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX5124FMAPS => Ok(IsaSet::Avx5124fmaps),
|
ffi::_ND_INS_SET::ND_SET_AVX5124FMAPS => Ok(IsaSet::AVX5124FMAPS),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX5124VNNIW => Ok(IsaSet::Avx5124vnniw),
|
ffi::_ND_INS_SET::ND_SET_AVX5124VNNIW => Ok(IsaSet::AVX5124VNNIW),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512BF16 => Ok(IsaSet::Avx512bf16),
|
ffi::_ND_INS_SET::ND_SET_AVX512BF16 => Ok(IsaSet::AVX512BF16),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512BITALG => Ok(IsaSet::Avx512bitalg),
|
ffi::_ND_INS_SET::ND_SET_AVX512BITALG => Ok(IsaSet::AVX512BITALG),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512BW => Ok(IsaSet::Avx512bw),
|
ffi::_ND_INS_SET::ND_SET_AVX512BW => Ok(IsaSet::AVX512BW),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512CD => Ok(IsaSet::Avx512cd),
|
ffi::_ND_INS_SET::ND_SET_AVX512CD => Ok(IsaSet::AVX512CD),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512DQ => Ok(IsaSet::Avx512dq),
|
ffi::_ND_INS_SET::ND_SET_AVX512DQ => Ok(IsaSet::AVX512DQ),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512ER => Ok(IsaSet::Avx512er),
|
ffi::_ND_INS_SET::ND_SET_AVX512ER => Ok(IsaSet::AVX512ER),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512F => Ok(IsaSet::Avx512f),
|
ffi::_ND_INS_SET::ND_SET_AVX512F => Ok(IsaSet::AVX512F),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512FP16 => Ok(IsaSet::Avx512fp16),
|
ffi::_ND_INS_SET::ND_SET_AVX512FP16 => Ok(IsaSet::AVX512FP16),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512IFMA => Ok(IsaSet::Avx512ifma),
|
ffi::_ND_INS_SET::ND_SET_AVX512IFMA => Ok(IsaSet::AVX512IFMA),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512PF => Ok(IsaSet::Avx512pf),
|
ffi::_ND_INS_SET::ND_SET_AVX512PF => Ok(IsaSet::AVX512PF),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512VBMI => Ok(IsaSet::Avx512vbmi),
|
ffi::_ND_INS_SET::ND_SET_AVX512VBMI => Ok(IsaSet::AVX512VBMI),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512VBMI2 => Ok(IsaSet::Avx512vbmi2),
|
ffi::_ND_INS_SET::ND_SET_AVX512VBMI2 => Ok(IsaSet::AVX512VBMI2),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512VNNI => Ok(IsaSet::Avx512vnni),
|
ffi::_ND_INS_SET::ND_SET_AVX512VNNI => Ok(IsaSet::AVX512VNNI),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512VP2INTERSECT => Ok(IsaSet::Avx512vp2intersect),
|
ffi::_ND_INS_SET::ND_SET_AVX512VP2INTERSECT => Ok(IsaSet::AVX512VP2INTERSECT),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVX512VPOPCNTDQ => Ok(IsaSet::Avx512vpopcntdq),
|
ffi::_ND_INS_SET::ND_SET_AVX512VPOPCNTDQ => Ok(IsaSet::AVX512VPOPCNTDQ),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVXIFMA => Ok(IsaSet::Avxifma),
|
ffi::_ND_INS_SET::ND_SET_AVXIFMA => Ok(IsaSet::AVXIFMA),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVXNECONVERT => Ok(IsaSet::Avxneconvert),
|
ffi::_ND_INS_SET::ND_SET_AVXNECONVERT => Ok(IsaSet::AVXNECONVERT),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVXVNNI => Ok(IsaSet::Avxvnni),
|
ffi::_ND_INS_SET::ND_SET_AVXVNNI => Ok(IsaSet::AVXVNNI),
|
||||||
ffi::_ND_INS_SET::ND_SET_AVXVNNIINT8 => Ok(IsaSet::Avxvnniint8),
|
ffi::_ND_INS_SET::ND_SET_AVXVNNIINT16 => Ok(IsaSet::AVXVNNIINT16),
|
||||||
ffi::_ND_INS_SET::ND_SET_BMI1 => Ok(IsaSet::Bmi1),
|
ffi::_ND_INS_SET::ND_SET_AVXVNNIINT8 => Ok(IsaSet::AVXVNNIINT8),
|
||||||
ffi::_ND_INS_SET::ND_SET_BMI2 => Ok(IsaSet::Bmi2),
|
ffi::_ND_INS_SET::ND_SET_BMI1 => Ok(IsaSet::BMI1),
|
||||||
ffi::_ND_INS_SET::ND_SET_CET_IBT => Ok(IsaSet::CetIbt),
|
ffi::_ND_INS_SET::ND_SET_BMI2 => Ok(IsaSet::BMI2),
|
||||||
ffi::_ND_INS_SET::ND_SET_CET_SS => Ok(IsaSet::CetSs),
|
ffi::_ND_INS_SET::ND_SET_CET_IBT => Ok(IsaSet::CET_IBT),
|
||||||
ffi::_ND_INS_SET::ND_SET_CLDEMOTE => Ok(IsaSet::Cldemote),
|
ffi::_ND_INS_SET::ND_SET_CET_SS => Ok(IsaSet::CET_SS),
|
||||||
ffi::_ND_INS_SET::ND_SET_CLFSH => Ok(IsaSet::Clfsh),
|
ffi::_ND_INS_SET::ND_SET_CLDEMOTE => Ok(IsaSet::CLDEMOTE),
|
||||||
ffi::_ND_INS_SET::ND_SET_CLFSHOPT => Ok(IsaSet::Clfshopt),
|
ffi::_ND_INS_SET::ND_SET_CLFSH => Ok(IsaSet::CLFSH),
|
||||||
ffi::_ND_INS_SET::ND_SET_CLWB => Ok(IsaSet::Clwb),
|
ffi::_ND_INS_SET::ND_SET_CLFSHOPT => Ok(IsaSet::CLFSHOPT),
|
||||||
ffi::_ND_INS_SET::ND_SET_CLZERO => Ok(IsaSet::Clzero),
|
ffi::_ND_INS_SET::ND_SET_CLWB => Ok(IsaSet::CLWB),
|
||||||
ffi::_ND_INS_SET::ND_SET_CMPCCXADD => Ok(IsaSet::Cmpccxadd),
|
ffi::_ND_INS_SET::ND_SET_CLZERO => Ok(IsaSet::CLZERO),
|
||||||
ffi::_ND_INS_SET::ND_SET_CMPXCHG16B => Ok(IsaSet::Cmpxchg16b),
|
ffi::_ND_INS_SET::ND_SET_CMPCCXADD => Ok(IsaSet::CMPCCXADD),
|
||||||
ffi::_ND_INS_SET::ND_SET_CYRIX => Ok(IsaSet::Cyrix),
|
ffi::_ND_INS_SET::ND_SET_CMPXCHG16B => Ok(IsaSet::CMPXCHG16B),
|
||||||
ffi::_ND_INS_SET::ND_SET_CYRIX_SMM => Ok(IsaSet::CyrixSmm),
|
ffi::_ND_INS_SET::ND_SET_CYRIX => Ok(IsaSet::CYRIX),
|
||||||
ffi::_ND_INS_SET::ND_SET_ENQCMD => Ok(IsaSet::Enqcmd),
|
ffi::_ND_INS_SET::ND_SET_CYRIX_SMM => Ok(IsaSet::CYRIX_SMM),
|
||||||
ffi::_ND_INS_SET::ND_SET_F16C => Ok(IsaSet::F16c),
|
ffi::_ND_INS_SET::ND_SET_ENQCMD => Ok(IsaSet::ENQCMD),
|
||||||
ffi::_ND_INS_SET::ND_SET_FMA => Ok(IsaSet::Fma),
|
ffi::_ND_INS_SET::ND_SET_F16C => Ok(IsaSet::F16C),
|
||||||
ffi::_ND_INS_SET::ND_SET_FMA4 => Ok(IsaSet::Fma4),
|
ffi::_ND_INS_SET::ND_SET_FMA => Ok(IsaSet::FMA),
|
||||||
ffi::_ND_INS_SET::ND_SET_FRED => Ok(IsaSet::Fred),
|
ffi::_ND_INS_SET::ND_SET_FMA4 => Ok(IsaSet::FMA4),
|
||||||
ffi::_ND_INS_SET::ND_SET_FXSAVE => Ok(IsaSet::Fxsave),
|
ffi::_ND_INS_SET::ND_SET_FRED => Ok(IsaSet::FRED),
|
||||||
ffi::_ND_INS_SET::ND_SET_GFNI => Ok(IsaSet::Gfni),
|
ffi::_ND_INS_SET::ND_SET_FXSAVE => Ok(IsaSet::FXSAVE),
|
||||||
ffi::_ND_INS_SET::ND_SET_HRESET => Ok(IsaSet::Hreset),
|
ffi::_ND_INS_SET::ND_SET_GFNI => Ok(IsaSet::GFNI),
|
||||||
|
ffi::_ND_INS_SET::ND_SET_HRESET => Ok(IsaSet::HRESET),
|
||||||
ffi::_ND_INS_SET::ND_SET_I186 => Ok(IsaSet::I186),
|
ffi::_ND_INS_SET::ND_SET_I186 => Ok(IsaSet::I186),
|
||||||
ffi::_ND_INS_SET::ND_SET_I286PROT => Ok(IsaSet::I286prot),
|
ffi::_ND_INS_SET::ND_SET_I286PROT => Ok(IsaSet::I286PROT),
|
||||||
ffi::_ND_INS_SET::ND_SET_I286REAL => Ok(IsaSet::I286real),
|
ffi::_ND_INS_SET::ND_SET_I286REAL => Ok(IsaSet::I286REAL),
|
||||||
ffi::_ND_INS_SET::ND_SET_I386 => Ok(IsaSet::I386),
|
ffi::_ND_INS_SET::ND_SET_I386 => Ok(IsaSet::I386),
|
||||||
ffi::_ND_INS_SET::ND_SET_I486 => Ok(IsaSet::I486),
|
ffi::_ND_INS_SET::ND_SET_I486 => Ok(IsaSet::I486),
|
||||||
ffi::_ND_INS_SET::ND_SET_I486REAL => Ok(IsaSet::I486real),
|
ffi::_ND_INS_SET::ND_SET_I486REAL => Ok(IsaSet::I486REAL),
|
||||||
ffi::_ND_INS_SET::ND_SET_I64 => Ok(IsaSet::I64),
|
ffi::_ND_INS_SET::ND_SET_I64 => Ok(IsaSet::I64),
|
||||||
ffi::_ND_INS_SET::ND_SET_I86 => Ok(IsaSet::I86),
|
ffi::_ND_INS_SET::ND_SET_I86 => Ok(IsaSet::I86),
|
||||||
ffi::_ND_INS_SET::ND_SET_INVLPGB => Ok(IsaSet::Invlpgb),
|
ffi::_ND_INS_SET::ND_SET_INVLPGB => Ok(IsaSet::INVLPGB),
|
||||||
ffi::_ND_INS_SET::ND_SET_INVPCID => Ok(IsaSet::Invpcid),
|
ffi::_ND_INS_SET::ND_SET_INVPCID => Ok(IsaSet::INVPCID),
|
||||||
ffi::_ND_INS_SET::ND_SET_KL => Ok(IsaSet::Kl),
|
ffi::_ND_INS_SET::ND_SET_KL => Ok(IsaSet::KL),
|
||||||
ffi::_ND_INS_SET::ND_SET_LKGS => Ok(IsaSet::Lkgs),
|
ffi::_ND_INS_SET::ND_SET_LKGS => Ok(IsaSet::LKGS),
|
||||||
ffi::_ND_INS_SET::ND_SET_LONGMODE => Ok(IsaSet::Longmode),
|
ffi::_ND_INS_SET::ND_SET_LONGMODE => Ok(IsaSet::LONGMODE),
|
||||||
ffi::_ND_INS_SET::ND_SET_LWP => Ok(IsaSet::Lwp),
|
ffi::_ND_INS_SET::ND_SET_LWP => Ok(IsaSet::LWP),
|
||||||
ffi::_ND_INS_SET::ND_SET_LZCNT => Ok(IsaSet::Lzcnt),
|
ffi::_ND_INS_SET::ND_SET_LZCNT => Ok(IsaSet::LZCNT),
|
||||||
ffi::_ND_INS_SET::ND_SET_MCOMMIT => Ok(IsaSet::Mcommit),
|
ffi::_ND_INS_SET::ND_SET_MCOMMIT => Ok(IsaSet::MCOMMIT),
|
||||||
ffi::_ND_INS_SET::ND_SET_MMX => Ok(IsaSet::Mmx),
|
ffi::_ND_INS_SET::ND_SET_MMX => Ok(IsaSet::MMX),
|
||||||
ffi::_ND_INS_SET::ND_SET_MOVBE => Ok(IsaSet::Movbe),
|
ffi::_ND_INS_SET::ND_SET_MOVBE => Ok(IsaSet::MOVBE),
|
||||||
ffi::_ND_INS_SET::ND_SET_MOVDIR64B => Ok(IsaSet::Movdir64b),
|
ffi::_ND_INS_SET::ND_SET_MOVDIR64B => Ok(IsaSet::MOVDIR64B),
|
||||||
ffi::_ND_INS_SET::ND_SET_MOVDIRI => Ok(IsaSet::Movdiri),
|
ffi::_ND_INS_SET::ND_SET_MOVDIRI => Ok(IsaSet::MOVDIRI),
|
||||||
ffi::_ND_INS_SET::ND_SET_MPX => Ok(IsaSet::Mpx),
|
ffi::_ND_INS_SET::ND_SET_MPX => Ok(IsaSet::MPX),
|
||||||
ffi::_ND_INS_SET::ND_SET_MSRLIST => Ok(IsaSet::Msrlist),
|
ffi::_ND_INS_SET::ND_SET_MSRLIST => Ok(IsaSet::MSRLIST),
|
||||||
ffi::_ND_INS_SET::ND_SET_MWAITT => Ok(IsaSet::Mwaitt),
|
ffi::_ND_INS_SET::ND_SET_MWAITT => Ok(IsaSet::MWAITT),
|
||||||
ffi::_ND_INS_SET::ND_SET_PAUSE => Ok(IsaSet::Pause),
|
ffi::_ND_INS_SET::ND_SET_PAUSE => Ok(IsaSet::PAUSE),
|
||||||
ffi::_ND_INS_SET::ND_SET_PCLMULQDQ => Ok(IsaSet::Pclmulqdq),
|
ffi::_ND_INS_SET::ND_SET_PCLMULQDQ => Ok(IsaSet::PCLMULQDQ),
|
||||||
ffi::_ND_INS_SET::ND_SET_PCONFIG => Ok(IsaSet::Pconfig),
|
ffi::_ND_INS_SET::ND_SET_PCONFIG => Ok(IsaSet::PCONFIG),
|
||||||
ffi::_ND_INS_SET::ND_SET_PENTIUMREAL => Ok(IsaSet::Pentiumreal),
|
ffi::_ND_INS_SET::ND_SET_PENTIUMREAL => Ok(IsaSet::PENTIUMREAL),
|
||||||
ffi::_ND_INS_SET::ND_SET_PKU => Ok(IsaSet::Pku),
|
ffi::_ND_INS_SET::ND_SET_PKU => Ok(IsaSet::PKU),
|
||||||
ffi::_ND_INS_SET::ND_SET_POPCNT => Ok(IsaSet::Popcnt),
|
ffi::_ND_INS_SET::ND_SET_POPCNT => Ok(IsaSet::POPCNT),
|
||||||
ffi::_ND_INS_SET::ND_SET_PPRO => Ok(IsaSet::Ppro),
|
ffi::_ND_INS_SET::ND_SET_PPRO => Ok(IsaSet::PPRO),
|
||||||
ffi::_ND_INS_SET::ND_SET_PREFETCHITI => Ok(IsaSet::Prefetchiti),
|
ffi::_ND_INS_SET::ND_SET_PREFETCHITI => Ok(IsaSet::PREFETCHITI),
|
||||||
ffi::_ND_INS_SET::ND_SET_PREFETCH_NOP => Ok(IsaSet::PrefetchNop),
|
ffi::_ND_INS_SET::ND_SET_PREFETCH_NOP => Ok(IsaSet::PREFETCH_NOP),
|
||||||
ffi::_ND_INS_SET::ND_SET_PTWRITE => Ok(IsaSet::Ptwrite),
|
ffi::_ND_INS_SET::ND_SET_PTWRITE => Ok(IsaSet::PTWRITE),
|
||||||
ffi::_ND_INS_SET::ND_SET_RAOINT => Ok(IsaSet::Raoint),
|
ffi::_ND_INS_SET::ND_SET_RAOINT => Ok(IsaSet::RAOINT),
|
||||||
ffi::_ND_INS_SET::ND_SET_RDPID => Ok(IsaSet::Rdpid),
|
ffi::_ND_INS_SET::ND_SET_RDPID => Ok(IsaSet::RDPID),
|
||||||
ffi::_ND_INS_SET::ND_SET_RDPMC => Ok(IsaSet::Rdpmc),
|
ffi::_ND_INS_SET::ND_SET_RDPMC => Ok(IsaSet::RDPMC),
|
||||||
ffi::_ND_INS_SET::ND_SET_RDPRU => Ok(IsaSet::Rdpru),
|
ffi::_ND_INS_SET::ND_SET_RDPRU => Ok(IsaSet::RDPRU),
|
||||||
ffi::_ND_INS_SET::ND_SET_RDRAND => Ok(IsaSet::Rdrand),
|
ffi::_ND_INS_SET::ND_SET_RDRAND => Ok(IsaSet::RDRAND),
|
||||||
ffi::_ND_INS_SET::ND_SET_RDSEED => Ok(IsaSet::Rdseed),
|
ffi::_ND_INS_SET::ND_SET_RDSEED => Ok(IsaSet::RDSEED),
|
||||||
ffi::_ND_INS_SET::ND_SET_RDTSCP => Ok(IsaSet::Rdtscp),
|
ffi::_ND_INS_SET::ND_SET_RDTSCP => Ok(IsaSet::RDTSCP),
|
||||||
ffi::_ND_INS_SET::ND_SET_RDWRFSGS => Ok(IsaSet::Rdwrfsgs),
|
ffi::_ND_INS_SET::ND_SET_RDWRFSGS => Ok(IsaSet::RDWRFSGS),
|
||||||
ffi::_ND_INS_SET::ND_SET_SERIALIZE => Ok(IsaSet::Serialize),
|
ffi::_ND_INS_SET::ND_SET_SERIALIZE => Ok(IsaSet::SERIALIZE),
|
||||||
ffi::_ND_INS_SET::ND_SET_SGX => Ok(IsaSet::Sgx),
|
ffi::_ND_INS_SET::ND_SET_SGX => Ok(IsaSet::SGX),
|
||||||
ffi::_ND_INS_SET::ND_SET_SHA => Ok(IsaSet::Sha),
|
ffi::_ND_INS_SET::ND_SET_SHA => Ok(IsaSet::SHA),
|
||||||
ffi::_ND_INS_SET::ND_SET_SMAP => Ok(IsaSet::Smap),
|
ffi::_ND_INS_SET::ND_SET_SHA512 => Ok(IsaSet::SHA512),
|
||||||
ffi::_ND_INS_SET::ND_SET_SMX => Ok(IsaSet::Smx),
|
ffi::_ND_INS_SET::ND_SET_SM3 => Ok(IsaSet::SM3),
|
||||||
ffi::_ND_INS_SET::ND_SET_SNP => Ok(IsaSet::Snp),
|
ffi::_ND_INS_SET::ND_SET_SM4 => Ok(IsaSet::SM4),
|
||||||
ffi::_ND_INS_SET::ND_SET_SSE => Ok(IsaSet::Sse),
|
ffi::_ND_INS_SET::ND_SET_SMAP => Ok(IsaSet::SMAP),
|
||||||
ffi::_ND_INS_SET::ND_SET_SSE2 => Ok(IsaSet::Sse2),
|
ffi::_ND_INS_SET::ND_SET_SMX => Ok(IsaSet::SMX),
|
||||||
ffi::_ND_INS_SET::ND_SET_SSE3 => Ok(IsaSet::Sse3),
|
ffi::_ND_INS_SET::ND_SET_SNP => Ok(IsaSet::SNP),
|
||||||
ffi::_ND_INS_SET::ND_SET_SSE4 => Ok(IsaSet::Sse4),
|
ffi::_ND_INS_SET::ND_SET_SSE => Ok(IsaSet::SSE),
|
||||||
ffi::_ND_INS_SET::ND_SET_SSE42 => Ok(IsaSet::Sse42),
|
ffi::_ND_INS_SET::ND_SET_SSE2 => Ok(IsaSet::SSE2),
|
||||||
ffi::_ND_INS_SET::ND_SET_SSE4A => Ok(IsaSet::Sse4a),
|
ffi::_ND_INS_SET::ND_SET_SSE3 => Ok(IsaSet::SSE3),
|
||||||
ffi::_ND_INS_SET::ND_SET_SSSE3 => Ok(IsaSet::Ssse3),
|
ffi::_ND_INS_SET::ND_SET_SSE4 => Ok(IsaSet::SSE4),
|
||||||
ffi::_ND_INS_SET::ND_SET_SVM => Ok(IsaSet::Svm),
|
ffi::_ND_INS_SET::ND_SET_SSE42 => Ok(IsaSet::SSE42),
|
||||||
ffi::_ND_INS_SET::ND_SET_TBM => Ok(IsaSet::Tbm),
|
ffi::_ND_INS_SET::ND_SET_SSE4A => Ok(IsaSet::SSE4A),
|
||||||
ffi::_ND_INS_SET::ND_SET_TDX => Ok(IsaSet::Tdx),
|
ffi::_ND_INS_SET::ND_SET_SSSE3 => Ok(IsaSet::SSSE3),
|
||||||
ffi::_ND_INS_SET::ND_SET_TSX => Ok(IsaSet::Tsx),
|
ffi::_ND_INS_SET::ND_SET_SVM => Ok(IsaSet::SVM),
|
||||||
ffi::_ND_INS_SET::ND_SET_TSXLDTRK => Ok(IsaSet::Tsxldtrk),
|
ffi::_ND_INS_SET::ND_SET_TBM => Ok(IsaSet::TBM),
|
||||||
ffi::_ND_INS_SET::ND_SET_UD => Ok(IsaSet::Ud),
|
ffi::_ND_INS_SET::ND_SET_TDX => Ok(IsaSet::TDX),
|
||||||
ffi::_ND_INS_SET::ND_SET_UINTR => Ok(IsaSet::Uintr),
|
ffi::_ND_INS_SET::ND_SET_TSE => Ok(IsaSet::TSE),
|
||||||
ffi::_ND_INS_SET::ND_SET_UNKNOWN => Ok(IsaSet::Unknown),
|
ffi::_ND_INS_SET::ND_SET_TSX => Ok(IsaSet::TSX),
|
||||||
ffi::_ND_INS_SET::ND_SET_VAES => Ok(IsaSet::Vaes),
|
ffi::_ND_INS_SET::ND_SET_TSXLDTRK => Ok(IsaSet::TSXLDTRK),
|
||||||
ffi::_ND_INS_SET::ND_SET_VPCLMULQDQ => Ok(IsaSet::Vpclmulqdq),
|
ffi::_ND_INS_SET::ND_SET_UD => Ok(IsaSet::UD),
|
||||||
ffi::_ND_INS_SET::ND_SET_VTX => Ok(IsaSet::Vtx),
|
ffi::_ND_INS_SET::ND_SET_UINTR => Ok(IsaSet::UINTR),
|
||||||
ffi::_ND_INS_SET::ND_SET_WAITPKG => Ok(IsaSet::Waitpkg),
|
ffi::_ND_INS_SET::ND_SET_UNKNOWN => Ok(IsaSet::UNKNOWN),
|
||||||
ffi::_ND_INS_SET::ND_SET_WBNOINVD => Ok(IsaSet::Wbnoinvd),
|
ffi::_ND_INS_SET::ND_SET_VAES => Ok(IsaSet::VAES),
|
||||||
ffi::_ND_INS_SET::ND_SET_WRMSRNS => Ok(IsaSet::Wrmsrns),
|
ffi::_ND_INS_SET::ND_SET_VPCLMULQDQ => Ok(IsaSet::VPCLMULQDQ),
|
||||||
|
ffi::_ND_INS_SET::ND_SET_VTX => Ok(IsaSet::VTX),
|
||||||
|
ffi::_ND_INS_SET::ND_SET_WAITPKG => Ok(IsaSet::WAITPKG),
|
||||||
|
ffi::_ND_INS_SET::ND_SET_WBNOINVD => Ok(IsaSet::WBNOINVD),
|
||||||
|
ffi::_ND_INS_SET::ND_SET_WRMSRNS => Ok(IsaSet::WRMSRNS),
|
||||||
ffi::_ND_INS_SET::ND_SET_X87 => Ok(IsaSet::X87),
|
ffi::_ND_INS_SET::ND_SET_X87 => Ok(IsaSet::X87),
|
||||||
ffi::_ND_INS_SET::ND_SET_XOP => Ok(IsaSet::Xop),
|
ffi::_ND_INS_SET::ND_SET_XOP => Ok(IsaSet::XOP),
|
||||||
ffi::_ND_INS_SET::ND_SET_XSAVE => Ok(IsaSet::Xsave),
|
ffi::_ND_INS_SET::ND_SET_XSAVE => Ok(IsaSet::XSAVE),
|
||||||
ffi::_ND_INS_SET::ND_SET_XSAVEC => Ok(IsaSet::Xsavec),
|
ffi::_ND_INS_SET::ND_SET_XSAVEC => Ok(IsaSet::XSAVEC),
|
||||||
ffi::_ND_INS_SET::ND_SET_XSAVES => Ok(IsaSet::Xsaves),
|
ffi::_ND_INS_SET::ND_SET_XSAVES => Ok(IsaSet::XSAVES),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -38,7 +38,7 @@
|
|||||||
//! let code = vec![0x31, 0xc0];
|
//! let code = vec![0x31, 0xc0];
|
||||||
//! match DecodedInstruction::decode(&code, DecodeMode::Bits32) {
|
//! match DecodedInstruction::decode(&code, DecodeMode::Bits32) {
|
||||||
//! Ok(ins) => {
|
//! Ok(ins) => {
|
||||||
//! assert_eq!(ins.mnemonic(), Mnemonic::Xor);
|
//! assert_eq!(ins.mnemonic(), Mnemonic::XOR);
|
||||||
//! println!("{}", ins);
|
//! println!("{}", ins);
|
||||||
//! },
|
//! },
|
||||||
//! Err(err) => println!("Unable to decode: {}", err),
|
//! Err(err) => println!("Unable to decode: {}", err),
|
||||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user