[clang][modules][deps] Create more efficient API for visitation of `ModuleFile` inputs
The current `ASTReader::visitInputFiles()` function calls into `FileManager` to create `FileEntryRef` objects. This ends up being fairly costly in `clang-scan-deps`, where we mostly only care about file paths. This patch introduces new `ASTReader` API that gives clients access to just the serialized paths. Since the scanner needs both the as-requested path and the on-disk one (and doesn't want to transform the former into the latter via `FileManager`), this patch starts serializing both of them into the PCM file if they differ. This increases the size of scanning PCMs by 0.1% and speeds up scanning by 5%. Reviewed By: benlangmuir, vsapsai Differential Revision: https://reviews.llvm.org/D157066
parent
6556e290
Please register or sign in to comment