This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH 03/13] posix: Consolidate Linux nanosleep syscall
On 12/05/2017 15:21, Florian Weimer wrote:
> On 05/12/2017 07:58 PM, Adhemerval Zanella wrote:
>> +++ b/nptl/Makefile
>
>> +CFLAGS-nanosleep.c = -fexceptions -fasynchronous-unwind-tables
>
>
>> +++ b/posix/Makefile
>
>> +CFLAGS-nanosleep.c = -fexceptions
>
> Why the discrepancy? I suppose both implementations could be called in a multi-threaded program.
I do not recall a reason why these are different, I will set both to
-fexceptions -fasynchronous-unwind-tables. AFAIK -fexception is the
required flag for cancelable syscall to work correctly, while
-fasynchronous-unwind-tables is make it work also through signals
(not really sure though). So I would say to be safe we should set
both.