]>
git.proxmox.com Git - rustc.git/blob - src/compiler-rt/test/sanitizer_common/print_address.h
4 void print_address(const char *str
, int n
, ...) {
5 fprintf(stderr
, "%s", str
);
9 void *p
= va_arg(ap
, void *);
10 #if defined(__x86_64__) || defined(__aarch64__) || defined(__powerpc64__)
11 // On FreeBSD, the %p conversion specifier works as 0x%x and thus does not
12 // match to the format used in the diagnotic message.
13 fprintf(stderr
, "0x%012lx ", (unsigned long) p
);
14 #elif defined(__mips64)
15 fprintf(stderr
, "0x%010lx ", (unsigned long) p
);
18 fprintf(stderr
, "\n");