summaryrefslogtreecommitdiffstats
path: root/clang/unittests/Tooling/SourceCodeTest.cpp
diff options
context:
space:
mode:
authorReid Kleckner <rnk@google.com>2019-10-10 01:06:01 +0000
committerReid Kleckner <rnk@google.com>2019-10-10 01:06:01 +0000
commit9d8f0b3519c4e9e4e2a3d3b19ea0caf9ef3f85ce (patch)
treef671bdfb4eed447c69b00403a42b568d45ced981 /clang/unittests/Tooling/SourceCodeTest.cpp
parentf6777964bde28c349d3e289ea37ecf5f5eeedbc4 (diff)
downloadbcm5719-llvm-9d8f0b3519c4e9e4e2a3d3b19ea0caf9ef3f85ce.tar.gz
bcm5719-llvm-9d8f0b3519c4e9e4e2a3d3b19ea0caf9ef3f85ce.zip
[codeview] Try to avoid emitting .cv_loc with line zero
Summary: Visual Studio doesn't like it while stepping. It kicks you out of the source view of the file being stepped through and tries to fall back to the disassembly view. Fixes PR43530 The fix is incomplete, because it's possible to have a basic block with no source locations at all. In this case, we don't emit a .cv_loc, but that will result in wrong stepping behavior in the debugger if the layout predecessor of the location-less BB has an unrelated source location. We could try harder to find a valid location that dominates or post-dominates the current BB, but in general it's a dataflow problem, and one still might not exist. I left a FIXME about this. As an alternative, we might want to consider having the middle-end check if its emitting codeview and get it to stop using line zero. Reviewers: akhuang Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D68747 llvm-svn: 374267
Diffstat (limited to 'clang/unittests/Tooling/SourceCodeTest.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud