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 getMaximumFunctionCount(); - /// \brief Attach profile summary metadata to this module. void setProfileSummary(Metadata *M); 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 Module::getMaximumFunctionCount() { - auto *Val = - cast_or_null(getModuleFlag("MaxFunctionCount")); - if (!Val) - return None; - return cast(Val->getValue())->getZExtValue(); -} - void Module::setProfileSummary(Metadata *M) { addModuleFlag(ModFlagBehavior::Error, "ProfileSummary", M); }