[PATCH] D150981: [lld][COFF] Retry failed paths to take advantage of winsysroot search paths

Arthur Eubanks via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri May 19 10:06:48 PDT 2023


aeubanks created this revision.
aeubanks added reviewers: hans, thakis.
Herald added a project: All.
aeubanks requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

With /winsysroot and without /machine, we don't know which paths to add to the search paths.

We do autodetect machine type and add winsysroot search paths in SymbolTable::addFile(), but that happens after all input files are opened. We could do this serially and update the search paths between input files, but then that doesn't work for the first input file, plus lld-link wants to open input files concurrently since file I/O is slow on Windows.

So instead, keep track of which files couldn't be opened and retry after adding winsysroot search paths.

Fixes #54409


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D150981

Files:
  lld/COFF/Driver.cpp
  lld/COFF/Driver.h
  lld/test/COFF/winsysroot.test

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D150981.523833.patch
Type: text/x-patch
Size: 7089 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230519/52e9546f/attachment.bin>


More information about the llvm-commits mailing list