tool/pps: Fix 32-bit build issue with format string

Fixes a 32-bit build issue with Perfetto enabled.
Move the printf format specifier to use PRIx64 which
will be consistent regardless of the build type.

Signed-Off By: Isaac Bosompem <mrisaacb@google.com>

Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20732>
This commit is contained in:
Isaac Bosompem
2023-01-16 15:54:21 -05:00
committed by Marge Bot
parent a32d6071e1
commit 4c0a54fc36

View File

@@ -14,6 +14,7 @@
#include <condition_variable>
#include <thread>
#include <variant>
#include <inttypes.h>
// Minimum supported sampling period in nanoseconds
#define MIN_SAMPLING_PERIOD_NS 50000
@@ -316,7 +317,7 @@ void GpuDataSource::trace(TraceContext &ctx)
}
if (!got_first_counters) {
PPS_LOG("Got first counters at gpu_ts=0x%016lx", gpu_timestamp);
PPS_LOG("Got first counters at gpu_ts=0x%016" PRIx64, gpu_timestamp);
got_first_counters = true;
}