@@ -1209,8 +1209,7 @@ void ModuleBitcodeWriter::writeTypeTable() {
1209
1209
TypeVals.push_back (TET->getNumTypeParameters ());
1210
1210
for (Type *InnerTy : TET->type_params ())
1211
1211
TypeVals.push_back (VE.getTypeID (InnerTy));
1212
- for (unsigned IntParam : TET->int_params ())
1213
- TypeVals.push_back (IntParam);
1212
+ llvm::append_range (TypeVals, TET->int_params ());
1214
1213
break ;
1215
1214
}
1216
1215
case Type::TypedPointerTyID:
@@ -4303,10 +4302,8 @@ static void writeFunctionHeapProfileRecords(
4303
4302
}
4304
4303
for (auto Id : CI.StackIdIndices )
4305
4304
Record.push_back (GetStackIndex (Id));
4306
- if (!PerModule) {
4307
- for (auto V : CI.Clones )
4308
- Record.push_back (V);
4309
- }
4305
+ if (!PerModule)
4306
+ llvm::append_range (Record, CI.Clones );
4310
4307
Stream.EmitRecord (PerModule ? bitc::FS_PERMODULE_CALLSITE_INFO
4311
4308
: bitc::FS_COMBINED_CALLSITE_INFO,
4312
4309
Record, CallsiteAbbrev);
@@ -4326,10 +4323,8 @@ static void writeFunctionHeapProfileRecords(
4326
4323
assert (CallStackCount <= CallStackPos.size ());
4327
4324
Record.push_back (CallStackPos[CallStackCount++]);
4328
4325
}
4329
- if (!PerModule) {
4330
- for (auto V : AI.Versions )
4331
- Record.push_back (V);
4332
- }
4326
+ if (!PerModule)
4327
+ llvm::append_range (Record, AI.Versions );
4333
4328
assert (AI.ContextSizeInfos .empty () ||
4334
4329
AI.ContextSizeInfos .size () == AI.MIBs .size ());
4335
4330
// Optionally emit the context size information if it exists.
0 commit comments