aboutsummaryrefslogtreecommitdiff
path: root/tools/bugpoint/CodeGeneratorBug.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-01-14 03:38:37 +0000
committerChris Lattner <sabre@nondot.org>2004-01-14 03:38:37 +0000
commitfa76183e8e28985dfd17b1d6291c939dab4cbe1d (patch)
tree5898187ef916460b4a0b844abf0ddee8a8bf1879 /tools/bugpoint/CodeGeneratorBug.cpp
parent277bafbff7384f282c4a409863c220536d6f09b6 (diff)
finegrainify namespacification
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10839 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/bugpoint/CodeGeneratorBug.cpp')
-rw-r--r--tools/bugpoint/CodeGeneratorBug.cpp44
1 files changed, 21 insertions, 23 deletions
diff --git a/tools/bugpoint/CodeGeneratorBug.cpp b/tools/bugpoint/CodeGeneratorBug.cpp
index 0858f4ed0d..18650c0396 100644
--- a/tools/bugpoint/CodeGeneratorBug.cpp
+++ b/tools/bugpoint/CodeGeneratorBug.cpp
@@ -32,29 +32,29 @@
#include "Support/FileUtilities.h"
#include <algorithm>
#include <set>
+using namespace llvm;
namespace llvm {
+ extern cl::list<std::string> InputArgv;
-extern cl::list<std::string> InputArgv;
-
-class ReduceMisCodegenFunctions : public ListReducer<Function*> {
- BugDriver &BD;
-public:
- ReduceMisCodegenFunctions(BugDriver &bd) : BD(bd) {}
-
- virtual TestResult doTest(std::vector<Function*> &Prefix,
- std::vector<Function*> &Suffix) {
- if (!Prefix.empty() && TestFuncs(Prefix))
- return KeepPrefix;
- if (!Suffix.empty() && TestFuncs(Suffix))
- return KeepSuffix;
- return NoFailure;
- }
-
- bool TestFuncs(const std::vector<Function*> &CodegenTest,
- bool KeepFiles = false);
-};
-
+ class ReduceMisCodegenFunctions : public ListReducer<Function*> {
+ BugDriver &BD;
+ public:
+ ReduceMisCodegenFunctions(BugDriver &bd) : BD(bd) {}
+
+ virtual TestResult doTest(std::vector<Function*> &Prefix,
+ std::vector<Function*> &Suffix) {
+ if (!Prefix.empty() && TestFuncs(Prefix))
+ return KeepPrefix;
+ if (!Suffix.empty() && TestFuncs(Suffix))
+ return KeepSuffix;
+ return NoFailure;
+ }
+
+ bool TestFuncs(const std::vector<Function*> &CodegenTest,
+ bool KeepFiles = false);
+ };
+}
bool ReduceMisCodegenFunctions::TestFuncs(const std::vector<Function*> &Funcs,
bool KeepFiles) {
@@ -328,7 +328,7 @@ namespace {
};
}
-void DisambiguateGlobalSymbols(Module *M) {
+static void DisambiguateGlobalSymbols(Module *M) {
// First, try not to cause collisions by minimizing chances of renaming an
// already-external symbol, so take in external globals and functions as-is.
Disambiguator D;
@@ -406,5 +406,3 @@ bool BugDriver::debugCodeGenerator() {
return false;
}
-
-} // End llvm namespace