[all-commits] [llvm/llvm-project] c84d8e: [clang][modules] Introduce new `ModuleCache` inter...
Jan Svoboda via All-commits
all-commits at lists.llvm.org
Fri Mar 14 11:33:01 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: c84d8e8f1c406ab34d56efd4a9f8c5fbce70af2d
https://github.com/llvm/llvm-project/commit/c84d8e8f1c406ab34d56efd4a9f8c5fbce70af2d
Author: Jan Svoboda <jan_svoboda at apple.com>
Date: 2025-03-14 (Fri, 14 Mar 2025)
Changed paths:
M clang-tools-extra/clangd/ModulesBuilder.cpp
M clang/include/clang/Frontend/ASTUnit.h
M clang/include/clang/Frontend/CompilerInstance.h
M clang/include/clang/Serialization/ASTReader.h
M clang/include/clang/Serialization/ASTWriter.h
A clang/include/clang/Serialization/ModuleCache.h
M clang/include/clang/Serialization/ModuleManager.h
M clang/lib/Frontend/ASTUnit.cpp
M clang/lib/Frontend/CompilerInstance.cpp
M clang/lib/Frontend/PrecompiledPreamble.cpp
M clang/lib/Serialization/ASTReader.cpp
M clang/lib/Serialization/ASTWriter.cpp
M clang/lib/Serialization/CMakeLists.txt
M clang/lib/Serialization/GeneratePCH.cpp
A clang/lib/Serialization/ModuleCache.cpp
M clang/lib/Serialization/ModuleManager.cpp
M clang/unittests/Frontend/FrontendActionTest.cpp
M clang/unittests/Lex/HeaderSearchTest.cpp
Log Message:
-----------
[clang][modules] Introduce new `ModuleCache` interface (#131193)
This PR adds new `ModuleCache` interface to Clang's implicitly-built
modules machinery. The main motivation for this change is to create a
second implementation that uses a more efficient kind of
`llvm::AdvisoryLock` during dependency scanning.
In addition to the lock abstraction, the `ModuleCache` interface also
manages the existing `InMemoryModuleCache` instance. I found that
compared to keeping these separate/independent, the code is a bit
simpler now, since these are two tightly coupled concepts. I can
envision a more efficient implementation of the `InMemoryModuleCache`
for the single-process case too, which will be much easier to implement
with the current setup.
This is not intended to be a functional change.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list