diff options
author | Arnaud Charlet <charlet@gcc.gnu.org> | 2015-10-26 11:39:41 +0100 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2015-10-26 11:39:41 +0100 |
commit | 02886c2e8a6056b5e969f57431671d0980596f0b (patch) | |
tree | 49e526ca3aacced71bb9e4c9238a41de95737534 /gcc/ada/adaint.c | |
parent | 51022ff73102918ab0574d677b6d572a0cb2c59b (diff) | |
download | gcc-02886c2e8a6056b5e969f57431671d0980596f0b.zip gcc-02886c2e8a6056b5e969f57431671d0980596f0b.tar.gz gcc-02886c2e8a6056b5e969f57431671d0980596f0b.tar.bz2 |
2015-10-26 Joel Brobecker <brobecker@adacore.com brobecker>
* adaint.c (__gnat_lwp_self): Replace current implementation re-using
the Linux one, which uses an __NR_gettid syscall rather than
pthread_self.
2015-10-26 Arnaud Charlet <charlet@adacore.com>
* sinfo.ads, exp_ch3.adb (Build_Array_Init_Proc,
Build_Record_Init_Proc): Do not inline init procs when
Modify_Tree_For_C is True.
2015-10-26 Bob Duff <duff@adacore.com>
* errout.ads: Minor comment fix.
* einfo.ads: Minor style fix.
2015-10-26 Bob Duff <duff@adacore.com>
* sem_ch3.adb (Derive_Interface_Subprogram): Fix
Is_Abstract_Subprogram, which might have been calculated
incorrectly, because we're passing Ultimate_Alias (Subp) (and
its dispatching type) to Derive_Subprogram, instead of the true
parent subprogram and type.
2015-10-26 Bob Duff <duff@adacore.com>
* sem_ch13.adb (Check_Iterator_Functions): When
printing the "default iterator must be unique" error message,
also print references to the places where the duplicates are
declared. This makes the message clearer.
From-SVN: r229320
Diffstat (limited to 'gcc/ada/adaint.c')
-rw-r--r-- | gcc/ada/adaint.c | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/gcc/ada/adaint.c b/gcc/ada/adaint.c index cb3e82c..6e18d94 100644 --- a/gcc/ada/adaint.c +++ b/gcc/ada/adaint.c @@ -3061,17 +3061,7 @@ __gnat_sals_init_using_constructors (void) #endif } -#if defined (__ANDROID__) - -#include <pthread.h> - -void * -__gnat_lwp_self (void) -{ - return (void *) pthread_self (); -} - -#elif defined (__linux__) +#if defined (__linux__) || defined (__ANDROID__) /* There is no function in the glibc to retrieve the LWP of the current thread. We need to do a system call in order to retrieve this information. */ @@ -3081,7 +3071,9 @@ __gnat_lwp_self (void) { return (void *) syscall (__NR_gettid); } +#endif +#if defined (__linux__) #include <sched.h> /* glibc versions earlier than 2.7 do not define the routines to handle |