From 0748dfe65398f17064ed744a3d198f144d0aa2c5 Mon Sep 17 00:00:00 2001 From: Rusty Wagner Date: Tue, 19 Dec 2023 22:39:11 -0700 Subject: Support intrinsics in Rust architecture plugins --- rust/src/llil/instruction.rs | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'rust/src/llil/instruction.rs') diff --git a/rust/src/llil/instruction.rs b/rust/src/llil/instruction.rs index e5ae508b..c9817dbf 100644 --- a/rust/src/llil/instruction.rs +++ b/rust/src/llil/instruction.rs @@ -112,6 +112,7 @@ where InstrInfo::Call(Operation::new(self.function, op)) } LLIL_SYSCALL => InstrInfo::Syscall(Operation::new(self.function, op)), + LLIL_INTRINSIC => InstrInfo::Intrinsic(Operation::new(self.function, op)), _ => { common_info(self.function, op).unwrap_or({ // Hopefully this is a bare value. If it isn't (expression @@ -149,6 +150,12 @@ where } Push(ref op) => visit!(fb, &op.operand()), Call(ref op) => visit!(fb, &op.target()), + Intrinsic(ref _op) => { + // TODO: Use this when we support expression lists + // for expr in op.source_exprs() { + // visit!(fb, expr); + // } + } _ => visit!(common_visit, &info, fb), } @@ -181,6 +188,7 @@ where Goto(Operation<'func, A, M, F, operation::Goto>), Syscall(Operation<'func, A, M, F, operation::Syscall>), + Intrinsic(Operation<'func, A, M, F, operation::Intrinsic>), Bp(Operation<'func, A, M, F, operation::NoArgs>), Trap(Operation<'func, A, M, F, operation::Trap>), Undef(Operation<'func, A, M, F, operation::NoArgs>), -- cgit v1.3.1