span = dsa_get_address(area, span_pointer);
fprintf(stderr,
- " span descriptor at %016lx, "
- "superblock at %016lx, pages = %zu, "
- "objects free = %hu/%hu\n",
+ " span descriptor at "
+ DSA_POINTER_FORMAT ", superblock at "
+ DSA_POINTER_FORMAT
+ ", pages = %zu, objects free = %hu/%hu\n",
span_pointer, span->start, span->npages,
span->nallocatable, span->nmax);
span_pointer = span->nextspan;
#define dsa_pointer_atomic_write pg_atomic_write_u32
#define dsa_pointer_atomic_fetch_add pg_atomic_fetch_add_u32
#define dsa_pointer_atomic_compare_exchange pg_atomic_compare_exchange_u32
+#define DSA_POINTER_FORMAT "%08x"
#else
typedef uint64 dsa_pointer;
typedef pg_atomic_uint64 dsa_pointer_atomic;
#define dsa_pointer_atomic_write pg_atomic_write_u64
#define dsa_pointer_atomic_fetch_add pg_atomic_fetch_add_u64
#define dsa_pointer_atomic_compare_exchange pg_atomic_compare_exchange_u64
+#define DSA_POINTER_FORMAT "%016" INT64_MODIFIER "x"
#endif
/* A sentinel value for dsa_pointer used to indicate failure to allocate. */