summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2017-08-20 13:03:48 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2017-08-20 13:03:48 +0000
commit49a49fe816122f9bc4cf8f909e0bc24aa84ea4ce (patch)
treef67fcbe4d22d0268902ea501339f083eab383c62 /llvm/lib/CodeGen
parentdf8c2628ac6778024d6b99484bb94fd77e466d0e (diff)
downloadbcm5719-llvm-49a49fe816122f9bc4cf8f909e0bc24aa84ea4ce.tar.gz
bcm5719-llvm-49a49fe816122f9bc4cf8f909e0bc24aa84ea4ce.zip
Move helper classes into anonymous namespaces.
No functionality change intended. llvm-svn: 311288
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/CodeGenPrepare.cpp2
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp2
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp8
3 files changed, 8 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/CodeGenPrepare.cpp b/llvm/lib/CodeGen/CodeGenPrepare.cpp
index 6d0043ba9e0..03ef8985210 100644
--- a/llvm/lib/CodeGen/CodeGenPrepare.cpp
+++ b/llvm/lib/CodeGen/CodeGenPrepare.cpp
@@ -1656,6 +1656,7 @@ static bool despeculateCountZeros(IntrinsicInst *CountZeros,
return true;
}
+namespace {
// This class provides helper functions to expand a memcmp library call into an
// inline expansion.
class MemCmpExpansion {
@@ -1703,6 +1704,7 @@ public:
unsigned NumLoadsPerBlock, const DataLayout &DL);
Value *getMemCmpExpansion(uint64_t Size);
};
+} // namespace
MemCmpExpansion::ResultBlock::ResultBlock()
: BB(nullptr), PhiSrc1(nullptr), PhiSrc2(nullptr) {}
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
index 083167ca62f..fc441b8d857 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
@@ -7015,6 +7015,7 @@ static bool createVirtualRegs(SmallVector<unsigned, 4> &Regs, unsigned NumRegs,
return true;
}
+namespace {
class ExtraFlags {
unsigned Flags = 0;
@@ -7048,6 +7049,7 @@ public:
unsigned get() const { return Flags; }
};
+} // namespace
/// visitInlineAsm - Handle a call to an InlineAsm object.
///
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
index 0ac92b5efa2..4d43a3b41f8 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
@@ -1287,10 +1287,10 @@ static void propagateSwiftErrorVRegs(FunctionLoweringInfo *FuncInfo) {
}
}
-void preassignSwiftErrorRegs(const TargetLowering *TLI,
- FunctionLoweringInfo *FuncInfo,
- BasicBlock::const_iterator Begin,
- BasicBlock::const_iterator End) {
+static void preassignSwiftErrorRegs(const TargetLowering *TLI,
+ FunctionLoweringInfo *FuncInfo,
+ BasicBlock::const_iterator Begin,
+ BasicBlock::const_iterator End) {
if (!TLI->supportSwiftError() || FuncInfo->SwiftErrorVals.empty())
return;
OpenPOWER on IntegriCloud