summaryrefslogtreecommitdiff
path: root/mediumlevelilinstruction.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'mediumlevelilinstruction.cpp')
-rw-r--r--mediumlevelilinstruction.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/mediumlevelilinstruction.cpp b/mediumlevelilinstruction.cpp
index 73f2e59b..ec6aa1c6 100644
--- a/mediumlevelilinstruction.cpp
+++ b/mediumlevelilinstruction.cpp
@@ -149,6 +149,7 @@ unordered_map<BNMediumLevelILOperation, vector<MediumLevelILOperandUsage>>
{MLIL_MEM_PHI, {DestMemoryVersionMediumLevelOperandUsage, SourceMemoryVersionsMediumLevelOperandUsage}},
{MLIL_CONST, {ConstantMediumLevelOperandUsage}},
{MLIL_CONST_PTR, {ConstantMediumLevelOperandUsage}},
+ {MLIL_IMPORT, {ConstantMediumLevelOperandUsage}},
{MLIL_ADD, {LeftExprMediumLevelOperandUsage, RightExprMediumLevelOperandUsage}},
{MLIL_SUB, {LeftExprMediumLevelOperandUsage, RightExprMediumLevelOperandUsage}},
{MLIL_AND, {LeftExprMediumLevelOperandUsage, RightExprMediumLevelOperandUsage}},
@@ -1552,6 +1553,8 @@ ExprId MediumLevelILInstruction::CopyTo(MediumLevelILFunction* dest,
return dest->Const(size, GetConstant<MLIL_CONST>(), *this);
case MLIL_CONST_PTR:
return dest->ConstPointer(size, GetConstant<MLIL_CONST_PTR>(), *this);
+ case MLIL_IMPORT:
+ return dest->ImportedAddress(size, GetConstant<MLIL_IMPORT>(), *this);
case MLIL_BP:
return dest->Breakpoint(*this);
case MLIL_TRAP:
@@ -2086,6 +2089,12 @@ ExprId MediumLevelILFunction::ConstPointer(size_t size, uint64_t val, const ILSo
}
+ExprId MediumLevelILFunction::ImportedAddress(size_t size, uint64_t val, const ILSourceLocation& loc)
+{
+ return AddExprWithLocation(MLIL_IMPORT, loc, size, val);
+}
+
+
ExprId MediumLevelILFunction::Add(size_t size, ExprId left, ExprId right, const ILSourceLocation& loc)
{
return AddExprWithLocation(MLIL_ADD, loc, size, left, right);