From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [216.205.24.124]) by sourceware.org (Postfix) with ESMTP id 7E735385481F for ; Wed, 17 Mar 2021 20:33:53 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 7E735385481F Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-15-wpWviWuiNfStYpuw2yI3HQ-1; Wed, 17 Mar 2021 16:33:49 -0400 X-MC-Unique: wpWviWuiNfStYpuw2yI3HQ-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 14D51612B0; Wed, 17 Mar 2021 20:33:48 +0000 (UTC) Received: from oldenburg.str.redhat.com (ovpn-115-121.ams2.redhat.com [10.36.115.121]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3C0145C1CF; Wed, 17 Mar 2021 20:33:47 +0000 (UTC) From: Florian Weimer To: Adhemerval Zanella Cc: Adhemerval Zanella via Libc-alpha Subject: Re: [PATCH v3 09/37] nptl: Move __pthread_unwind_next into libc References: <37181fcb-03db-dec0-11bd-01009324d2c5@linaro.org> <871rcdy2ru.fsf@oldenburg.str.redhat.com> <3391e1fd-44c9-9231-3289-23968b61b0a9@linaro.org> Date: Wed, 17 Mar 2021 21:33:53 +0100 In-Reply-To: <3391e1fd-44c9-9231-3289-23968b61b0a9@linaro.org> (Adhemerval Zanella's message of "Wed, 17 Mar 2021 17:16:49 -0300") Message-ID: <87k0q5wmdq.fsf@oldenburg.str.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain X-Spam-Status: No, score=-5.8 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP, URIBL_BLACK autolearn=no autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Mar 2021 20:33:54 -0000 * Adhemerval Zanella: > On 17/03/2021 16:54, Florian Weimer wrote: >> * Adhemerval Zanella via Libc-alpha: >> >>> On 16/03/2021 14:29, Florian Weimer via Libc-alpha wrote: >>>> It's necessary to stub out __libc_disable_asynccancel and >>>> __libc_enable_asynccancel via rtld-stubbed-symbols because the new >>>> direct references to the unwinder result in symbol conflicts when the >>>> rtld exception handling from libc is linked in during the construction >>>> of librtld.map. >>> >>> From where exactly these come from? The *assynccancel should not be >>> generated for rtld-* objects. >> >> I think what happens is this: The libc.so objects that are used as a >> starting point have them, so the reducer tries to link in those symbols, >> and that fails with symbol conflicts. > > Right, but why doesn't it happen with other symbols that might be > pulled as well? It not a blocker, but I am trying to understand why > we are seeing this behavior with this change. Ah, the explanation is quite trivial: We used to have a forwarder for __pthread_unwind, and that acted as a firewall for the rtld symbol set discovery. Now the forwarder is gone, so the implementation of __pthread_unwind starts to matter. Maybe I should stub out __pthread_unwind instead? But doing it for the cancellation feels more natural. Thanks, Florian