[llvm-commits] CVS: llvm/tools/bugpoint/BugDriver.cpp BugDriver.h CodeGeneratorBug.cpp CrashDebugger.cpp ExecutionDriver.cpp ExtractFunction.cpp ListReducer.h Miscompilation.cpp OptimizerDriver.cpp TestPasses.cpp bugpoint.cpp

Brian Gaeke gaeke at cs.uiuc.edu
Tue Nov 11 16:42:42 PST 2003


Changes in directory llvm/tools/bugpoint:

BugDriver.cpp updated: 1.20 -> 1.21
BugDriver.h updated: 1.21 -> 1.22
CodeGeneratorBug.cpp updated: 1.31 -> 1.32
CrashDebugger.cpp updated: 1.24 -> 1.25
ExecutionDriver.cpp updated: 1.32 -> 1.33
ExtractFunction.cpp updated: 1.19 -> 1.20
ListReducer.h updated: 1.7 -> 1.8
Miscompilation.cpp updated: 1.23 -> 1.24
OptimizerDriver.cpp updated: 1.15 -> 1.16
TestPasses.cpp updated: 1.5 -> 1.6
bugpoint.cpp updated: 1.10 -> 1.11

---
Log message:

Put all LLVM code into the llvm namespace, as per bug 109.

---
Diffs of the changes:  (+51 -0)

Index: llvm/tools/bugpoint/BugDriver.cpp
diff -u llvm/tools/bugpoint/BugDriver.cpp:1.20 llvm/tools/bugpoint/BugDriver.cpp:1.21
--- llvm/tools/bugpoint/BugDriver.cpp:1.20	Mon Oct 20 12:57:12 2003
+++ llvm/tools/bugpoint/BugDriver.cpp	Tue Nov 11 16:41:34 2003
@@ -23,6 +23,8 @@
 #include "Support/FileUtilities.h"
 #include <memory>
 
+using namespace llvm;
+
 // Anonymous namespace to define command line options for debugging.
 //
 namespace {
@@ -36,6 +38,8 @@
                                 "(for miscompilation detection)"));
 }
 
+namespace llvm {
+
 /// getPassesString - Turn a list of passes into a string which indicates the
 /// command line options that must be passed to add the passes.
 ///
@@ -179,3 +183,5 @@
   }
   std::cout << std::flush;
 }
+
+} // End llvm namespace


Index: llvm/tools/bugpoint/BugDriver.h
diff -u llvm/tools/bugpoint/BugDriver.h:1.21 llvm/tools/bugpoint/BugDriver.h:1.22
--- llvm/tools/bugpoint/BugDriver.h:1.21	Wed Nov  5 15:45:35 2003
+++ llvm/tools/bugpoint/BugDriver.h	Tue Nov 11 16:41:34 2003
@@ -19,6 +19,8 @@
 #include <vector>
 #include <string>
 
+namespace llvm {
+
 class PassInfo;
 class Module;
 class Function;
@@ -206,5 +208,7 @@
 // blocks, making it external.
 //
 void DeleteFunctionBody(Function *F);
+
+} // End llvm namespace
 
 #endif


Index: llvm/tools/bugpoint/CodeGeneratorBug.cpp
diff -u llvm/tools/bugpoint/CodeGeneratorBug.cpp:1.31 llvm/tools/bugpoint/CodeGeneratorBug.cpp:1.32
--- llvm/tools/bugpoint/CodeGeneratorBug.cpp:1.31	Wed Nov  5 15:45:35 2003
+++ llvm/tools/bugpoint/CodeGeneratorBug.cpp	Tue Nov 11 16:41:34 2003
@@ -33,6 +33,8 @@
 #include <algorithm>
 #include <set>
 
+namespace llvm {
+
 extern cl::list<std::string> InputArgv;
 
 class ReduceMisCodegenFunctions : public ListReducer<Function*> {
@@ -408,3 +410,5 @@
 
   return false;
 }
+
+} // End llvm namespace


Index: llvm/tools/bugpoint/CrashDebugger.cpp
diff -u llvm/tools/bugpoint/CrashDebugger.cpp:1.24 llvm/tools/bugpoint/CrashDebugger.cpp:1.25
--- llvm/tools/bugpoint/CrashDebugger.cpp:1.24	Wed Nov  5 15:45:35 2003
+++ llvm/tools/bugpoint/CrashDebugger.cpp	Tue Nov 11 16:41:34 2003
@@ -29,6 +29,8 @@
 #include <fstream>
 #include <set>
 
+namespace llvm {
+
 class DebugCrashes : public ListReducer<const PassInfo*> {
   BugDriver &BD;
 public:
@@ -397,3 +399,5 @@
 
   return false;
 }
+
+} // End llvm namespace


Index: llvm/tools/bugpoint/ExecutionDriver.cpp
diff -u llvm/tools/bugpoint/ExecutionDriver.cpp:1.32 llvm/tools/bugpoint/ExecutionDriver.cpp:1.33
--- llvm/tools/bugpoint/ExecutionDriver.cpp:1.32	Tue Oct 21 12:41:35 2003
+++ llvm/tools/bugpoint/ExecutionDriver.cpp	Tue Nov 11 16:41:34 2003
@@ -30,6 +30,8 @@
 #include <fstream>
 #include <iostream>
 
+using namespace llvm;
+
 namespace {
   // OutputType - Allow the user to specify the way code should be run, to test
   // for miscompilation.
@@ -58,6 +60,8 @@
                          "into executing programs"));
 }
 
