]> granicus.if.org Git - llvm/commit
[PGO] Handle cases of failing to split critical edges
authorRong Xu <xur@google.com>
Tue, 28 May 2019 21:45:56 +0000 (21:45 +0000)
committerRong Xu <xur@google.com>
Tue, 28 May 2019 21:45:56 +0000 (21:45 +0000)
commit8f580be75c44e6843d11c3f893579a56132dffd6
treef65587a67b3b3fc41079b6f93888a4aac87be64c
parent03c816bd0e05d7a2638b23917f8a9e4bcdfbfb0f
[PGO] Handle cases of failing to split critical edges

Fix PR41279 where critical edges to EHPad are not split.
The fix is to not instrument those critical edges. We used to be able to know
the size of counters right after MST is computed. With this, we have to
pre-collect the instrument BBs to know the size, and then instrument them.

Differential Revision: https://reviews.llvm.org/D62439

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@361882 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Instrumentation/PGOInstrumentation.cpp
test/Transforms/PGOProfile/PR41279.ll [new file with mode: 0644]