aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorPatrick Bernardi <bernardi@adacore.com>2024-08-16 19:00:23 -0400
committerMarc Poulhiès <dkm@gcc.gnu.org>2024-09-02 10:22:50 +0200
commit34437eb472f18af091890336ef1a1c70bbc95132 (patch)
tree9a203650131a4ff93883543e7cdb9351d0f9c25a /gcc
parentcb690aa1ce37f109986a5848c2b727be6a2aaacb (diff)
downloadgcc-34437eb472f18af091890336ef1a1c70bbc95132.zip
gcc-34437eb472f18af091890336ef1a1c70bbc95132.tar.gz
gcc-34437eb472f18af091890336ef1a1c70bbc95132.tar.bz2
ada: Small fixes for FreeBSD
Size of pthread data types now need to be defined for FreeBSD ports. Traceback support for AArch64 FreeBSD is now defined. gcc/ada/ * s-oscons-tmplt.c: Define sizes of pthread data types on FreeBSD. * tracebak.c: Use GCC unwinder and adjust PC appropriately on aarch64-freebsd.
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ada/s-oscons-tmplt.c9
-rw-r--r--gcc/ada/tracebak.c5
2 files changed, 9 insertions, 5 deletions
diff --git a/gcc/ada/s-oscons-tmplt.c b/gcc/ada/s-oscons-tmplt.c
index 946da34..96eb99d 100644
--- a/gcc/ada/s-oscons-tmplt.c
+++ b/gcc/ada/s-oscons-tmplt.c
@@ -1997,8 +1997,10 @@ CND(CLOCK_THREAD_CPUTIME_ID, "Thread CPU clock")
CNS(CLOCK_RT_Ada, "")
#endif
-#if defined (__APPLE__) || defined (__linux__) || defined (__ANDROID__) \
- || defined (__QNX__) || defined (__rtems__) || defined (DUMMY)
+#if defined (__APPLE__) || defined (__ANDROID__) || defined (DUMMY) \
+ || defined (__FreeBSD__) || defined (__linux__) \
+ || defined (__QNX__) || defined (__rtems__)
+
/*
-- Sizes of pthread data types
@@ -2041,7 +2043,8 @@ CND(PTHREAD_RWLOCKATTR_SIZE, "pthread_rwlockattr_t")
CND(PTHREAD_RWLOCK_SIZE, "pthread_rwlock_t")
CND(PTHREAD_ONCE_SIZE, "pthread_once_t")
-#endif /* __APPLE__ || __linux__ || __ANDROID__ || __rtems__ */
+#endif /* __APPLE__ || __ANDROID__ || __FreeBSD ||__linux__
+ || __QNX__|| __rtems__ */
/*
diff --git a/gcc/ada/tracebak.c b/gcc/ada/tracebak.c
index 13ab707..da940d1 100644
--- a/gcc/ada/tracebak.c
+++ b/gcc/ada/tracebak.c
@@ -564,9 +564,10 @@ is_return_from(void *symbol_addr, void *ret_addr)
#error Unhandled QNX architecture.
#endif
-/*------------------- aarch64-linux or aarch64-rtems -----------------*/
+/*------------------- aarch64 FreeBSD, Linux, RTEMS -----------------*/
-#elif (defined (__aarch64__) && (defined (__linux__) || defined (__rtems__)))
+#elif (defined (__aarch64__) && (defined (__FreeBSD__) || \
+ defined (__linux__) || defined (__rtems__)))
#define USE_GCC_UNWINDER
#define PC_ADJUST -4