]> granicus.if.org Git - llvm/commitdiff
[IPO/ConstantMerge] Convert to static function, to facilitate transition to the new PM.
authorDavide Italiano <davide@freebsd.org>
Wed, 4 May 2016 03:21:20 +0000 (03:21 +0000)
committerDavide Italiano <davide@freebsd.org>
Wed, 4 May 2016 03:21:20 +0000 (03:21 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268476 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/IPO/ConstantMerge.cpp

index 80470a706cddefe182348b5c5c8d99e713902d9c..9489c75e6faa7b49f5ed5b5ecf1439dd37cc319e 100644 (file)
@@ -44,11 +44,6 @@ namespace {
     // For this pass, process all of the globals in the module, eliminating
     // duplicate constants.
     bool runOnModule(Module &M) override;
-
-    // Return the alignment of the global, including converting the default
-    // alignment to a concrete value.
-    unsigned getAlignment(GlobalVariable *GV) const;
-
   };
 }
 
@@ -85,7 +80,7 @@ static bool IsBetterCanonical(const GlobalVariable &A,
   return A.hasUnnamedAddr();
 }
 
-unsigned ConstantMerge::getAlignment(GlobalVariable *GV) const {
+static unsigned getAlignment(GlobalVariable *GV) {
   unsigned Align = GV->getAlignment();
   if (Align)
     return Align;