@@ -204,18 +204,11 @@ struct Stats {
204204 }
205205 };
206206
207+
207208 foreachAC ([&](auto tid, auto pid, auto cid, auto stats) {
208209 auto [allocSizeSuffix, allocSize] = formatMemory (stats.allocSize );
209210 auto [memorySizeSuffix, memorySize] =
210211 formatMemory (stats.totalAllocatedSize ());
211- out << folly::sformat (" tid{:2} pid{:2} cid{:4} {:8.2f}{} memorySize: {:8.2f}{}" ,
212- tid, pid, cid, allocSize, allocSizeSuffix, memorySize,
213- memorySizeSuffix)
214- << std::endl;
215- });
216-
217- foreachAC ([&](auto tid, auto pid, auto cid, auto stats) {
218- auto [allocSizeSuffix, allocSize] = formatMemory (stats.allocSize );
219212
220213 // If the pool is not full, extrapolate usageFraction for AC assuming it
221214 // will grow at the same rate. This value will be the same for all ACs.
@@ -225,8 +218,10 @@ struct Stats {
225218
226219 out << folly::sformat (
227220 " tid{:2} pid{:2} cid{:4} {:8.2f}{} usageFraction: {:4.2f} "
221+ " memorySize: {:8.2f}{} "
228222 " rollingAvgAllocLatency: {:8.2f}ns" ,
229223 tid, pid, cid, allocSize, allocSizeSuffix, acUsageFraction,
224+ memorySize, memorySizeSuffix,
230225 stats.allocLatencyNs .estimate ())
231226 << std::endl;
232227 });
0 commit comments