头文件位置:bionic/libc/include/
stdint.h (基本数据类型)
- uintptr_t
50 #if defined(__LP64__) 51 typedef long __intptr_t; 52 typedef unsigned long __uintptr_t; 53 #else 54 typedef int __intptr_t; 55 typedef unsigned int __uintptr_t; 56 #endif ... 71 typedef __uintptr_t uintptr_t;
https://developer.android.google.cn/google/play/requirements/64-bit?hl=zh-cn,android官方说明了用
__LP64__
宏来区分64与32位操作系统。
stdatomic.h (原子操作)
55 #define _Atomic(t) std::atomic<t>
290 typedef _Atomic(uintptr_t) atomic_uintptr_t;
324 #define atomic_load_explicit(object, order) \
325 __c11_atomic_load(object, order) //__c11_atomic_load为gcc编译器的内建函数
0 条评论