[PATCH] D19185: Remove interface to get/set MaxFunctionCount

Easwaran Raman via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 15 16:55:11 PDT 2016


eraman created this revision.
eraman added a reviewer: vsk.
eraman added subscribers: llvm-commits, davidxl.

This completes MaxFunctionCount deprecation

http://reviews.llvm.org/D19185

Files:
  include/llvm/IR/Module.h
  lib/IR/Module.cpp

Index: lib/IR/Module.cpp
===================================================================
--- lib/IR/Module.cpp
+++ lib/IR/Module.cpp
@@ -497,18 +497,6 @@
   addModuleFlag(ModFlagBehavior::Error, "PIC Level", PL);
 }
 
-void Module::setMaximumFunctionCount(uint64_t Count) {
-  addModuleFlag(ModFlagBehavior::Error, "MaxFunctionCount", Count);
-}
-
-Optional<uint64_t> Module::getMaximumFunctionCount() {
-  auto *Val =
-      cast_or_null<ConstantAsMetadata>(getModuleFlag("MaxFunctionCount"));
-  if (!Val)
-    return None;
-  return cast<ConstantInt>(Val->getValue())->getZExtValue();
-}
-
 void Module::setProfileSummary(Metadata *M) {
   addModuleFlag(ModFlagBehavior::Error, "ProfileSummary", M);
 }
Index: include/llvm/IR/Module.h
===================================================================
--- include/llvm/IR/Module.h
+++ include/llvm/IR/Module.h
@@ -734,12 +734,6 @@
   /// @name Utility functions for querying and setting PGO summary
   /// @{
 
-  /// \brief Set maximum function count in PGO mode
-  void setMaximumFunctionCount(uint64_t);
-
-  /// \brief Returns maximum function count in PGO mode
-  Optional<uint64_t> getMaximumFunctionCount();
-
   /// \brief Attach profile summary metadata to this module.
   void setProfileSummary(Metadata *M);
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D19185.53970.patch
Type: text/x-patch
Size: 1279 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160415/fc075a32/attachment.bin>


More information about the llvm-commits mailing list