Disable LLDB index cache for .o files with no UUID.
authorGreg Clayton <gclayton@fb.com>
Fri, 4 Mar 2022 00:53:04 +0000 (16:53 -0800)
committerGreg Clayton <gclayton@fb.com>
Tue, 5 Apr 2022 22:14:36 +0000 (15:14 -0700)
commitb6087ba769c612c031b84e6673c438fe44a46c6a
tree76df7f08e2773c2c3f08fc55506b0ef3a6e4a079
parent30922d62f420731d0a7808c015e69fe6f0ce2e4d
Disable LLDB index cache for .o files with no UUID.

After enabling the LLDB index cache in production we discovered that some distributed build systems play with the modification times of any .o files that were downloaded from the build cache. This was causing the LLDB index cache to read the wrong cache file for files that didn't have a UUID as all of the modfication times were set to the same value by the build system. When new .o files were downloaded, the only unique identifier was the mod time which were all the same, and we would load an older cache for the updated .o file. So disabling caching of files that have no UUIDs for now until we can create a more solid solution.

Differential Revision: https://reviews.llvm.org/D120948
lldb/include/lldb/Core/DataFileCache.h
lldb/source/Core/DataFileCache.cpp
lldb/test/API/functionalities/module_cache/bsd/TestModuleCacheBSD.py
lldb/unittests/SymbolFile/DWARF/DWARFIndexCachingTest.cpp