[all-commits] [llvm/llvm-project] 3cbf44: [SampleFDO] Do not scale the magic number NOMORE_I...
wmi-11 via All-commits
all-commits at lists.llvm.org
Mon Mar 29 09:35:07 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 3cbf44190b593210bdc78f45e5f747cb234ce5d9
https://github.com/llvm/llvm-project/commit/3cbf44190b593210bdc78f45e5f747cb234ce5d9
Author: Wei Mi <wmi at google.com>
Date: 2021-03-29 (Mon, 29 Mar 2021)
Changed paths:
M llvm/include/llvm/IR/Metadata.h
M llvm/include/llvm/ProfileData/InstrProf.h
M llvm/lib/IR/Instructions.cpp
A llvm/test/Transforms/SampleProfile/norepeated-icp-4.ll
Log Message:
-----------
[SampleFDO] Do not scale the magic number NOMORE_ICP_MAGICNUM in value profile
during profile update.
When we inline a function and update the profile, the value profiles of the
indirect call in the inliner and inlinee will be scaled. In
https://reviews.llvm.org/D96806 and https://reviews.llvm.org/D97350, we start
using the magic number NOMORE_ICP_MAGICNUM (-1) to mark targets which have
been promoted. The magic number shouldn't be scaled during the profile update.
Although the problem has been suppressed by https://reviews.llvm.org/D98187
for SampleFDO, which stops profile update for inlining in sampleFDO, the patch
is still wanted since it will be more consistent to handle the magic number
properly in profile update.
Differential Revision: https://reviews.llvm.org/D99394
More information about the All-commits
mailing list