zequanwu added inline comments.

================
Comment at: lld/COFF/LTO.cpp:183
+      [&](size_t task, const Twine &moduleName) {
+        buf[task].first = moduleName.str();
         return std::make_unique<CachedFileStream>(
----------------
int3 wrote:
> Any reason why this doesn't instead store the module name in the 
> `file_names[task]` vector that the cache callback uses? Are the task IDs not 
> unique across each run of `ltoObj`, regardless of whether we end up using the 
> cache or not?
Users have to explicitly uses the flag `/opt:lldltocache=path` to let lld to 
search for cache files at the given folder. If it's not given, the callback of 
localCache won't be invoked. 


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D137217/new/

https://reviews.llvm.org/D137217

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to