[NFC][ThinLTO] Avoid temporary std::string (#130353)

Preparation for CFI Index refactoring,
which will fix O(N^2) in ThinLTO indexing.
This commit is contained in:
Vitaly Buka 2025-03-07 14:56:44 -08:00 committed by GitHub
parent e4a6e2eb71
commit d8e8892ddf
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1699,9 +1699,9 @@ void LowerTypeTestsModule::buildBitSetsFromFunctionsNative(
if (IsExported) {
if (IsJumpTableCanonical)
ExportSummary->cfiFunctionDefs().insert(std::string(F->getName()));
ExportSummary->cfiFunctionDefs().emplace(F->getName());
else
ExportSummary->cfiFunctionDecls().insert(std::string(F->getName()));
ExportSummary->cfiFunctionDecls().emplace(F->getName());
}
if (!IsJumpTableCanonical) {