summaryrefslogtreecommitdiff
path: root/rust/src/mlil/instruction.rs
diff options
context:
space:
mode:
authorRusty Wagner <rusty.wagner@gmail.com>2023-11-09 18:39:55 -0500
committerRusty Wagner <rusty.wagner@gmail.com>2023-12-06 13:48:37 -0500
commite9604c37df479a991d131d9540fafe78c7a0f7d4 (patch)
treed1ac45fbc0da8dbfd3d09fec0625d11a5cfbc69e /rust/src/mlil/instruction.rs
parent6e1a863a4b20d73610e88cb7d9adf676c1053fce (diff)
Add LLIL/MLIL instructions to describe integer vs. floating point argument usage
Diffstat (limited to 'rust/src/mlil/instruction.rs')
-rw-r--r--rust/src/mlil/instruction.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/rust/src/mlil/instruction.rs b/rust/src/mlil/instruction.rs
index 5e237128..139abe20 100644
--- a/rust/src/mlil/instruction.rs
+++ b/rust/src/mlil/instruction.rs
@@ -113,6 +113,8 @@ pub enum MediumLevelILOperation {
CallUntyped(CallUntyped),
TailcallUntyped(CallUntyped),
SyscallUntyped(SyscallUntyped),
+ SeparateParamList(SeparateParamList),
+ SharedParamSlot(SharedParamSlot),
Neg(UnaryOp),
Not(UnaryOp),
Sx(UnaryOp),
@@ -535,6 +537,12 @@ impl MediumLevelILInstruction {
op.operands[1] as usize,
op.operands[2] as usize,
)),
+ MLIL_SEPARATE_PARAM_LIST => Op::SeparateParamList(SeparateParamList::new(
+ (op.operands[0] as usize, op.operands[1] as usize)
+ )),
+ MLIL_SHARED_PARAM_SLOT => Op::SharedParamSlot(SharedParamSlot::new(
+ (op.operands[0] as usize, op.operands[1] as usize)
+ )),
MLIL_NEG => Op::Neg(UnaryOp::new(op.operands[0] as usize)),
MLIL_NOT => Op::Not(UnaryOp::new(op.operands[0] as usize)),
MLIL_SX => Op::Sx(UnaryOp::new(op.operands[0] as usize)),
@@ -706,6 +714,8 @@ impl MediumLevelILInstruction {
CallUntyped(op) => Lifted::CallUntyped(op.lift(&self.function)),
TailcallUntyped(op) => Lifted::TailcallUntyped(op.lift(&self.function)),
SyscallUntyped(op) => Lifted::SyscallUntyped(op.lift(&self.function)),
+ SeparateParamList(op) => Lifted::SeparateParamList(op.lift(&self.function)),
+ SharedParamSlot(op) => Lifted::SharedParamSlot(op.lift(&self.function)),
Neg(op) => Lifted::Neg(op.lift(&self.function)),
Not(op) => Lifted::Not(op.lift(&self.function)),
Sx(op) => Lifted::Sx(op.lift(&self.function)),
@@ -793,6 +803,8 @@ impl MediumLevelILInstruction {
SyscallUntypedSsa(op) => Box::new(op.operands(&self.function)),
CallUntyped(op) | TailcallUntyped(op) => Box::new(op.operands(&self.function)),
SyscallUntyped(op) => Box::new(op.operands(&self.function)),
+ SeparateParamList(op) => Box::new(op.operands(&self.function)),
+ SharedParamSlot(op) => Box::new(op.operands(&self.function)),
Neg(op) | Not(op) | Sx(op) | Zx(op) | LowPart(op) | BoolToInt(op) | UnimplMem(op)
| Fsqrt(op) | Fneg(op) | Fabs(op) | FloatToInt(op) | IntToFloat(op) | FloatConv(op)
| RoundToInt(op) | Floor(op) | Ceil(op) | Ftrunc(op) | Load(op) => {