We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
__data_end
1 parent 8fe9c63 commit 9b2390cCopy full SHA for 9b2390c
1 file changed
tests/compile-only/addresses.c
@@ -2,16 +2,20 @@
2
#include <limits.h>
3
4
extern void __dso_handle;
5
+#if !defined(__clang_major__) || __clang_major__ >= 10
6
extern void __data_end;
7
extern void __global_base;
8
extern void __heap_base;
9
+#endif
10
11
int main(int argc, char *argv[]) {
12
printf("NULL=%p\n", NULL);
13
printf("__dso_handle=%p\n", &__dso_handle);
14
15
printf("__data_end=%p\n", &__data_end);
16
printf("__global_base=%p\n", &__global_base);
17
printf("__heap_base=%p\n", &__heap_base);
18
19
printf("__builtin_frame_address(0)=%p\n", __builtin_frame_address(0));
20
printf("__builtin_alloca(0)=%p\n", __builtin_alloca(0));
21
printf("__builtin_wasm_memory_size(0)=%p\n", (void *)(__builtin_wasm_memory_size(0) * PAGE_SIZE));
0 commit comments