Skip to content

Commit

Permalink
rename abstractInterpretation
Browse files Browse the repository at this point in the history
  • Loading branch information
bjjwwang committed Apr 4, 2024
1 parent b243759 commit 5609cc1
Show file tree
Hide file tree
Showing 5 changed files with 66 additions and 65 deletions.
2 changes: 1 addition & 1 deletion svf-llvm/tools/AE/ae.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -663,7 +663,7 @@ int main(int argc, char** argv)
}
else
{
AbstractExecution ae;
AbstractInterpretation ae;

ae.runOnModule(pag->getICFG());
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//===- AE.cpp -- Abstract Execution---------------------------------//
//===- AbstractInterpretation.h -- Abstract Execution----------//
//
// SVF: Static Value-Flow Analysis
//
Expand Down Expand Up @@ -35,7 +35,7 @@

namespace SVF
{
class AbstractExecution;
class AbstractInterpretation;
class AEStat;
class AEAPI;
class ExeState;
Expand All @@ -53,7 +53,7 @@ class AEStat : public SVFStat
{
public:
void countStateSize();
AEStat(AbstractExecution* ae) : _ae(ae)
AEStat(AbstractInterpretation* ae) : _ae(ae)
{
startTime = getClk(true);
}
Expand All @@ -71,7 +71,7 @@ class AEStat : public SVFStat
void reportBug();

public:
AbstractExecution* _ae;
AbstractInterpretation* _ae;
s32_t count{0};
std::string memory_usage;
std::string memUsage;
Expand Down Expand Up @@ -104,7 +104,8 @@ class AEStat : public SVFStat
}
};

class AbstractExecution
/// AbstractInterpretation is same as Abstract Execution
class AbstractInterpretation
{
friend class AEStat;
friend class AEAPI;
Expand All @@ -113,17 +114,17 @@ class AbstractExecution
enum ExtAPIType { UNCLASSIFIED, MEMCPY, MEMSET, STRCPY, STRCAT };
typedef SCCDetection<PTACallGraph*> CallGraphSCC;
/// Constructor
AbstractExecution();
AbstractInterpretation();

virtual void runOnModule(ICFG* icfg);

/// Destructor
virtual ~AbstractExecution();
virtual ~AbstractInterpretation();

/// Program entry
void analyse();

static bool classof(const AbstractExecution* ae)
static bool classof(const AbstractInterpretation* ae)
{
return ae->getKind() == AEKind::AbstractExecution;
}
Expand Down
8 changes: 4 additions & 4 deletions svf/include/AE/Svfexe/BufOverflowChecker.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
// Created by Jiawei Wang on 2024/1/12.
//

#include "AE/Svfexe/AbstractExecution.h"
#include "AE/Svfexe/AbstractInterpretation.h"

namespace SVF
{
Expand Down Expand Up @@ -100,17 +100,17 @@ struct BufOverflowException: public std::exception
const SVFValue* _allocVar;
};

class BufOverflowChecker: public AbstractExecution
class BufOverflowChecker: public AbstractInterpretation
{
public:
BufOverflowChecker() : AbstractExecution()
BufOverflowChecker() : AbstractInterpretation()
{
initExtFunMap();
_kind = AEKind::BufOverflowChecker;
initExtAPIBufOverflowCheckRules();
}

static bool classof(const AbstractExecution* ae)
static bool classof(const AbstractInterpretation* ae)
{
return ae->getKind() == AEKind::BufOverflowChecker;
}
Expand Down
Loading

0 comments on commit 5609cc1

Please sign in to comment.