From: Andreas Schwab <schwab@linux-m68k.org>
To: Florian Weimer <fweimer@redhat.com>
Cc: libc-alpha@sourceware.org
Subject: Re: Async cacellation and pthread_cleanup_push
Date: Wed, 04 Aug 2021 18:24:12 +0200 [thread overview]
Message-ID: <87pmuttbyr.fsf@igel.home> (raw)
In-Reply-To: <87fsvp6vis.fsf@oldenburg.str.redhat.com> (Florian Weimer's message of "Wed, 04 Aug 2021 18:10:19 +0200")
On Aug 04 2021, Florian Weimer wrote:
> * Andreas Schwab:
>
>> On Aug 04 2021, Florian Weimer wrote:
>>
>>> * Andreas Schwab:
>>>
>>>> Is pthread_cleanup_push supposed to work together with async
>>>> cancellation?
>>>
>>> In our implementation? I think so.
>>
>> I don't see how that can work with -fexceptions or in C++, though. Is
>> that supported?
>
> I think it is supposed to work, but it probably is unreliable.
Since the compiler puts the exception regions only over function calls
(and -fnon-call-exceptions only covers potentially trapping insns in
addition) the cleanup region will not be fully covered.
>>> POSIX doesn't require it, though.
>>
>> Chapter and verse?
>
> 2.9.5 Thread Cancellation, Thread Cancellation Cleanup Handlers and
> Async-Cancel Safety. The first section calls pthread_cleanup_push a
> function, the second section does not list it.
>
>> Then the LTP test is INVALID.
>
> Which test? It could be a test for Linux extension.
testcases/open_posix_testsuite/conformance/interfaces/pthread_cancel/3-1.c
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1
"And now for something completely different."
next prev parent reply other threads:[~2021-08-04 16:24 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-08-04 13:58 Async cacellation and pthread_cleanup_push Andreas Schwab
2021-08-04 15:33 ` Florian Weimer via Libc-alpha
2021-08-04 16:04 ` Andreas Schwab
2021-08-04 16:10 ` Florian Weimer via Libc-alpha
2021-08-04 16:24 ` Andreas Schwab [this message]
2021-08-23 9:43 ` Florian Weimer via Libc-alpha
2021-08-23 10:05 ` Andreas Schwab
2021-08-23 10:11 ` Florian Weimer via Libc-alpha
2021-08-23 10:24 ` Andreas Schwab
2021-08-23 10:58 ` Florian Weimer via Libc-alpha
2021-08-05 10:43 ` Petr Vorel
2021-08-06 5:25 ` Petr Vorel
2021-08-23 9:38 ` Florian Weimer via Libc-alpha
2021-08-23 9:49 ` Petr Vorel
2021-08-04 18:43 ` Zack Weinberg via Libc-alpha
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/libc/involved.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87pmuttbyr.fsf@igel.home \
--to=schwab@linux-m68k.org \
--cc=fweimer@redhat.com \
--cc=libc-alpha@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).