]> granicus.if.org Git - clang/commitdiff
Make helper functions static. NFC.
authorBenjamin Kramer <benny.kra@googlemail.com>
Fri, 1 May 2015 13:59:53 +0000 (13:59 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Fri, 1 May 2015 13:59:53 +0000 (13:59 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@236315 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/CGOpenMPRuntime.cpp
lib/CodeGen/CGStmtOpenMP.cpp
lib/Sema/SemaStmt.cpp

index 1dbf0e55687745774720056259d08a272fe53536..b89f0c0676cd0f9eeb62378d1fec73afaca027a7 100644 (file)
@@ -1740,11 +1740,10 @@ emitProxyTaskFunction(CodeGenModule &CGM, SourceLocation Loc,
   return TaskEntry;
 }
 
-llvm::Value *emitDestructorsFunction(CodeGenModule &CGM, SourceLocation Loc,
-                                     QualType KmpInt32Ty,
-                                     QualType KmpTaskTPtrQTy,
-                                     QualType KmpTaskQTy,
-                                     RecordDecl *KmpTaskQTyRD) {
+static llvm::Value *
+emitDestructorsFunction(CodeGenModule &CGM, SourceLocation Loc,
+                        QualType KmpInt32Ty, QualType KmpTaskTPtrQTy,
+                        QualType KmpTaskQTy, RecordDecl *KmpTaskQTyRD) {
   auto &C = CGM.getContext();
   FunctionArgList Args;
   ImplicitParamDecl GtidArg(C, /*DC=*/nullptr, Loc, /*Id=*/nullptr, KmpInt32Ty);
index 1489685459a9235665bf91eae684f1ce28763576..2c2d7032e3dae1389fc716c5dada3bfe09694031 100644 (file)
@@ -1529,10 +1529,11 @@ static void EmitOMPAtomicWriteExpr(CodeGenFunction &CGF, bool IsSeqCst,
     CGF.CGM.getOpenMPRuntime().emitFlush(CGF, llvm::None, Loc);
 }
 
-std::pair<bool, RValue> emitOMPAtomicRMW(CodeGenFunction &CGF, LValue X,
-                                         RValue Update, BinaryOperatorKind BO,
-                                         llvm::AtomicOrdering AO,
-                                         bool IsXLHSInRHSPart) {
+static std::pair<bool, RValue> emitOMPAtomicRMW(CodeGenFunction &CGF, LValue X,
+                                                RValue Update,
+                                                BinaryOperatorKind BO,
+                                                llvm::AtomicOrdering AO,
+                                                bool IsXLHSInRHSPart) {
   auto &Context = CGF.CGM.getContext();
   // Allow atomicrmw only if 'x' and 'update' are integer values, lvalue for 'x'
   // expression is simple and atomic is allowed for the given type for the
index ed5da43f8a964bb81944055be2ebae9c9d17162f..0c0c60f1e4e2c4681e640ec60de09e6bd5999614 100644 (file)
@@ -3410,6 +3410,7 @@ Sema::ActOnObjCAutoreleasePoolStmt(SourceLocation AtLoc, Stmt *Body) {
   return new (Context) ObjCAutoreleasePoolStmt(AtLoc, Body);
 }
 
+namespace {
 class CatchHandlerType {
   QualType QT;
   unsigned IsPointer : 1;
@@ -3451,6 +3452,7 @@ public:
     return LHS.QT == RHS.QT;
   }
 };
+} // namespace
 
 namespace llvm {
 template <> struct DenseMapInfo<CatchHandlerType> {