summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2019-09-22 09:28:47 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2019-09-22 09:28:47 +0000
commit1b38002c7dae02ab8b97f3d3b076e3e5f58c136f (patch)
tree95075eb06066009cef78333f3cd8989c3ad647ac
parent38014c553f0d8aa8b5db4fe7b0a2d98c044580f3 (diff)
downloadbcm5719-llvm-1b38002c7dae02ab8b97f3d3b076e3e5f58c136f.tar.gz
bcm5719-llvm-1b38002c7dae02ab8b97f3d3b076e3e5f58c136f.zip
Move classes into anonymous namespaces. NFC.
llvm-svn: 372495
-rw-r--r--clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp4
-rw-r--r--llvm/lib/Target/Hexagon/HexagonInstrInfo.cpp2
-rw-r--r--llvm/lib/Target/PowerPC/PPCISelLowering.cpp2
-rw-r--r--llvm/lib/Target/PowerPC/PPCInstrInfo.cpp2
4 files changed, 7 insertions, 3 deletions
diff --git a/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp b/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp
index 52d21a54a12..a8244995187 100644
--- a/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp
+++ b/clang/lib/StaticAnalyzer/Checkers/MallocChecker.cpp
@@ -662,8 +662,6 @@ private:
void reportLeak(SymbolRef Sym, ExplodedNode *N, CheckerContext &C) const;
};
-} // end anonymous namespace
-
//===----------------------------------------------------------------------===//
// Definition of MallocBugVisitor.
//===----------------------------------------------------------------------===//
@@ -793,6 +791,8 @@ private:
};
};
+} // end anonymous namespace
+
// A map from the freed symbol to the symbol representing the return value of
// the free function.
REGISTER_MAP_WITH_PROGRAMSTATE(FreeReturnValue, SymbolRef, SymbolRef)
diff --git a/llvm/lib/Target/Hexagon/HexagonInstrInfo.cpp b/llvm/lib/Target/Hexagon/HexagonInstrInfo.cpp
index ea43db0f413..32cb97fe760 100644
--- a/llvm/lib/Target/Hexagon/HexagonInstrInfo.cpp
+++ b/llvm/lib/Target/Hexagon/HexagonInstrInfo.cpp
@@ -674,6 +674,7 @@ unsigned HexagonInstrInfo::insertBranch(MachineBasicBlock &MBB,
return 2;
}
+namespace {
class HexagonPipelinerLoopInfo : public TargetInstrInfo::PipelinerLoopInfo {
MachineInstr *Loop, *EndLoop;
MachineFunction *MF;
@@ -748,6 +749,7 @@ public:
void disposed() override { Loop->eraseFromParent(); }
};
+} // namespace
std::unique_ptr<TargetInstrInfo::PipelinerLoopInfo>
HexagonInstrInfo::analyzeLoopForPipelining(MachineBasicBlock *LoopBB) const {
diff --git a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
index ed9aae8f2e7..432d772185a 100644
--- a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
+++ b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
@@ -8187,7 +8187,7 @@ SDValue PPCTargetLowering::LowerBITCAST(SDValue Op, SelectionDAG &DAG) const {
Op0.getOperand(1));
}
-const SDValue *getNormalLoadInput(const SDValue &Op) {
+static const SDValue *getNormalLoadInput(const SDValue &Op) {
const SDValue *InputLoad = &Op;
if (InputLoad->getOpcode() == ISD::BITCAST)
InputLoad = &InputLoad->getOperand(0);
diff --git a/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp b/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp
index c33f0b36867..f217bfbe908 100644
--- a/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp
+++ b/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp
@@ -3930,6 +3930,7 @@ bool PPCInstrInfo::isBDNZ(unsigned Opcode) const {
return (Opcode == (Subtarget.isPPC64() ? PPC::BDNZ8 : PPC::BDNZ));
}
+namespace {
class PPCPipelinerLoopInfo : public TargetInstrInfo::PipelinerLoopInfo {
MachineInstr *Loop, *EndLoop, *LoopCount;
MachineFunction *MF;
@@ -3996,6 +3997,7 @@ public:
LoopCount->eraseFromParent();
}
};
+} // namespace
std::unique_ptr<TargetInstrInfo::PipelinerLoopInfo>
PPCInstrInfo::analyzeLoopForPipelining(MachineBasicBlock *LoopBB) const {
OpenPOWER on IntegriCloud