Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp10137890rwb; Fri, 25 Nov 2022 01:15:09 -0800 (PST) X-Google-Smtp-Source: AA0mqf6JKer8USACXC2ozd7SdL1YI0Qhg6i9QpCvHgIZ8+mgS3edROY+xumLuSl46iOCl3ADPq9B X-Received: by 2002:a17:902:c7d1:b0:189:1a24:2865 with SMTP id r17-20020a170902c7d100b001891a242865mr19593152pla.18.1669367709228; Fri, 25 Nov 2022 01:15:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669367709; cv=none; d=google.com; s=arc-20160816; b=D8c3WKMHXYOFwauHq20tMM+zQ1d7Lu0n522S/Xh6WaZy+1YNrw82gsEcJ8IZZW88eg pyWa3Xm907tiAwNrUnJmElH26D/ORAfYi0bX306t9uNJLws+vMen07qoqvT81+MzYGln xMlCxQqR6inYOGN3ScetlGho9dkQ4x0u2vTH6HB6H0D+8Kw7ml07b3wo8xX7g03a4ZQR kJq1WKm9+WXkeOWVzfn2Q++D5iyuIyLslYSea78lv3CgMvQNYKe8gRoq3woedK9Zarmi EMP6tu0W42Wkgv4nM7+qexyErsAliF/xijHNYhKU217Q9+6Wti8GO+LtfcEEwcB761y6 TGSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=OFEaEjT5KSONgMYFWWvhw5bKxKSPNX5IN2pjVkckIMs=; b=ILC1PpFskRICOdvj/WLHNtFK9Q7rtJifydoG1xTI6XrPOJ+SKW8XMmk/25LATNZI5K gR+tKOxcl+eltvHPUo7iUghHaeDWC6Tu+EwSE5nBbGiCq1wQ2LP0al9VMW1w7AlOeh0J a33YmFWxDjug0eqSBvkTVwf/czi328yNM4d7nDC4bJq1XXtmVseLzJ6OBki4YjeNCLdK XoNndv4HiD68ZPVZbsDm79WMtLhzqF4GtOSuhYRlKhgPROhfqUGUrGHpI8QlB7v/tNgq Yf1QSwsnezwGKgllSWzDCVrpdBdHgm7tmCoYoAmxvDRcl8usm/rsGoSFtmwaxa/4HtCc TGtA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h9-20020a170902748900b0016cca53817dsi3078187pll.341.2022.11.25.01.14.51; Fri, 25 Nov 2022 01:15:08 -0800 (PST) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229741AbiKYJDW (ORCPT + 99 others); Fri, 25 Nov 2022 04:03:22 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50240 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229576AbiKYJDV (ORCPT ); Fri, 25 Nov 2022 04:03:21 -0500 Received: from formenos.hmeau.com (helcar.hmeau.com [216.24.177.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8548F31F98; Fri, 25 Nov 2022 01:03:18 -0800 (PST) Received: from loth.rohan.me.apana.org.au ([192.168.167.2]) by formenos.hmeau.com with smtp (Exim 4.94.2 #2 (Debian)) id 1oyUbu-000hD4-Kt; Fri, 25 Nov 2022 17:03:03 +0800 Received: by loth.rohan.me.apana.org.au (sSMTP sendmail emulation); Fri, 25 Nov 2022 17:03:02 +0800 Date: Fri, 25 Nov 2022 17:03:02 +0800 From: Herbert Xu To: Ard Biesheuvel Cc: "Jason A. Donenfeld" , Robert Elliott , davem@davemloft.net, tim.c.chen@linux.intel.com, ap420073@gmail.com, David.Laight@aculab.com, ebiggers@kernel.org, linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v4 10/24] crypto: x86/poly - limit FPU preemption Message-ID: References: <20221103042740.6556-1-elliott@hpe.com> <20221116041342.3841-1-elliott@hpe.com> <20221116041342.3841-11-elliott@hpe.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On Fri, Nov 25, 2022 at 09:59:17AM +0100, Ard Biesheuvel wrote: > > On arm64, this is implemented in an assembler macro 'cond_yield' so we > don't need to preserve/restore the SIMD state state at all if the > yield is not going to result in a call to schedule(). For example, the > SHA3 code keeps 400 bytes of state in registers, which we don't want > to save and reload unless needed. (5f6cb2e617681 'crypto: > arm64/sha512-ce - simplify NEON yield') Yes this would be optimally done from the assembly code which would make a difference if they benefited from larger block sizes. Cheers, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt