diff options
| author | Daniel Bertalan <dani@danielbertalan.dev> | 2022-06-13 15:49:27 -0400 |
|---|---|---|
| committer | Nico Weber <thakis@chromium.org> | 2022-06-13 15:49:27 -0400 |
| commit | 5f627cc2251c17ed9362abd556b425e7d0a53437 (patch) | |
| tree | a877f68c18640237568822d364a7c26d56918efa /llvm/lib/Bitcode/Writer/BitcodeWriterPass.cpp | |
| parent | c39b76ae2ecb05c567dcf4f3d23a60fba1bc81d6 (diff) | |
| download | llvm-5f627cc2251c17ed9362abd556b425e7d0a53437.zip llvm-5f627cc2251c17ed9362abd556b425e7d0a53437.tar.gz llvm-5f627cc2251c17ed9362abd556b425e7d0a53437.tar.bz2 | |
[lld-macho] Fix symbol name returned from InputSection::getLocation
This commit fixes the issue that getLocation always printed the name of
the first symbol in the section.
For clarity, upper_bound is used instead of a linear search for finding
the closest symbol name. Note that this change does not affect
performance: this function is only called when printing errors and
`symbols` typically contains a single symbol because of
.subsections_via_symbols.
Differential Revision: https://reviews.llvm.org/D127670
Diffstat (limited to 'llvm/lib/Bitcode/Writer/BitcodeWriterPass.cpp')
0 files changed, 0 insertions, 0 deletions
