llvm-project/llvm/lib
Reid Kleckner 9d8f0b3519 [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
2019-10-10 01:06:01 +00:00
..
Analysis [System Model] [TTI] Update cache and prefetch TTI interfaces 2019-10-09 19:51:48 +00:00
AsmParser [X86] Add new calling convention that guarantees tail call optimization 2019-10-07 22:28:58 +00:00
BinaryFormat DebugInfo: Move LLE enum handling to .def to match RLE handling 2019-10-08 21:48:46 +00:00
Bitcode [Bitcode] Update naming of UNOP_NEG to UNOP_FNEG 2019-10-07 20:41:25 +00:00
Bitstream [Bitcode] Move Bitstream to a separate library 2019-07-03 22:40:07 +00:00
CodeGen [codeview] Try to avoid emitting .cv_loc with line zero 2019-10-10 01:06:01 +00:00
DebugInfo llvm-dwarfdump: Support multiple debug_loclists contributions 2019-10-09 21:25:28 +00:00
Demangle Fix uninitialized variable warning. NFCI. 2019-10-02 11:48:45 +00:00
ExecutionEngine Second attempt to add iterator_range::empty() 2019-10-07 18:14:24 +00:00
FuzzMutate [llvm] Migrate llvm::make_unique to std::make_unique 2019-08-15 15:54:37 +00:00
Fuzzer
IR [SVE][IR] Scalable Vector size queries and IR instruction support 2019-10-08 12:53:54 +00:00
IRReader
LTO [ThinLTO/WPD] Ensure devirtualized targets use promoted symbol when necessary 2019-10-02 16:36:59 +00:00
LineEditor [CMake] Delete redundant DEPENDS/LINK_LIBS from LineEditor/XRay 2019-06-22 01:50:21 +00:00
Linker [IRMover] Don't map globals if their types are the same 2019-09-11 18:35:49 +00:00
MC [System Model] [TTI] Update cache and prefetch TTI interfaces 2019-10-09 19:51:48 +00:00
MCA [MCA][LSUnit] Track loads and stores until retirement. 2019-10-08 10:46:01 +00:00
Object Object/minidump: Add support for the MemoryInfoList stream 2019-10-08 14:15:32 +00:00
ObjectYAML [yaml2obj] - Add a Size tag support for SHT_LLVM_ADDRSIG sections. 2019-10-03 15:02:18 +00:00
Option [llvm] Migrate llvm::make_unique to std::make_unique 2019-08-15 15:54:37 +00:00
Passes [NewPM] Port MachineModuleInfo to the new pass manager. 2019-09-30 17:54:50 +00:00
ProfileData [SampleFDO] Add indexing for function profiles so they can be loaded on demand 2019-10-09 21:36:03 +00:00
Remarks [Remarks] Pass StringBlockValue as StringRef. 2019-10-07 17:05:09 +00:00
Support Unify the two CRC implementations 2019-10-09 09:06:30 +00:00
TableGen [tblgen] Add getOperatorAsDef() to Record 2019-10-08 18:41:32 +00:00
Target Conservatively add volatility and atomic checks in a few places 2019-10-09 23:43:33 +00:00
Testing [Testing] Move clangd::Annotations to llvm testing support 2019-04-25 10:08:31 +00:00
TextAPI Revert [TextAPI] Introduce TBDv4 2019-10-08 15:24:37 +00:00
ToolDrivers [llvm-lib] Detect duplicate input files 2019-10-02 06:41:52 +00:00
Transforms [InstCombine] Fix PR43617 2019-10-09 22:03:23 +00:00
WindowsManifest Fight a bit against global initializers. NFC. 2019-08-22 19:43:27 +00:00
XRay [XRay] Silence static analyzer dyn_cast<BufferExtents> null dereference warning. NFCI. 2019-09-22 18:47:00 +00:00
CMakeLists.txt Fix build errors LLVM tests are disabled. 2019-07-11 22:08:35 +00:00
LLVMBuild.txt [Bitcode] Move Bitstream to a separate library 2019-07-03 22:40:07 +00:00