[clang] [clang][modules] Track Included Files Per Submodule (PR #170215)
Qiongsi Wu via cfe-commits
cfe-commits at lists.llvm.org
Tue Dec 9 10:34:52 PST 2025
================
@@ -2373,10 +2386,8 @@ HeaderFileInfoTrait::ReadData(internal_key_ref key, const unsigned char *d,
// implicit module import.
SubmoduleID GlobalSMID = Reader.getGlobalSubmoduleID(M, LocalSMID);
Module *Mod = Reader.getSubmodule(GlobalSMID);
- ModuleMap &ModMap =
- Reader.getPreprocessor().getHeaderSearchInfo().getModuleMap();
- if (FE || (FE = getFile(key))) {
+ if (FE) {
----------------
qiongsiwu wrote:
Are we commenting on the change where I removed the `FE = getFile(key)` expression? If so, I think we are ok because the expression seems loop invariant to me, and it is pulled out and is executed earlier unconditionally. See the change at [line 2356](https://github.com/llvm/llvm-project/pull/170215/files#diff-c61a3cce4bfa099b5af032fa83cbf1563f0af4bf58dc112b39571d74b6b681c1R2356).
https://github.com/llvm/llvm-project/pull/170215
More information about the cfe-commits
mailing list