diff options
author | Owen Anderson <resistor@mac.com> | 2009-07-01 21:22:36 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2009-07-01 21:22:36 +0000 |
commit | 1cf085d558fd73f2599fb68e600365dd20502e2b (patch) | |
tree | 39bfcf795980a39bd173e8cbc60962da057bbd9d /llvm/tools/bugpoint/BugDriver.h | |
parent | 52337414b78f00aa7ff498e5872fd428996e8fe5 (diff) | |
download | bcm5719-llvm-1cf085d558fd73f2599fb68e600365dd20502e2b.tar.gz bcm5719-llvm-1cf085d558fd73f2599fb68e600365dd20502e2b.zip |
Hold the LLVMContext by reference rather than by pointer.
llvm-svn: 74640
Diffstat (limited to 'llvm/tools/bugpoint/BugDriver.h')
-rw-r--r-- | llvm/tools/bugpoint/BugDriver.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/llvm/tools/bugpoint/BugDriver.h b/llvm/tools/bugpoint/BugDriver.h index 4c81cc2a2b6..34267d55a62 100644 --- a/llvm/tools/bugpoint/BugDriver.h +++ b/llvm/tools/bugpoint/BugDriver.h @@ -43,7 +43,7 @@ extern bool DisableSimplifyCFG; extern bool BugpointIsInterrupted; class BugDriver { - LLVMContext* Context; + const LLVMContext& Context; const std::string ToolName; // Name of bugpoint std::string ReferenceOutputFile; // Name of `good' output file Module *Program; // The raw program, linked together @@ -62,11 +62,11 @@ class BugDriver { public: BugDriver(const char *toolname, bool as_child, bool find_bugs, - unsigned timeout, unsigned memlimit, LLVMContext* ctxt); + unsigned timeout, unsigned memlimit, const LLVMContext& ctxt); const std::string &getToolName() const { return ToolName; } - LLVMContext* getContext() { return Context; } + const LLVMContext& getContext() { return Context; } // Set up methods... these methods are used to copy information about the // command line arguments into instance variables of BugDriver. @@ -294,7 +294,8 @@ private: /// ParseInputFile - Given a bitcode or assembly input filename, parse and /// return it, or return null if not possible. /// -Module *ParseInputFile(const std::string &InputFilename, LLVMContext* ctxt); +Module *ParseInputFile(const std::string &InputFilename, + const LLVMContext& ctxt); /// getPassesString - Turn a list of passes into a string which indicates the |