On Wed Feb 5 08:05:10 2025 +0000, eric pouech wrote:
Adam, agreeing on these remarks. Real life impact would however vary from usage of rescan (between restart keeping current mask vs use a different mask). Out of curiosity, do you have some figures to share here from your current test cases? My thoughts behind the question deals in fact with the data structures used... I wondered if the mask should be part of the cache, or part of an iterator on top of the directory view (meaning that the cached directory view shouldn't be filtered by the mask). That would cleanly separate iterator operation (restart, set a different mask) from flushing the cache entry. But that would have other impacts. So I'm not considering it for this MR. So ok to keep the mask inside the cache entry.
Apologies for the delay in getting the performance numbers back to you, the flooding and resulting network outages that impacted our office slowed things down a bit.
Eugene ran some tests with MSVC building the Unreal Engine's `ShaderCompileWorker` target (which contains around 100 C++ source files), and found that on average the build times increased by about 3 seconds from a baseline of around 150 seconds, representing approximately a 2% overhead when unconditionally flushing the cache regardless of whether the mask has changed. It's not a massive difference for a small build target like this one, but given that we expect it to scale with the number of translation units being compiled, it would likely represent a more significant issue for larger compilation jobs.