1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 10:42:39 +01:00

[TableGen] Use ListSeparator (NFC)

This commit is contained in:
Kazu Hirata 2021-02-09 22:14:26 -08:00
parent ca74e6236d
commit 14e0945738

View File

@ -91,13 +91,10 @@ void ValueTypeByHwMode::writeToStream(raw_ostream &OS) const {
llvm::sort(Pairs, deref<std::less<PairType>>()); llvm::sort(Pairs, deref<std::less<PairType>>());
OS << '{'; OS << '{';
for (unsigned i = 0, e = Pairs.size(); i != e; ++i) { ListSeparator LS(",");
const PairType *P = Pairs[i]; for (const PairType *P : Pairs)
OS << '(' << getModeName(P->first) OS << LS << '(' << getModeName(P->first) << ':'
<< ':' << getMVTName(P->second).str() << ')'; << getMVTName(P->second).str() << ')';
if (i != e-1)
OS << ',';
}
OS << '}'; OS << '}';
} }
@ -183,12 +180,9 @@ void RegSizeInfoByHwMode::writeToStream(raw_ostream &OS) const {
llvm::sort(Pairs, deref<std::less<PairType>>()); llvm::sort(Pairs, deref<std::less<PairType>>());
OS << '{'; OS << '{';
for (unsigned i = 0, e = Pairs.size(); i != e; ++i) { ListSeparator LS(",");
const PairType *P = Pairs[i]; for (const PairType *P : Pairs)
OS << '(' << getModeName(P->first) << ':' << P->second << ')'; OS << LS << '(' << getModeName(P->first) << ':' << P->second << ')';
if (i != e-1)
OS << ',';
}
OS << '}'; OS << '}';
} }