aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Utility/Reproducer.cpp
diff options
context:
space:
mode:
authorJonas Devlieghere <jonas@devlieghere.com>2020-03-31 11:35:55 -0700
committerJonas Devlieghere <jonas@devlieghere.com>2020-03-31 12:47:12 -0700
commit015c6cd47557272bb8b92fbf9f5bd2bcb8fa8989 (patch)
treebf50480b52e0317e876832e774bbb0cb9b714ce4 /lldb/source/Utility/Reproducer.cpp
parent11ccad6e879573f75dc8b231351ee23a17e0900f (diff)
downloadllvm-015c6cd47557272bb8b92fbf9f5bd2bcb8fa8989.tar.gz
llvm-015c6cd47557272bb8b92fbf9f5bd2bcb8fa8989.tar.bz2
llvm-015c6cd47557272bb8b92fbf9f5bd2bcb8fa8989.zip
Re-land "[lldb/Reproducers] Always collect the whole dSYM in the reproducer"
The FileCollector in LLDB collects every files that's used during a debug session when capture is enabled. This ensures that the reproducer only contains the files necessary to reproduce. This approach is not a good fit for the dSYM bundle, which is a directory on disk, but should be treated as a single unit. On macOS LLDB have automatically find the matching dSYM for a binary by its UUID. Having a incomplete dSYM in a reproducer can break debugging even when reproducers are disabled. This patch adds a was to specify a directory of interest to the reproducers. It is called from SymbolVendorMacOSX with the path of the dSYMs used by LLDB. Differential revision: https://reviews.llvm.org/D76672
Diffstat (limited to 'lldb/source/Utility/Reproducer.cpp')
-rw-r--r--lldb/source/Utility/Reproducer.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/lldb/source/Utility/Reproducer.cpp b/lldb/source/Utility/Reproducer.cpp
index 8daa3216f7b1..bbf399e599bf 100644
--- a/lldb/source/Utility/Reproducer.cpp
+++ b/lldb/source/Utility/Reproducer.cpp
@@ -321,6 +321,11 @@ void WorkingDirectoryProvider::Keep() {
os << m_cwd << "\n";
}
+void FileProvider::recordInterestingDirectory(const llvm::Twine &dir) {
+ if (m_collector)
+ m_collector->addDirectory(dir);
+}
+
void ProviderBase::anchor() {}
char CommandProvider::ID = 0;
char FileProvider::ID = 0;