From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.1 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 9844 invoked from network); 7 Dec 2021 00:37:36 -0000 Received: from mother.openwall.net (195.42.179.200) by inbox.vuxu.org with ESMTPUTF8; 7 Dec 2021 00:37:36 -0000 Received: (qmail 28293 invoked by uid 550); 7 Dec 2021 00:37:34 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Reply-To: musl@lists.openwall.com Received: (qmail 28273 invoked from network); 7 Dec 2021 00:37:33 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1638837441; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=nCB3MqDhl+ZDJ6MZxE9+Gp5EASyvUvhcRPv3CGImEmk=; b=Y8q+5uwg1W07Qw3uAfkg6Vble89xWiCC+VTsUGr6i1iLuobQgnzum73vtnl+tRUPM9zKuH hNfMiiesOdZpInrQjxtUKN1+lqwIEknY9RiKbO3EpHKsVwDPlppBjA4j6cF3wqDsJVozFY vuBCfmaec+GsJj6j3wUkEMNP/31C0YA= X-MC-Unique: rQBdsbawN0SV1MrnhgSzcA-1 From: Florian Weimer To: Stijn Tintel Cc: musl@lists.openwall.com References: <20211206234358.2174444-1-stijn@linux-ipv6.be> Date: Tue, 07 Dec 2021 01:37:12 +0100 In-Reply-To: <20211206234358.2174444-1-stijn@linux-ipv6.be> (Stijn Tintel's message of "Tue, 7 Dec 2021 01:43:58 +0200") Message-ID: <87tufljlmv.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 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=fweimer@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain Subject: Re: [musl] [PATCH] ppc64: check for AltiVec in setjmp/longjmp * Stijn Tintel: > diff --git a/src/setjmp/powerpc64/setjmp.s b/src/setjmp/powerpc64/setjmp.s > index 37683fda..32853693 100644 > --- a/src/setjmp/powerpc64/setjmp.s > +++ b/src/setjmp/powerpc64/setjmp.s > @@ -69,7 +69,17 @@ __setjmp_toc: > stfd 30, 38*8(3) > stfd 31, 39*8(3) > > - # 5) store vector registers v20-v31 > + # 5) store vector registers v20-v31 if hardware supports AltiVec > + mflr 0 > + bl 1f > + .hidden __hwcap > + .long __hwcap-. > +1: mflr 4 This de-balances the return stack and probably has quite severe performance impact. The ISA manual says to use bcl 20,31,$+4 and you'll have to store the __hwcap offset somewhere else. Thanks, Florian