diff options
author | Jan Svoboda <jan_svoboda@apple.com> | 2022-10-11 16:02:10 -0700 |
---|---|---|
committer | Jan Svoboda <jan_svoboda@apple.com> | 2022-10-12 18:40:34 -0700 |
commit | 98672596626862e4b21319da7c01737bf7e20ae4 (patch) | |
tree | c4bf34b92d92983b44ce97bb43c16ef2c93b2b50 /llvm/lib/CodeGen/ModuloSchedule.cpp | |
parent | 4f158995b9cddae392bfb5989af8c83101ae0789 (diff) | |
download | llvm-98672596626862e4b21319da7c01737bf7e20ae4.zip llvm-98672596626862e4b21319da7c01737bf7e20ae4.tar.gz llvm-98672596626862e4b21319da7c01737bf7e20ae4.tar.bz2 |
[clang][deps] Don't share in-memory VFS across scans
The dependency scanning worker may create an in-memory VFS and inject that into its `FileManager`. (Implemented in D109485.) This VFS currently persists between scans, which is not correct: in-memory files created in one scan could affect subsequent scans. This patch changes things so that the in-memory VFS is local to `DependencyScanningWorker::computeDependencies()`.
To test this, one would first scan for dependencies of a named module and then run second scan (on the same worker) for something unrelated, which would pick up the in-memory file created in the first scan. This set up is impossible to achieve with `clang-scan-deps`. We could set this up in `ToolingTests`, but the scanner needs to access the physical filesystem to store `.pcm` files. AFAIK we don't have a good way to propagate something like `%t` into unit tests to make that feasible. (This could be achieved with something like the virtualized `OutputManager`.)
Reviewed By: Bigcheese
Differential Revision: https://reviews.llvm.org/D135414
Diffstat (limited to 'llvm/lib/CodeGen/ModuloSchedule.cpp')
0 files changed, 0 insertions, 0 deletions