Skip to content

Commit eaab9df

Browse files
committed
Update pseudo probe search range && range checks
1 parent 2978e21 commit eaab9df

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

llvm/tools/llvm-profgen/ProfiledBinary.cpp

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1151,14 +1151,10 @@ void ProfiledBinary::loadSymbolsFromPseudoProbe() {
11511151
auto Func = Range.Func;
11521152
if (!Range.IsFuncEntry || Func->NameStatus != DwarfNameStatus::Mismatch)
11531153
continue;
1154-
#ifndef NDEBUG
1155-
if (PseudoProbeNames.count(Func))
1156-
continue;
1157-
#endif
1158-
const auto &Probe = Address2ProbesMap.find(Addr).begin();
1159-
if (Probe != Address2ProbesMap.end()) {
1154+
const auto &Probe = Address2ProbesMap.find(Addr, Range.EndAddress);
1155+
if (Probe.begin() != Probe.end()) {
11601156
const MCDecodedPseudoProbeInlineTree *InlineTreeNode =
1161-
Probe->get().getInlineTreeNode();
1157+
Probe.begin()->get().getInlineTreeNode();
11621158
while (!InlineTreeNode->isTopLevelFunc())
11631159
InlineTreeNode = static_cast<MCDecodedPseudoProbeInlineTree *>(
11641160
InlineTreeNode->Parent);

0 commit comments

Comments
 (0)