llvm-project/clang/test/Headers
Duncan P. N. Exon Smith e77a3aff6f Headers: Make the type of SIZE_MAX the same as size_t
size_t is usually defined as unsigned long, but on 64-bit platforms,
stdint.h currently defines SIZE_MAX using "ull" (unsigned long long).
Although this is the same width, it doesn't necessarily have the same
alignment or calling convention.  It also triggers printf warnings when
using the format flag "%zu" to print SIZE_MAX.

This changes SIZE_MAX to reuse the compiler-provided __SIZE_MAX__, and
provides similar fixes for the other integers:

  - INTPTR_MIN
  - INTPTR_MAX
  - UINTPTR_MAX
  - PTRDIFF_MIN
  - PTRDIFF_MAX
  - INTMAX_MIN
  - INTMAX_MAX
  - UINTMAX_MAX
  - INTMAX_C()
  - UINTMAX_C()

... and fixes the typedefs for intptr_t and uintptr_t to use
__INTPTR_TYPE__ and __UINTPTR_TYPE__ instead of int32_t, effectively
reverting r89224, r89226, and r89237 (r89221 already having been
effectively reverted).

We can probably also kill __INTPTR_WIDTH__, __INTMAX_WIDTH__, and
__UINTMAX_WIDTH__ in a follow-up, but I was hesitant to delete all the
per-target CHECK lines in this commit since those might serve their own
purpose.

rdar://problem/11811377

llvm-svn: 301593
2017-04-27 21:49:45 +00:00
..
Inputs [Headers] Reapply: Add #include_next for tgmath.h on Darwin 2017-03-16 23:19:00 +00:00
altivec-header.c Remove the -faltivec alias option and replace it with -maltivec everywhere. 2017-03-21 22:06:18 +00:00
altivec-intrin.c Remove the -faltivec alias option and replace it with -maltivec everywhere. 2017-03-21 22:06:18 +00:00
arm-acle-header.c
arm-neon-header.c
arm64-apple-ios-types.cpp
c11.c
c89.c
cpuid.c
cxx11.cpp [modules] Don't expose *intrin.h headers that cannot be included standalone as 2016-04-16 00:46:26 +00:00
float-darwin.c [Headers] Enable #include_next<float.h> on Darwin 2016-12-08 02:13:56 +00:00
float.c test/Headers/float.c: fix theoretical edge values 2016-02-12 19:24:36 +00:00
htm-header.c Fix parsing of htmxlintrin.h in C++ mode 2017-03-20 22:31:33 +00:00
int64-type.c
limits.cpp
ms-intrin.cpp Implement __stosb intrinsic as a volatile memset 2016-10-14 17:33:05 +00:00
ms-null-ms-header-vs-stddef.cpp
ms-wchar.c
opencl-c-header.cl [OpenCL] Correct ndrange_t implementation 2017-02-16 12:27:47 +00:00
pmmintrin.c Update the intel intrinsic headers to use the target attribute support. 2015-06-17 07:09:32 +00:00
stdarg-gnuc_va_list.c Guard __gnuc_va_list typedef. 2017-01-23 19:09:21 +00:00
stdatomic.c Use __CLANG_ATOMIC_TYPE_LOCK_FREE macros in `stdatomic.h` 2017-04-20 23:07:38 +00:00
stdbool.cpp
stddefneeds.cpp
stdint-typeof-MINMAX.cpp Headers: Make the type of SIZE_MAX the same as size_t 2017-04-27 21:49:45 +00:00
tgmath-darwin.c [Headers] Reapply: Add #include_next for tgmath.h on Darwin 2017-03-16 23:19:00 +00:00
tgmath.c
thumbv7-apple-ios-types.cpp
typedef_guards.c
unwind.c
wchar_limits.cpp
wmmintrin.c
x86-intrinsics-headers.c
x86_64-apple-macosx-types.cpp
x86intrin-2.c [AVX512] _m512_setzero_qi/hi should return __m512i. 2016-05-17 03:42:25 +00:00
x86intrin.c Update the intel intrinsic headers to use the target attribute support. 2015-06-17 07:09:32 +00:00
x86intrin.cpp Add some MS aliases for existing intrinsics 2016-09-14 21:19:43 +00:00
xmmintrin.c [X86] _MM_ALIGN16 attribute support for non-windows targets 2016-06-18 20:01:07 +00:00