[PATCH] D158469: [clang][deps] Compute command lines and file deps on-demand

Jan Svoboda via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 21 17:22:51 PDT 2023


jansvoboda11 created this revision.
jansvoboda11 added a reviewer: benlangmuir.
Herald added a subscriber: ributzka.
Herald added a project: All.
jansvoboda11 requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.

Although generating command lines and collecting file dependencies recently got faster, there are still benefits to be had from doing these lazily, on-demand.

This patch makes it so that the `ModuleDepsGraph` keeps the scanning instance alive. Instances of `ModuleDeps` can then use pointer to the `ModuleDepCollector` to compute the information lazily.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D158469

Files:
  clang/include/clang/Tooling/DependencyScanning/DependencyScanningTool.h
  clang/include/clang/Tooling/DependencyScanning/DependencyScanningWorker.h
  clang/include/clang/Tooling/DependencyScanning/ModuleDepCollector.h
  clang/lib/Tooling/DependencyScanning/DependencyScanningTool.cpp
  clang/lib/Tooling/DependencyScanning/DependencyScanningWorker.cpp
  clang/lib/Tooling/DependencyScanning/ModuleDepCollector.cpp
  clang/tools/clang-scan-deps/ClangScanDeps.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D158469.552173.patch
Type: text/x-patch
Size: 14421 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230822/b9ebc0f4/attachment.bin>


More information about the cfe-commits mailing list