aboutsummaryrefslogtreecommitdiff
path: root/libgcc/config/arm/cmse.c
diff options
context:
space:
mode:
Diffstat (limited to 'libgcc/config/arm/cmse.c')
-rw-r--r--libgcc/config/arm/cmse.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/libgcc/config/arm/cmse.c b/libgcc/config/arm/cmse.c
index 4ef7102064e..e284bae4293 100644
--- a/libgcc/config/arm/cmse.c
+++ b/libgcc/config/arm/cmse.c
@@ -36,7 +36,7 @@ cmse_check_address_range (void *p, size_t size, int flags)
char *pb = (char *) p, *pe;
/* Check if the range wraps around. */
- if (UINTPTR_MAX - (uintptr_t) p < size)
+ if (__UINTPTR_MAX__ - (__UINTPTR_TYPE__) p < size)
return NULL;
/* Check if an unknown flag is present. */
@@ -51,7 +51,8 @@ cmse_check_address_range (void *p, size_t size, int flags)
/* Execute the right variant of the TT instructions. */
pe = pb + size - 1;
- const int singleCheck = (((uintptr_t) pb ^ (uintptr_t) pe) < 32);
+ const int singleCheck
+ = (((__UINTPTR_TYPE__) pb ^ (__UINTPTR_TYPE__) pe) < 32);
switch (flags & known_secure_level)
{
case 0: