diff options
author | Stephen Tozer <stephen.tozer@sony.com> | 2024-11-12 16:23:35 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-11-12 16:23:35 +0000 |
commit | fe18ab983d08b9e1726314009d677517d9cd5935 (patch) | |
tree | a84a5354f799ef065c18626c07b8a203e1983ac0 /llvm/lib/Bitcode/Reader/BitcodeReader.cpp | |
parent | 6256f4b807e0637784c0bea948488adfe87cee5b (diff) | |
download | llvm-fe18ab983d08b9e1726314009d677517d9cd5935.zip llvm-fe18ab983d08b9e1726314009d677517d9cd5935.tar.gz llvm-fe18ab983d08b9e1726314009d677517d9cd5935.tar.bz2 |
[DebugInfo] Don't apply is_stmt on MBB branches that preserve lines (#108251)
This patch follows on from the changes made in #105524, by adding an
additional heuristic that prevents us from applying the start-of-MBB
is_stmt flag when we can see that, for all direct branches to the MBB,
the last line stepped on before the branch is the same as the first line
of the MBB. This is mainly to prevent certain pathological cases, such
as macros that expand to multiple basic blocks that all have the same
source location, from giving us repeated steps on the same line. This
approach is not comprehensive, since it relies on analyzeBranch to read
edges, but the default fallback of applying is_stmt may lead only to
useless steps in some cases, rather than skipping useful steps
altogether.
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
0 files changed, 0 insertions, 0 deletions