Skip to content

Commit 36c2940

Browse files
committed
[lld-link] Remove unneeded Twine when using COFFSyncStream
1 parent 8d225f1 commit 36c2940

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

lld/COFF/DebugTypes.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1149,8 +1149,8 @@ void TypeMerger::mergeTypesWithGHash() {
11491149
"midpoint is not midpoint");
11501150
uint32_t numTypes = std::distance(entries.begin(), mid);
11511151
uint32_t numItems = std::distance(mid, entries.end());
1152-
Log(ctx) << "Tpi record count: " << Twine(numTypes);
1153-
Log(ctx) << "Ipi record count: " << Twine(numItems);
1152+
Log(ctx) << "Tpi record count: " << numTypes;
1153+
Log(ctx) << "Ipi record count: " << numItems;
11541154

11551155
// Make a list of the "unique" type records to merge for each tpi source. Type
11561156
// merging will skip indices not on this list. Store the destination PDB type

lld/COFF/Writer.cpp

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -676,9 +676,8 @@ void Writer::finalizeAddresses() {
676676
}
677677
if (rangesOk) {
678678
if (pass > 0)
679-
Log(ctx) << "Added " << Twine(numChunks - origNumChunks)
680-
<< " thunks with " << "margin " << Twine(margin) << " in "
681-
<< Twine(pass) << " passes";
679+
Log(ctx) << "Added " << (numChunks - origNumChunks) << " thunks with "
680+
<< "margin " << margin << " in " << pass << " passes";
682681
return;
683682
}
684683

@@ -2245,8 +2244,7 @@ void Writer::createRuntimePseudoRelocs() {
22452244
}
22462245

22472246
if (!rels.empty()) {
2248-
Log(ctx) << "Writing " << Twine(rels.size())
2249-
<< " runtime pseudo relocations";
2247+
Log(ctx) << "Writing " << rels.size() << " runtime pseudo relocations";
22502248
const char *symbolName = "_pei386_runtime_relocator";
22512249
Symbol *relocator = ctx.symtab.findUnderscore(symbolName);
22522250
if (!relocator)
@@ -2523,7 +2521,7 @@ void Writer::sortCRTSectionChunks(std::vector<Chunk *> &chunks) {
25232521
for (auto &c : chunks) {
25242522
auto sc = dyn_cast<SectionChunk>(c);
25252523
Log(ctx) << " " << sc->file->mb.getBufferIdentifier().str()
2526-
<< ", SectionID: " << Twine(sc->getSectionNumber());
2524+
<< ", SectionID: " << sc->getSectionNumber();
25272525
}
25282526
}
25292527
}

0 commit comments

Comments
 (0)