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 75BBE3858C3B for ; Wed, 15 Sep 2021 10:42:30 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 75BBE3858C3B 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-593-ce-KdVHyMaSAM77B0nrLgw-1; Wed, 15 Sep 2021 06:42:27 -0400 X-MC-Unique: ce-KdVHyMaSAM77B0nrLgw-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id EF8F684A5E0; Wed, 15 Sep 2021 10:42:25 +0000 (UTC) Received: from oldenburg.str.redhat.com (unknown [10.39.192.194]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 37EFC1000358; Wed, 15 Sep 2021 10:42:24 +0000 (UTC) From: Florian Weimer To: Joseph Myers Cc: Vincent Chen , libc-alpha@sourceware.org, andrew@sifive.com Subject: Re: [RFC 5/5] RISC-V: Expand PTHREAD_STACK_MIN to support RVV environment References: <1631497278-29829-1-git-send-email-vincent.chen@sifive.com> <1631497278-29829-6-git-send-email-vincent.chen@sifive.com> Date: Wed, 15 Sep 2021 12:42:22 +0200 In-Reply-To: (Joseph Myers's message of "Tue, 14 Sep 2021 23:43:22 +0000") Message-ID: <87a6ket90x.fsf@oldenburg.str.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain X-Spam-Status: No, score=-6.7 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_H2, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) 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, 15 Sep 2021 10:42:31 -0000 * Joseph Myers: > On Mon, 13 Sep 2021, Vincent Chen wrote: > >> In order to support all pthread operations in the RVV environment, here >> PTHREAD_STACK_MIN is set to 4 times GLRO(dl_minsigstacksize), and the >> default PTHREAD_STACK_MIN is expanded to 20K bytes. > > A change to PTHREAD_STACK_MIN has been considered an ABI change in the > past, requiring new symbol versions for pthread_attr_setstack and > pthread_attr_setstacksize to ensure that binaries built with the old > PTHREAD_STACK_MIN definition continue to work rather than failing because > the old size is too small. You may need symbol versioning updates for > those functions in RISC-V if you make such a change. (All the existing > versioning support for this in architecture-independent files assumes the > change in value was done before libpthread was merged into libc, so there > will be some extra work involved in being the first architecture to > increase PTHREAD_STACK_MIN after that merge.) Instead it may make sense to leave PTHREAD_STACK_MIN as is and switch to the dynamic version (same for the SIGSTKSZ constants). Thanks, Florian