[PATCH] D156742: [BOLT][DWARF] Fix handling inlined subroutine with no output pc.
Alexander Yermolovich via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 31 15:52:03 PDT 2023
ayermolo marked 2 inline comments as done.
ayermolo added inline comments.
================
Comment at: bolt/lib/Rewrite/DWARFRewriter.cpp:868
consumeError(RangesOrError.takeError());
+ } else if (OutputRanges.empty()) {
+ if (RangesOrError.get().front().LowPC)
----------------
maksfb wrote:
> maksfb wrote:
> > The condition is always `true` here.
> Remove unnecessary check.
Removed, but it proved useful. Added extra test that would trigger it.
================
Comment at: bolt/lib/Rewrite/DWARFRewriter.cpp:872
+ "DW_AT_low_pc to address in output binary\n";
+ OutputRanges.push_back({0, RangesOrError.get().front().HighPC});
}
----------------
maksfb wrote:
> Do we expect such range to be ignored by DWARF consumers? Why not push `{0, 0}` or `{0, 1}` then?
I want to preserve as much of original as possible.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D156742/new/
https://reviews.llvm.org/D156742
More information about the llvm-commits
mailing list