mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 20:51:52 +01:00
Move code into anonymous namespaces.
llvm-svn: 145154
This commit is contained in:
parent
563854a230
commit
d861d825f2
@ -30,7 +30,7 @@ static cl::opt<bool,false>
|
|||||||
ProfileVerifierDisableAssertions("profile-verifier-noassert",
|
ProfileVerifierDisableAssertions("profile-verifier-noassert",
|
||||||
cl::desc("Disable assertions"));
|
cl::desc("Disable assertions"));
|
||||||
|
|
||||||
namespace llvm {
|
namespace {
|
||||||
template<class FType, class BType>
|
template<class FType, class BType>
|
||||||
class ProfileVerifierPassT : public FunctionPass {
|
class ProfileVerifierPassT : public FunctionPass {
|
||||||
|
|
||||||
|
@ -38,8 +38,7 @@ INITIALIZE_PASS_DEPENDENCY(LiveIntervals)
|
|||||||
INITIALIZE_PASS_END(LoopSplitter, "loop-splitting",
|
INITIALIZE_PASS_END(LoopSplitter, "loop-splitting",
|
||||||
"Split virtual regists across loop boundaries.", false, false)
|
"Split virtual regists across loop boundaries.", false, false)
|
||||||
|
|
||||||
namespace llvm {
|
namespace {
|
||||||
|
|
||||||
class StartSlotComparator {
|
class StartSlotComparator {
|
||||||
public:
|
public:
|
||||||
StartSlotComparator(LiveIntervals &lis) : lis(lis) {}
|
StartSlotComparator(LiveIntervals &lis) : lis(lis) {}
|
||||||
@ -50,6 +49,9 @@ namespace llvm {
|
|||||||
private:
|
private:
|
||||||
LiveIntervals &lis;
|
LiveIntervals &lis;
|
||||||
};
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
namespace llvm {
|
||||||
|
|
||||||
class LoopSplit {
|
class LoopSplit {
|
||||||
public:
|
public:
|
||||||
|
@ -72,7 +72,7 @@ ARMInterworking("arm-interworking", cl::Hidden,
|
|||||||
cl::desc("Enable / disable ARM interworking (for debugging only)"),
|
cl::desc("Enable / disable ARM interworking (for debugging only)"),
|
||||||
cl::init(true));
|
cl::init(true));
|
||||||
|
|
||||||
namespace llvm {
|
namespace {
|
||||||
class ARMCCState : public CCState {
|
class ARMCCState : public CCState {
|
||||||
public:
|
public:
|
||||||
ARMCCState(CallingConv::ID CC, bool isVarArg, MachineFunction &MF,
|
ARMCCState(CallingConv::ID CC, bool isVarArg, MachineFunction &MF,
|
||||||
|
@ -29,13 +29,11 @@ using namespace llvm;
|
|||||||
|
|
||||||
STATISTIC(FilledSlots, "Number of delay slots filled");
|
STATISTIC(FilledSlots, "Number of delay slots filled");
|
||||||
|
|
||||||
namespace llvm {
|
static cl::opt<bool> MBDisableDelaySlotFiller(
|
||||||
cl::opt<bool> MBDisableDelaySlotFiller(
|
|
||||||
"disable-mblaze-delay-filler",
|
"disable-mblaze-delay-filler",
|
||||||
cl::init(false),
|
cl::init(false),
|
||||||
cl::desc("Disable the MBlaze delay slot filter."),
|
cl::desc("Disable the MBlaze delay slot filter."),
|
||||||
cl::Hidden);
|
cl::Hidden);
|
||||||
}
|
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
struct Filler : public MachineFunctionPass {
|
struct Filler : public MachineFunctionPass {
|
||||||
|
@ -32,13 +32,11 @@
|
|||||||
|
|
||||||
using namespace llvm;
|
using namespace llvm;
|
||||||
|
|
||||||
namespace llvm {
|
static cl::opt<bool> MBDisableStackAdjust(
|
||||||
cl::opt<bool> MBDisableStackAdjust(
|
"disable-mblaze-stack-adjust",
|
||||||
"disable-mblaze-stack-adjust",
|
cl::init(false),
|
||||||
cl::init(false),
|
cl::desc("Disable MBlaze stack layout adjustment."),
|
||||||
cl::desc("Disable MBlaze stack layout adjustment."),
|
cl::Hidden);
|
||||||
cl::Hidden);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void replaceFrameIndexes(MachineFunction &MF,
|
static void replaceFrameIndexes(MachineFunction &MF,
|
||||||
SmallVector<std::pair<int,int64_t>, 16> &FR) {
|
SmallVector<std::pair<int,int64_t>, 16> &FR) {
|
||||||
|
@ -23,9 +23,11 @@
|
|||||||
#include "llvm/Support/ErrorHandling.h"
|
#include "llvm/Support/ErrorHandling.h"
|
||||||
#include "llvm/Support/raw_ostream.h"
|
#include "llvm/Support/raw_ostream.h"
|
||||||
|
|
||||||
|
using namespace llvm;
|
||||||
|
|
||||||
// NOTE: PTXFPRoundingModePass should be executed just before emission.
|
// NOTE: PTXFPRoundingModePass should be executed just before emission.
|
||||||
|
|
||||||
namespace llvm {
|
namespace {
|
||||||
/// PTXFPRoundingModePass - Pass to assign appropriate FP rounding modes to
|
/// PTXFPRoundingModePass - Pass to assign appropriate FP rounding modes to
|
||||||
/// all FP instructions. Essentially, this pass just looks for all FP
|
/// all FP instructions. Essentially, this pass just looks for all FP
|
||||||
/// instructions that have a rounding mode set to RndDefault, and sets an
|
/// instructions that have a rounding mode set to RndDefault, and sets an
|
||||||
@ -58,7 +60,7 @@ namespace llvm {
|
|||||||
void initializeMap();
|
void initializeMap();
|
||||||
void processInstruction(MachineInstr &MI);
|
void processInstruction(MachineInstr &MI);
|
||||||
}; // class PTXFPRoundingModePass
|
}; // class PTXFPRoundingModePass
|
||||||
} // namespace llvm
|
} // end anonymous namespace
|
||||||
|
|
||||||
using namespace llvm;
|
using namespace llvm;
|
||||||
|
|
||||||
|
@ -22,9 +22,11 @@
|
|||||||
#include "llvm/Support/ErrorHandling.h"
|
#include "llvm/Support/ErrorHandling.h"
|
||||||
#include "llvm/Support/raw_ostream.h"
|
#include "llvm/Support/raw_ostream.h"
|
||||||
|
|
||||||
|
using namespace llvm;
|
||||||
|
|
||||||
// NOTE: PTXMFInfoExtract must after register allocation!
|
// NOTE: PTXMFInfoExtract must after register allocation!
|
||||||
|
|
||||||
namespace llvm {
|
namespace {
|
||||||
/// PTXMFInfoExtract - PTX specific code to extract of PTX machine
|
/// PTXMFInfoExtract - PTX specific code to extract of PTX machine
|
||||||
/// function information for PTXAsmPrinter
|
/// function information for PTXAsmPrinter
|
||||||
///
|
///
|
||||||
@ -42,7 +44,7 @@ namespace llvm {
|
|||||||
return "PTX Machine Function Info Extractor";
|
return "PTX Machine Function Info Extractor";
|
||||||
}
|
}
|
||||||
}; // class PTXMFInfoExtract
|
}; // class PTXMFInfoExtract
|
||||||
} // namespace llvm
|
} // end anonymous namespace
|
||||||
|
|
||||||
using namespace llvm;
|
using namespace llvm;
|
||||||
|
|
||||||
|
@ -58,18 +58,16 @@ STATISTIC(NumLFTR , "Number of loop exit tests replaced");
|
|||||||
STATISTIC(NumElimExt , "Number of IV sign/zero extends eliminated");
|
STATISTIC(NumElimExt , "Number of IV sign/zero extends eliminated");
|
||||||
STATISTIC(NumElimIV , "Number of congruent IVs eliminated");
|
STATISTIC(NumElimIV , "Number of congruent IVs eliminated");
|
||||||
|
|
||||||
namespace llvm {
|
static cl::opt<bool> EnableIVRewrite(
|
||||||
cl::opt<bool> EnableIVRewrite(
|
"enable-iv-rewrite", cl::Hidden,
|
||||||
"enable-iv-rewrite", cl::Hidden,
|
cl::desc("Enable canonical induction variable rewriting"));
|
||||||
cl::desc("Enable canonical induction variable rewriting"));
|
|
||||||
|
|
||||||
// Trip count verification can be enabled by default under NDEBUG if we
|
// Trip count verification can be enabled by default under NDEBUG if we
|
||||||
// implement a strong expression equivalence checker in SCEV. Until then, we
|
// implement a strong expression equivalence checker in SCEV. Until then, we
|
||||||
// use the verify-indvars flag, which may assert in some cases.
|
// use the verify-indvars flag, which may assert in some cases.
|
||||||
cl::opt<bool> VerifyIndvars(
|
static cl::opt<bool> VerifyIndvars(
|
||||||
"verify-indvars", cl::Hidden,
|
"verify-indvars", cl::Hidden,
|
||||||
cl::desc("Verify the ScalarEvolution result after running indvars"));
|
cl::desc("Verify the ScalarEvolution result after running indvars"));
|
||||||
}
|
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
class IndVarSimplify : public LoopPass {
|
class IndVarSimplify : public LoopPass {
|
||||||
|
@ -77,19 +77,17 @@
|
|||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
using namespace llvm;
|
using namespace llvm;
|
||||||
|
|
||||||
namespace llvm {
|
static cl::opt<bool> EnableNested(
|
||||||
cl::opt<bool> EnableNested(
|
|
||||||
"enable-lsr-nested", cl::Hidden, cl::desc("Enable LSR on nested loops"));
|
"enable-lsr-nested", cl::Hidden, cl::desc("Enable LSR on nested loops"));
|
||||||
|
|
||||||
cl::opt<bool> EnableRetry(
|
static cl::opt<bool> EnableRetry(
|
||||||
"enable-lsr-retry", cl::Hidden, cl::desc("Enable LSR retry"));
|
"enable-lsr-retry", cl::Hidden, cl::desc("Enable LSR retry"));
|
||||||
|
|
||||||
// Temporary flag to cleanup congruent phis after LSR phi expansion.
|
// Temporary flag to cleanup congruent phis after LSR phi expansion.
|
||||||
// It's currently disabled until we can determine whether it's truly useful or
|
// It's currently disabled until we can determine whether it's truly useful or
|
||||||
// not. The flag should be removed after the v3.0 release.
|
// not. The flag should be removed after the v3.0 release.
|
||||||
cl::opt<bool> EnablePhiElim(
|
static cl::opt<bool> EnablePhiElim(
|
||||||
"enable-lsr-phielim", cl::Hidden, cl::desc("Enable LSR phi elimination"));
|
"enable-lsr-phielim", cl::Hidden, cl::desc("Enable LSR phi elimination"));
|
||||||
}
|
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user