From f1166563f54d28a745eb781dfe27c13a099bb7d9 Mon Sep 17 00:00:00 2001 From: Brian Potchik Date: Wed, 20 Jan 2021 10:53:04 -0500 Subject: Add get_lifted_ils_at API. --- function.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'function.cpp') diff --git a/function.cpp b/function.cpp index 805e9560..80f55fe6 100644 --- a/function.cpp +++ b/function.cpp @@ -558,6 +558,20 @@ size_t Function::GetLiftedILForInstruction(Architecture* arch, uint64_t addr) } +set Function::GetLiftedILInstructionsForAddress(Architecture* arch, uint64_t addr) +{ + size_t count; + size_t* instrs = BNGetLiftedILInstructionsForAddress(m_object, arch->GetObject(), addr, &count); + + set result; + for (size_t i = 0; i < count; i++) + result.insert(instrs[i]); + + BNFreeILInstructionList(instrs); + return result; +} + + set Function::GetLiftedILFlagUsesForDefinition(size_t i, uint32_t flag) { size_t count; -- cgit v1.3.1