Bug ID: 45310
Summary: Save file fails while debugging is active on Windows
OS: Windows NT
Component: All Bugs
CC: jdevliegh...@apple.com, email@example.com
On Windows, when LLDB hits a breakpoint in a large source file, the file is
locked and users can no longer edit the file. This causes trouble for users of
IDEs such as Android Studio, where users expect to be able to edit and save
files while they are debugging.
LLDB MemoryBuffer uses mmap for files larger than (4 * 4096) bytes. On Windows,
as long as the mapping is active, files cannot be overwritten.
1. SourceManager keeps m_last_file_sp to remember the most recently used file.
This keeps the mmapped region alive while a breakpoint is hit.
2. SourceFileCache keeps m_file_cache to remember all previously opened files.
This keeps all mmapped regions alive as long as LLDB is running. (see next
3. SourceFileCache.AddSourceFile is broken: It always adds bogus entry to the
cache, and therefore, cache insertions always conflict and cache lookups never
// Android Studio reported bug: https://issuetracker.google.com/143436652
You are receiving this mail because:
You are on the CC list for the bug.
llvm-bugs mailing list