diff options
author | James Y Knight <jyknight@google.com> | 2015-06-04 15:36:29 +0000 |
---|---|---|
committer | James Y Knight <jyknight@google.com> | 2015-06-04 15:36:29 +0000 |
commit | 4b4d19ede267cb56f4463c24c1d335cfc195d0c3 (patch) | |
tree | 0e1877d4071455a9726abdbfb9742c184c9d5ffc /clang/test/Preprocessor/init.c | |
parent | a401eee22fabea8d214ab604037c937277477c38 (diff) | |
download | bcm5719-llvm-4b4d19ede267cb56f4463c24c1d335cfc195d0c3.tar.gz bcm5719-llvm-4b4d19ede267cb56f4463c24c1d335cfc195d0c3.zip |
[SPARC] Fix types of size_t, intptr_t, and ptrdiff_t on Linux.
They should be 'int' instead of 'long int' everywhere else except
NetBSD too, from what I gather in GCC's spec files. So, optimistically
changing it for everyone else, too.
llvm-svn: 239046
Diffstat (limited to 'clang/test/Preprocessor/init.c')
-rw-r--r-- | clang/test/Preprocessor/init.c | 23 |
1 files changed, 16 insertions, 7 deletions
diff --git a/clang/test/Preprocessor/init.c b/clang/test/Preprocessor/init.c index c5dff25f042..e80d57b82cd 100644 --- a/clang/test/Preprocessor/init.c +++ b/clang/test/Preprocessor/init.c @@ -6851,10 +6851,10 @@ // SPARC:#define __INTMAX_MAX__ 9223372036854775807LL // SPARC:#define __INTMAX_TYPE__ long long int // SPARC:#define __INTMAX_WIDTH__ 64 -// SPARC:#define __INTPTR_FMTd__ "ld" -// SPARC:#define __INTPTR_FMTi__ "li" -// SPARC:#define __INTPTR_MAX__ 2147483647L -// SPARC:#define __INTPTR_TYPE__ long int +// SPARC:#define __INTPTR_FMTd__ "d" +// SPARC:#define __INTPTR_FMTi__ "i" +// SPARC:#define __INTPTR_MAX__ 2147483647 +// SPARC:#define __INTPTR_TYPE__ int // SPARC:#define __INTPTR_WIDTH__ 32 // SPARC:#define __INT_FAST16_FMTd__ "hd" // SPARC:#define __INT_FAST16_FMTi__ "hi" @@ -6906,7 +6906,7 @@ // SPARC:#define __LONG_MAX__ 2147483647L // SPARC-NOT:#define __LP64__ // SPARC:#define __POINTER_WIDTH__ 32 -// SPARC:#define __PTRDIFF_TYPE__ long int +// SPARC:#define __PTRDIFF_TYPE__ int // SPARC:#define __PTRDIFF_WIDTH__ 32 // SPARC:#define __REGISTER_PREFIX__ // SPARC:#define __SCHAR_MAX__ 127 @@ -6926,7 +6926,7 @@ // SPARC:#define __SIZEOF_WCHAR_T__ 4 // SPARC:#define __SIZEOF_WINT_T__ 4 // SPARC:#define __SIZE_MAX__ 4294967295U -// SPARC:#define __SIZE_TYPE__ long unsigned int +// SPARC:#define __SIZE_TYPE__ unsigned int // SPARC:#define __SIZE_WIDTH__ 32 // SPARC:#define __UINT16_C_SUFFIX__ {{$}} // SPARC:#define __UINT16_MAX__ 65535 @@ -6945,7 +6945,7 @@ // SPARC:#define __UINTMAX_TYPE__ long long unsigned int // SPARC:#define __UINTMAX_WIDTH__ 64 // SPARC:#define __UINTPTR_MAX__ 4294967295U -// SPARC:#define __UINTPTR_TYPE__ long unsigned int +// SPARC:#define __UINTPTR_TYPE__ unsigned int // SPARC:#define __UINTPTR_WIDTH__ 32 // SPARC:#define __UINT_FAST16_MAX__ 65535 // SPARC:#define __UINT_FAST16_TYPE__ unsigned short @@ -6975,6 +6975,15 @@ // SPARC:#define __sparcv8 1 // SPARC:#define sparc 1 // +// RUN: %clang_cc1 -E -dM -ffreestanding -triple=sparc-none-netbsd < /dev/null | FileCheck -check-prefix SPARC-NETBSD %s +// SPARC-NETBSD:#define __INTPTR_FMTd__ "ld" +// SPARC-NETBSD:#define __INTPTR_FMTi__ "li" +// SPARC-NETBSD:#define __INTPTR_MAX__ 2147483647L +// SPARC-NETBSD:#define __INTPTR_TYPE__ long int +// SPARC-NETBSD:#define __PTRDIFF_TYPE__ long int +// SPARC-NETBSD:#define __SIZE_TYPE__ long unsigned int +// SPARC-NETBSD:#define __UINTPTR_TYPE__ long unsigned int + // RUN: %clang_cc1 -E -dM -ffreestanding -triple=tce-none-none < /dev/null | FileCheck -check-prefix TCE %s // // TCE-NOT:#define _LP64 |