+namespace llvm {
+
 // Anything specified after the --args option are taken as arguments to the
 // program being debugged.
 cl::list<std::string>
@@ -232,3 +236,5 @@
 bool BugDriver::isExecutingJIT() {
   return InterpreterSel == RunJIT;
 }
+
+} // End llvm namespace


Index: llvm/tools/bugpoint/ExtractFunction.cpp
diff -u llvm/tools/bugpoint/ExtractFunction.cpp:1.19 llvm/tools/bugpoint/ExtractFunction.cpp:1.20
--- llvm/tools/bugpoint/ExtractFunction.cpp:1.19	Wed Nov  5 15:45:35 2003
+++ llvm/tools/bugpoint/ExtractFunction.cpp	Tue Nov 11 16:41:34 2003
@@ -25,8 +25,15 @@
 #include "llvm/Target/TargetData.h"
 #include "Support/CommandLine.h"
 
+
+namespace llvm {
+
 bool DisableSimplifyCFG = false;
 
+} // End llvm namespace
+
+using namespace llvm;
+
 namespace {
   cl::opt<bool>
   NoADCE("disable-adce",
@@ -39,6 +46,8 @@
          cl::desc("Do not use the -simplifycfg pass to reduce testcases"));
 }
 
+namespace llvm {
+
 /// deleteInstructionFromProgram - This method clones the current Program and
 /// deletes the specified instruction from the cloned module.  It then runs a
 /// series of cleanup passes (ADCE and SimplifyCFG) to eliminate any code which
@@ -125,3 +134,5 @@
   }
   return M;
 }
+
+} // End llvm namespace


Index: llvm/tools/bugpoint/ListReducer.h
diff -u llvm/tools/bugpoint/ListReducer.h:1.7 llvm/tools/bugpoint/ListReducer.h:1.8
--- llvm/tools/bugpoint/ListReducer.h:1.7	Mon Oct 20 12:57:13 2003
+++ llvm/tools/bugpoint/ListReducer.h	Tue Nov 11 16:41:34 2003
@@ -17,6 +17,8 @@
 
 #include <vector>
 
+namespace llvm {
+
 template<typename ElTy>
 struct ListReducer {
   enum TestResult {
@@ -108,5 +110,7 @@
     return true; // there are some failure and we've narrowed them down
   }
 };
+
+} // End llvm namespace
 
 #endif


Index: llvm/tools/bugpoint/Miscompilation.cpp
diff -u llvm/tools/bugpoint/Miscompilation.cpp:1.23 llvm/tools/bugpoint/Miscompilation.cpp:1.24
--- llvm/tools/bugpoint/Miscompilation.cpp:1.23	Mon Oct 20 12:57:13 2003
+++ llvm/tools/bugpoint/Miscompilation.cpp	Tue Nov 11 16:41:34 2003
@@ -19,6 +19,8 @@
 #include "llvm/Transforms/Utils/Linker.h"
 #include "Support/FileUtilities.h"
 
+namespace llvm {
+
 class ReduceMiscompilingPasses : public ListReducer<const PassInfo*> {
   BugDriver &BD;
 public:
@@ -308,3 +310,5 @@
 
   return false;
 }
+
+} // End llvm namespace


Index: llvm/tools/bugpoint/OptimizerDriver.cpp
diff -u llvm/tools/bugpoint/OptimizerDriver.cpp:1.15 llvm/tools/bugpoint/OptimizerDriver.cpp:1.16
--- llvm/tools/bugpoint/OptimizerDriver.cpp:1.15	Mon Oct 20 12:57:13 2003
+++ llvm/tools/bugpoint/OptimizerDriver.cpp	Tue Nov 11 16:41:34 2003
@@ -26,6 +26,8 @@
 #include <sys/types.h>
 #include <sys/wait.h>
 
+namespace llvm {
+
 /// writeProgramToFile - This writes the current "Program" to the named bytecode
 /// file.  If an error occurs, true is returned.
 ///
@@ -159,3 +161,5 @@
   // Was the child successful?
   return !ExitedOK;
 }
+
+} // End llvm namespace


Index: llvm/tools/bugpoint/TestPasses.cpp
diff -u llvm/tools/bugpoint/TestPasses.cpp:1.5 llvm/tools/bugpoint/TestPasses.cpp:1.6
--- llvm/tools/bugpoint/TestPasses.cpp:1.5	Mon Oct 20 12:57:13 2003
+++ llvm/tools/bugpoint/TestPasses.cpp	Tue Nov 11 16:41:34 2003
@@ -18,6 +18,8 @@
 #include "llvm/Pass.h"
 #include "llvm/Support/InstVisitor.h"
 
+using namespace llvm;
+
 namespace {
   /// CrashOnCalls - This pass is used to test bugpoint.  It intentionally
   /// crashes on any call instructions.


Index: llvm/tools/bugpoint/bugpoint.cpp
diff -u llvm/tools/bugpoint/bugpoint.cpp:1.10 llvm/tools/bugpoint/bugpoint.cpp:1.11
--- llvm/tools/bugpoint/bugpoint.cpp:1.10	Mon Oct 20 12:57:13 2003
+++ llvm/tools/bugpoint/bugpoint.cpp	Tue Nov 11 16:41:34 2003
@@ -19,6 +19,8 @@
 #include "Config/unistd.h"
 #include <sys/resource.h>
 
+using namespace llvm;
+
 static cl::list<std::string>
 InputFilenames(cl::Positional, cl::OneOrMore,
                cl::desc("<input llvm ll/bc files>"));





More information about the llvm-commits mailing list