mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-05-18 22:38:56 +00:00
Fix a bunch of namespace polution.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101376 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
098406b42c
commit
b35798347e
@ -29,9 +29,9 @@ using namespace llvm;
|
|||||||
|
|
||||||
// Always verify loopinfo if expensive checking is enabled.
|
// Always verify loopinfo if expensive checking is enabled.
|
||||||
#ifdef XDEBUG
|
#ifdef XDEBUG
|
||||||
bool VerifyLoopInfo = true;
|
static bool VerifyLoopInfo = true;
|
||||||
#else
|
#else
|
||||||
bool VerifyLoopInfo = false;
|
static bool VerifyLoopInfo = false;
|
||||||
#endif
|
#endif
|
||||||
static cl::opt<bool,true>
|
static cl::opt<bool,true>
|
||||||
VerifyLoopInfoX("verify-loop-info", cl::location(VerifyLoopInfo),
|
VerifyLoopInfoX("verify-loop-info", cl::location(VerifyLoopInfo),
|
||||||
|
@ -642,6 +642,8 @@ static const Loop *GetRelevantLoop(const SCEV *S, LoopInfo &LI,
|
|||||||
llvm_unreachable("Unexpected SCEV type!");
|
llvm_unreachable("Unexpected SCEV type!");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace {
|
||||||
|
|
||||||
/// LoopCompare - Compare loops by PickMostRelevantLoop.
|
/// LoopCompare - Compare loops by PickMostRelevantLoop.
|
||||||
class LoopCompare {
|
class LoopCompare {
|
||||||
DominatorTree &DT;
|
DominatorTree &DT;
|
||||||
@ -668,6 +670,8 @@ public:
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
Value *SCEVExpander::visitAddExpr(const SCEVAddExpr *S) {
|
Value *SCEVExpander::visitAddExpr(const SCEVAddExpr *S) {
|
||||||
const Type *Ty = SE.getEffectiveSCEVType(S->getType());
|
const Type *Ty = SE.getEffectiveSCEVType(S->getType());
|
||||||
|
|
||||||
|
@ -1331,7 +1331,7 @@ DbgScope *DwarfDebug::getOrCreateAbstractScope(MDNode *N) {
|
|||||||
|
|
||||||
/// isSubprogramContext - Return true if Context is either a subprogram
|
/// isSubprogramContext - Return true if Context is either a subprogram
|
||||||
/// or another context nested inside a subprogram.
|
/// or another context nested inside a subprogram.
|
||||||
bool isSubprogramContext(MDNode *Context) {
|
static bool isSubprogramContext(MDNode *Context) {
|
||||||
if (!Context)
|
if (!Context)
|
||||||
return false;
|
return false;
|
||||||
DIDescriptor D(Context);
|
DIDescriptor D(Context);
|
||||||
|
@ -351,7 +351,7 @@ void MachineVerifier::visitMachineFunctionBefore() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Does iterator point to a and b as the first two elements?
|
// Does iterator point to a and b as the first two elements?
|
||||||
bool matchPair(MachineBasicBlock::const_succ_iterator i,
|
static bool matchPair(MachineBasicBlock::const_succ_iterator i,
|
||||||
const MachineBasicBlock *a, const MachineBasicBlock *b) {
|
const MachineBasicBlock *a, const MachineBasicBlock *b) {
|
||||||
if (*i == a)
|
if (*i == a)
|
||||||
return *++i == b;
|
return *++i == b;
|
||||||
|
@ -1881,6 +1881,7 @@ static unsigned IsPredicateKnownToFail(const unsigned char *Table,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace {
|
||||||
|
|
||||||
struct MatchScope {
|
struct MatchScope {
|
||||||
/// FailIndex - If this match fails, this is the index to continue with.
|
/// FailIndex - If this match fails, this is the index to continue with.
|
||||||
@ -1902,6 +1903,8 @@ struct MatchScope {
|
|||||||
bool HasChainNodesMatched, HasFlagResultNodesMatched;
|
bool HasChainNodesMatched, HasFlagResultNodesMatched;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
SDNode *SelectionDAGISel::
|
SDNode *SelectionDAGISel::
|
||||||
SelectCodeCommon(SDNode *NodeToMatch, const unsigned char *MatcherTable,
|
SelectCodeCommon(SDNode *NodeToMatch, const unsigned char *MatcherTable,
|
||||||
unsigned TableSize) {
|
unsigned TableSize) {
|
||||||
|
@ -51,12 +51,19 @@ DebugBufferSize("debug-buffer-size",
|
|||||||
cl::init(0));
|
cl::init(0));
|
||||||
|
|
||||||
static std::string CurrentDebugType;
|
static std::string CurrentDebugType;
|
||||||
static struct DebugOnlyOpt {
|
|
||||||
|
namespace {
|
||||||
|
|
||||||
|
struct DebugOnlyOpt {
|
||||||
void operator=(const std::string &Val) const {
|
void operator=(const std::string &Val) const {
|
||||||
DebugFlag |= !Val.empty();
|
DebugFlag |= !Val.empty();
|
||||||
CurrentDebugType = Val;
|
CurrentDebugType = Val;
|
||||||
}
|
}
|
||||||
} DebugOnlyOptLoc;
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
static DebugOnlyOpt DebugOnlyOptLoc;
|
||||||
|
|
||||||
static cl::opt<DebugOnlyOpt, true, cl::parser<std::string> >
|
static cl::opt<DebugOnlyOpt, true, cl::parser<std::string> >
|
||||||
DebugOnly("debug-only", cl::desc("Enable a specific type of debug output"),
|
DebugOnly("debug-only", cl::desc("Enable a specific type of debug output"),
|
||||||
|
@ -190,6 +190,8 @@ void TimeRecord::print(const TimeRecord &Total, raw_ostream &OS) const {
|
|||||||
// NamedRegionTimer Implementation
|
// NamedRegionTimer Implementation
|
||||||
//===----------------------------------------------------------------------===//
|
//===----------------------------------------------------------------------===//
|
||||||
|
|
||||||
|
namespace {
|
||||||
|
|
||||||
typedef StringMap<Timer> Name2TimerMap;
|
typedef StringMap<Timer> Name2TimerMap;
|
||||||
|
|
||||||
class Name2PairMap {
|
class Name2PairMap {
|
||||||
@ -216,6 +218,8 @@ public:
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
static ManagedStatic<Name2TimerMap> NamedTimers;
|
static ManagedStatic<Name2TimerMap> NamedTimers;
|
||||||
static ManagedStatic<Name2PairMap> NamedGroupedTimers;
|
static ManagedStatic<Name2PairMap> NamedGroupedTimers;
|
||||||
|
|
||||||
|
@ -24,12 +24,18 @@
|
|||||||
// Collection of symbol name/value pairs to be searched prior to any libraries.
|
// Collection of symbol name/value pairs to be searched prior to any libraries.
|
||||||
static std::map<std::string, void*> *ExplicitSymbols = 0;
|
static std::map<std::string, void*> *ExplicitSymbols = 0;
|
||||||
|
|
||||||
static struct ExplicitSymbolsDeleter {
|
namespace {
|
||||||
|
|
||||||
|
struct ExplicitSymbolsDeleter {
|
||||||
~ExplicitSymbolsDeleter() {
|
~ExplicitSymbolsDeleter() {
|
||||||
if (ExplicitSymbols)
|
if (ExplicitSymbols)
|
||||||
delete ExplicitSymbols;
|
delete ExplicitSymbols;
|
||||||
}
|
}
|
||||||
} Dummy;
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
static ExplicitSymbolsDeleter Dummy;
|
||||||
|
|
||||||
void llvm::sys::DynamicLibrary::AddSymbol(const char* symbolName,
|
void llvm::sys::DynamicLibrary::AddSymbol(const char* symbolName,
|
||||||
void *symbolValue) {
|
void *symbolValue) {
|
||||||
|
@ -40,7 +40,7 @@
|
|||||||
#include "llvm/Support/CommandLine.h"
|
#include "llvm/Support/CommandLine.h"
|
||||||
using namespace llvm;
|
using namespace llvm;
|
||||||
|
|
||||||
cl::opt<bool>
|
static cl::opt<bool>
|
||||||
ReuseFrameIndexVals("arm-reuse-frame-index-vals", cl::Hidden, cl::init(true),
|
ReuseFrameIndexVals("arm-reuse-frame-index-vals", cl::Hidden, cl::init(true),
|
||||||
cl::desc("Reuse repeated frame index values"));
|
cl::desc("Reuse repeated frame index values"));
|
||||||
|
|
||||||
|
@ -56,11 +56,11 @@ using namespace llvm;
|
|||||||
#define ALIGN_STACK 0
|
#define ALIGN_STACK 0
|
||||||
|
|
||||||
// FIXME (64-bit): Eventually enable by default.
|
// FIXME (64-bit): Eventually enable by default.
|
||||||
cl::opt<bool> EnablePPC32RS("enable-ppc32-regscavenger",
|
static cl::opt<bool> EnablePPC32RS("enable-ppc32-regscavenger",
|
||||||
cl::init(false),
|
cl::init(false),
|
||||||
cl::desc("Enable PPC32 register scavenger"),
|
cl::desc("Enable PPC32 register scavenger"),
|
||||||
cl::Hidden);
|
cl::Hidden);
|
||||||
cl::opt<bool> EnablePPC64RS("enable-ppc64-regscavenger",
|
static cl::opt<bool> EnablePPC64RS("enable-ppc64-regscavenger",
|
||||||
cl::init(false),
|
cl::init(false),
|
||||||
cl::desc("Enable PPC64 register scavenger"),
|
cl::desc("Enable PPC64 register scavenger"),
|
||||||
cl::Hidden);
|
cl::Hidden);
|
||||||
|
@ -1217,7 +1217,7 @@ static Value *GetMemInstValueForLoad(MemIntrinsic *SrcInst, unsigned Offset,
|
|||||||
return ConstantFoldLoadFromConstPtr(Src, &TD);
|
return ConstantFoldLoadFromConstPtr(Src, &TD);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
namespace {
|
||||||
|
|
||||||
struct AvailableValueInBlock {
|
struct AvailableValueInBlock {
|
||||||
/// BB - The basic block in question.
|
/// BB - The basic block in question.
|
||||||
@ -1291,6 +1291,8 @@ struct AvailableValueInBlock {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
/// ConstructSSAForLoadSet - Given a set of loads specified by ValuesPerBlock,
|
/// ConstructSSAForLoadSet - Given a set of loads specified by ValuesPerBlock,
|
||||||
/// construct SSA form, allowing us to eliminate LI. This returns the value
|
/// construct SSA form, allowing us to eliminate LI. This returns the value
|
||||||
/// that should be used at LI's definition site.
|
/// that should be used at LI's definition site.
|
||||||
|
@ -30,9 +30,9 @@ using namespace llvm;
|
|||||||
|
|
||||||
// Always verify dominfo if expensive checking is enabled.
|
// Always verify dominfo if expensive checking is enabled.
|
||||||
#ifdef XDEBUG
|
#ifdef XDEBUG
|
||||||
bool VerifyDomInfo = true;
|
static bool VerifyDomInfo = true;
|
||||||
#else
|
#else
|
||||||
bool VerifyDomInfo = false;
|
static bool VerifyDomInfo = false;
|
||||||
#endif
|
#endif
|
||||||
static cl::opt<bool,true>
|
static cl::opt<bool,true>
|
||||||
VerifyDomInfoX("verify-dom-info", cl::location(VerifyDomInfo),
|
VerifyDomInfoX("verify-dom-info", cl::location(VerifyDomInfo),
|
||||||
|
@ -13,6 +13,7 @@
|
|||||||
|
|
||||||
#include "LLVMContextImpl.h"
|
#include "LLVMContextImpl.h"
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
using namespace llvm;
|
||||||
|
|
||||||
LLVMContextImpl::LLVMContextImpl(LLVMContext &C)
|
LLVMContextImpl::LLVMContextImpl(LLVMContext &C)
|
||||||
: TheTrueVal(0), TheFalseVal(0),
|
: TheTrueVal(0), TheFalseVal(0),
|
||||||
|
@ -14,7 +14,8 @@
|
|||||||
|
|
||||||
#include "llvm/Value.h"
|
#include "llvm/Value.h"
|
||||||
#include "llvm/ADT/SmallPtrSet.h"
|
#include "llvm/ADT/SmallPtrSet.h"
|
||||||
using namespace llvm;
|
|
||||||
|
namespace llvm {
|
||||||
|
|
||||||
template <class T>
|
template <class T>
|
||||||
struct PrinterTrait {
|
struct PrinterTrait {
|
||||||
@ -87,3 +88,5 @@ private:
|
|||||||
const T* Cache;
|
const T* Cache;
|
||||||
const char* Name;
|
const char* Name;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
@ -161,7 +161,7 @@ void DisassemblerTables::emitOneID(raw_ostream &o,
|
|||||||
/// @param i - The indentation level for that output stream.
|
/// @param i - The indentation level for that output stream.
|
||||||
static void emitEmptyTable(raw_ostream &o, uint32_t &i)
|
static void emitEmptyTable(raw_ostream &o, uint32_t &i)
|
||||||
{
|
{
|
||||||
o.indent(i * 2) << "InstrUID modRMEmptyTable[1] = { 0 };" << "\n";
|
o.indent(i * 2) << "static InstrUID modRMEmptyTable[1] = { 0 };" << "\n";
|
||||||
o << "\n";
|
o << "\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -275,7 +275,7 @@ void DisassemblerTables::emitModRMDecision(raw_ostream &o1,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
o1.indent(i1) << "InstrUID modRMTable" << thisTableNumber;
|
o1.indent(i1) << "static InstrUID modRMTable" << thisTableNumber;
|
||||||
|
|
||||||
switch (dt) {
|
switch (dt) {
|
||||||
default:
|
default:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user