mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-17 05:56:36 +00:00
[lld] Avoid repeated map lookups (NFC) (#132327)
This commit is contained in:
parent
7f8451c868
commit
690b8b4e94
@ -1278,8 +1278,7 @@ void Writer::createImportTables() {
|
||||
continue;
|
||||
|
||||
std::string dll = StringRef(file->dllName).lower();
|
||||
if (ctx.config.dllOrder.count(dll) == 0)
|
||||
ctx.config.dllOrder[dll] = ctx.config.dllOrder.size();
|
||||
ctx.config.dllOrder.try_emplace(dll, ctx.config.dllOrder.size());
|
||||
|
||||
if (file->impSym && !isa<DefinedImportData>(file->impSym))
|
||||
Fatal(ctx) << file->symtab.printSymbol(file->impSym) << " was replaced";
|
||||
|
Loading…
x
Reference in New Issue
Block a user