@@ -225,7 +225,7 @@ void intel_require_memory(uint32_t count, uint32_t size, unsigned mode)
required *= size + KERNEL_BO_OVERHEAD;
required = ALIGN(required, 4096);
- igt_debug("Checking %u surfaces of size %u bytes (total %llu) against %s%s\n",
+ igt_debug("Checking %u surfaces of size %u bytes (total %'llu) against %s%s\n",
count, size, (long long)required,
mode & (CHECK_RAM | CHECK_SWAP) ? "RAM" : "",
mode & CHECK_SWAP ? " + swap": "");
@@ -238,7 +238,7 @@ void intel_require_memory(uint32_t count, uint32_t size, unsigned mode)
total *= 1024 * 1024;
igt_skip_on_f(total <= required,
- "Estimated that we need %llu bytes for the test, but only have %llu bytes available (%s%s)\n",
+ "Estimated that we need %'llu bytes for the test, but only have %'llu bytes available (%s%s)\n",
(long long)required, (long long)total,
mode & (CHECK_RAM | CHECK_SWAP) ? "RAM" : "",
mode & CHECK_SWAP ? " + swap": "");
@@ -63,7 +63,7 @@ int cpu_top_update(struct cpu_top *cpu)
sscanf(buf, "cpu %lu %lu %lu %lu",
&s->user, &s->nice, &s->sys, &s->idle);
#else
- sscanf(buf, "cpu %llu %llu %llu %llu",
+ sscanf(buf, "cpu %'llu %'llu %'llu %'llu",
&s->user, &s->nice, &s->sys, &s->idle);
#endif
@@ -697,7 +697,7 @@ static void show_gpu_freq(struct overlay_context *ctx, struct overlay_gpu_freq *
}
if (has_power) {
- sprintf(buf, "Power: %llumW", (long long unsigned)gf->power.power_mW);
+ sprintf(buf, "Power: %'llumW", (long long unsigned)gf->power.power_mW);
cairo_set_source_rgba(ctx->cr, 1, 1, 1, 1);
cairo_move_to(ctx->cr, PAD, y);
cairo_show_text(ctx->cr, buf);
@@ -705,7 +705,7 @@ static void show_gpu_freq(struct overlay_context *ctx, struct overlay_gpu_freq *
}
if (has_irqs) {
- sprintf(buf, "Interrupts: %llu", (long long unsigned)gf->irqs.delta);
+ sprintf(buf, "Interrupts: %'llu", (long long unsigned)gf->irqs.delta);
cairo_set_source_rgba(ctx->cr, 1, 1, 1, 1);
cairo_move_to(ctx->cr, PAD, y);
cairo_show_text(ctx->cr, buf);
@@ -213,13 +213,13 @@ igt_simple_main
ptr = NULL;
for (reloc_ofs = 4096; reloc_ofs < batch_size; reloc_ofs += 4096) {
- igt_debug("batch_size %llu, reloc_ofs %llu\n",
+ igt_debug("batch_size %'llu, reloc_ofs %'llu\n",
(long long)batch_size, (long long)reloc_ofs);
exec1(fd, handle, reloc_ofs, 0, ptr);
exec1(fd, handle, reloc_ofs, I915_EXEC_SECURE, ptr);
}
- igt_debug("batch_size %llu, all %ld relocs\n",
+ igt_debug("batch_size %'llu, all %ld relocs\n",
(long long)batch_size, (long)(batch_size >> 12));
execN(fd, handle, batch_size, 0, ptr);
execN(fd, handle, batch_size, I915_EXEC_SECURE, ptr);
@@ -637,7 +637,7 @@ int main(int argc, char **argv)
}
if (i < STATS_COUNT && HAS_STATS_REGS(devid)) {
- printf("%13s: %llu (%lld/sec)",
+ printf("%13s: %'llu (%'lld/sec)",
stats_reg_names[i],
(long long)stats[i],
(long long)(stats[i] - last_stats[i]));
After Chris' "Enable locale dependent output to a terminal" patch, we can put thousand separators into these long long outputs. sed "s/%ll/%'ll/g" Signed-off-by: Michel Thierry <michel.thierry@intel.com> --- lib/intel_os.c | 4 ++-- overlay/cpu-top.c | 2 +- overlay/overlay.c | 4 ++-- tests/gem_exec_big.c | 4 ++-- tools/intel_gpu_top.c | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-)