[llvm] 8fb4a4f - [SampleFDO] Silence -Wnon-virtual-dtor warning
Benjamin Kramer via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 10 14:38:18 PST 2021
Author: Benjamin Kramer
Date: 2021-02-10T23:37:15+01:00
New Revision: 8fb4a4f7bba0fd1af7e2ae0be96082de0526d8d0
URL: https://github.com/llvm/llvm-project/commit/8fb4a4f7bba0fd1af7e2ae0be96082de0526d8d0
DIFF: https://github.com/llvm/llvm-project/commit/8fb4a4f7bba0fd1af7e2ae0be96082de0526d8d0.diff
LOG: [SampleFDO] Silence -Wnon-virtual-dtor warning
There's no polymorphic deletion happening here.
Added:
Modified:
llvm/lib/Transforms/IPO/SampleProfile.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/IPO/SampleProfile.cpp b/llvm/lib/Transforms/IPO/SampleProfile.cpp
index 22ef3e5499af..9d55d9c0fdd7 100644
--- a/llvm/lib/Transforms/IPO/SampleProfile.cpp
+++ b/llvm/lib/Transforms/IPO/SampleProfile.cpp
@@ -395,6 +395,8 @@ class SampleProfileLoaderBaseImpl {
protected:
friend class SampleCoverageTracker;
+ ~SampleProfileLoaderBaseImpl() = default;
+
unsigned getFunctionLoc(Function &F);
virtual ErrorOr<uint64_t> getInstWeight(const Instruction &Inst);
ErrorOr<uint64_t> getInstWeightImpl(const Instruction &Inst);
@@ -483,7 +485,7 @@ class SampleProfileLoaderBaseImpl {
/// This pass reads profile data from the file specified by
/// -sample-profile-file and annotates every affected function with the
/// profile information found in that file.
-class SampleProfileLoader : public SampleProfileLoaderBaseImpl {
+class SampleProfileLoader final : public SampleProfileLoaderBaseImpl {
public:
SampleProfileLoader(
StringRef Name, StringRef RemapName, ThinOrFullLTOPhase LTOPhase,
More information about the llvm-commits
mailing list