summaryrefslogtreecommitdiff
path: root/rust/src/medium_level_il/operation.rs
diff options
context:
space:
mode:
authorMason Reed <mason@vector35.com>2025-05-11 21:00:55 -0400
committerMason Reed <35282038+emesare@users.noreply.github.com>2025-05-12 17:45:24 -0400
commit3b14d1605cf9ea638a0d058911a8c1e233a9f70d (patch)
tree578fde48ea785a21072ba0e2c5c93061e4ba5a72 /rust/src/medium_level_il/operation.rs
parente2fac46543527d27eab2fc77cf19a4f715438857 (diff)
[Rust] Add missing instruction types to MLIL
Diffstat (limited to 'rust/src/medium_level_il/operation.rs')
-rw-r--r--rust/src/medium_level_il/operation.rs78
1 files changed, 78 insertions, 0 deletions
diff --git a/rust/src/medium_level_il/operation.rs b/rust/src/medium_level_il/operation.rs
index e11f59c8..e8b70cc6 100644
--- a/rust/src/medium_level_il/operation.rs
+++ b/rust/src/medium_level_il/operation.rs
@@ -329,6 +329,54 @@ pub struct LiftedCall {
pub params: Vec<MediumLevelILLiftedInstruction>,
}
+// CALL_OUTPUT
+#[derive(Debug, Copy, Clone)]
+pub struct CallOutput {
+ pub first_output: usize,
+ pub num_outputs: usize,
+}
+#[derive(Clone, Debug, PartialEq)]
+pub struct LiftedCallOutput {
+ pub output: Vec<Variable>,
+}
+
+// CALL_PARAM_SSA
+#[derive(Debug, Copy, Clone)]
+pub struct CallParam {
+ pub first_param: usize,
+ pub num_params: usize,
+}
+#[derive(Clone, Debug, PartialEq)]
+pub struct LiftedCallParam {
+ pub params: Vec<MediumLevelILLiftedInstruction>,
+}
+
+// CALL_OUTPUT_SSA
+#[derive(Debug, Copy, Clone)]
+pub struct CallOutputSsa {
+ pub dest_memory: u64,
+ pub first_output: usize,
+ pub num_outputs: usize,
+}
+#[derive(Clone, Debug, PartialEq)]
+pub struct LiftedCallOutputSsa {
+ pub dest_memory: u64,
+ pub output: Vec<SSAVariable>,
+}
+
+// CALL_PARAM_SSA
+#[derive(Debug, Copy, Clone)]
+pub struct CallParamSsa {
+ pub src_memory: u64,
+ pub first_param: usize,
+ pub num_params: usize,
+}
+#[derive(Clone, Debug, PartialEq)]
+pub struct LiftedCallParamSsa {
+ pub src_memory: u64,
+ pub params: Vec<MediumLevelILLiftedInstruction>,
+}
+
// SYSCALL
#[derive(Debug, Copy, Clone)]
pub struct Syscall {
@@ -375,6 +423,36 @@ pub struct LiftedIntrinsicSsa {
pub params: Vec<MediumLevelILLiftedInstruction>,
}
+// MEMORY_INTRINSIC_SSA
+#[derive(Debug, Copy, Clone)]
+pub struct MemoryIntrinsicSsa {
+ pub output: usize,
+ pub intrinsic: u32,
+ pub first_param: usize,
+ pub num_params: usize,
+ pub src_memory: u64,
+}
+#[derive(Clone, Debug, PartialEq)]
+pub struct LiftedMemoryIntrinsicSsa {
+ pub output: Box<MediumLevelILLiftedInstruction>,
+ pub intrinsic: CoreIntrinsic,
+ pub params: Vec<MediumLevelILLiftedInstruction>,
+ pub src_memory: u64,
+}
+
+// MEMORY_INTRINSIC_OUTPUT_SSA
+#[derive(Debug, Copy, Clone)]
+pub struct MemoryIntrinsicOutputSsa {
+ pub dest_memory: u64,
+ pub first_output: usize,
+ pub num_outputs: usize,
+}
+#[derive(Clone, Debug, PartialEq)]
+pub struct LiftedMemoryIntrinsicOutputSsa {
+ pub dest_memory: u64,
+ pub output: Vec<SSAVariable>,
+}
+
// CALL_SSA, TAILCALL_SSA
#[derive(Debug, Copy, Clone)]
pub struct CallSsa {