diff options
author | Hiroshi Yamauchi <yamauchi@google.com> | 2019-11-20 13:08:07 -0800 |
---|---|---|
committer | Hiroshi Yamauchi <yamauchi@google.com> | 2019-12-02 13:54:13 -0800 |
commit | 8cdfdfeee6dada5d47eabe9c1d44ceb12235da8f (patch) | |
tree | 888c196b7ae0b7aea6b420baab138ba8dc6cbfd8 /llvm/lib/CodeGen/MachineSizeOpts.cpp | |
parent | 7999cd41d16d841d66c9c91b56bddaf209c54955 (diff) | |
download | bcm5719-llvm-8cdfdfeee6dada5d47eabe9c1d44ceb12235da8f.tar.gz bcm5719-llvm-8cdfdfeee6dada5d47eabe9c1d44ceb12235da8f.zip |
[PGO][PGSO] Add an optional query type parameter to shouldOptimizeForSize.
Summary:
In case of a need to distinguish different query sites for gradual commit or
debugging of PGSO. NFC.
Reviewers: davidxl
Subscribers: hiraditya, zzheng, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D70510
Diffstat (limited to 'llvm/lib/CodeGen/MachineSizeOpts.cpp')
-rw-r--r-- | llvm/lib/CodeGen/MachineSizeOpts.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/MachineSizeOpts.cpp b/llvm/lib/CodeGen/MachineSizeOpts.cpp index 0c2ef3321e0..aff67f9cfd5 100644 --- a/llvm/lib/CodeGen/MachineSizeOpts.cpp +++ b/llvm/lib/CodeGen/MachineSizeOpts.cpp @@ -107,14 +107,16 @@ struct MachineBasicBlockBFIAdapter { bool llvm::shouldOptimizeForSize(const MachineFunction *MF, ProfileSummaryInfo *PSI, - const MachineBlockFrequencyInfo *MBFI) { + const MachineBlockFrequencyInfo *MBFI, + PGSOQueryType QueryType) { return shouldFuncOptimizeForSizeImpl<MachineBasicBlockBFIAdapter>( - MF, PSI, MBFI); + MF, PSI, MBFI, QueryType); } bool llvm::shouldOptimizeForSize(const MachineBasicBlock *MBB, ProfileSummaryInfo *PSI, - const MachineBlockFrequencyInfo *MBFI) { + const MachineBlockFrequencyInfo *MBFI, + PGSOQueryType QueryType) { return shouldOptimizeForSizeImpl<MachineBasicBlockBFIAdapter>( - MBB, PSI, MBFI); + MBB, PSI, MBFI, QueryType); } |