linux-crypto.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jihong Min <hurryman2212@gmail.com>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Christian Marangi <ansuelsmth@gmail.com>,
	linux-crypto@vger.kernel.org,
	"David S. Miller" <davem@davemloft.net>,
	Antoine Tenart <atenart@kernel.org>,
	linux-kernel@vger.kernel.org, Eric Biggers <ebiggers@kernel.org>
Subject: Re: [PATCH 0/4] crypto: introduce generic dynamic software fallback and EIP93 support
Date: Wed, 19 Aug 2026 17:05:43 +0900	[thread overview]
Message-ID: <f3cb693e-341d-4d4d-8eb5-45420dcca3e8@gmail.com> (raw)
In-Reply-To: <anmEDI6cQxS1wGtH@gondor.apana.org.au>

Hi,

On 8/10/26 16:55, Herbert Xu wrote:
> On Tue, Jul 28, 2026 at 05:43:28PM +0900, Jihong Min wrote:
>>
>> The tcrypt AES-128-CBC results are median cycles from five runs. Lower
>> is better. Disabled uses cbc(aes-eip93) directly, while enabled uses
>> fallback(cbc(aes-eip93)).
>>
>>   Request   Disabled   Enabled   Cycle reduction
>>    (bytes)   (cycles)  (cycles)
>>        16        322        18             94.4%
>>        64        274        43             84.3%
>>       128        292        74             74.7%
>>       256        312       138             55.8%
>>      1024        434       439             -1.2%
>>      1424        492       488              0.8%
>>      4096        980      1023             -4.4%
> 
> Do these results vary that much at run-time that requires a run-time
> test? Surely you can predict the outcome for the platforms involved?>
> It appears to me that you're simply adding complexity for something
> that can already be easily tuned by the administrator through the
> algorithm priorities.

Many crypto IP including EIP93 can have different host CPU performance.
This idea is directly from in-kernel raid6 module to dynamically
calculate this host CPU performance to set the boundaries.

> 
> In fact, why not implement the benchmark in user-space and then based
> on that result adjust the priorities?

The same reason why there is the kernel crypto API. It is a single point
(both AF_ALG and devcrypto) of entrance to each crypto device
implementation. It is best to control within them.

> 
> Cheers,


Sincerely,
Jihong Min

      reply	other threads:[~2026-08-19  8:05 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-28  8:43 [PATCH 0/4] crypto: introduce generic dynamic software fallback and EIP93 support Jihong Min
2026-07-28  8:43 ` [PATCH 1/4] crypto: move cycle benchmark helpers out of tcrypt Jihong Min
2026-07-28  8:43 ` [PATCH 2/4] crypto: introduce dynamic software fallback Jihong Min
2026-07-28  8:43 ` [PATCH 3/4] crypto: eip93 - add dynamic software fallback support Jihong Min
2026-07-28  8:43 ` [PATCH 4/4] crypto: eliminate fallback proxy overhead while disabled Jihong Min
2026-08-10  7:55 ` [PATCH 0/4] crypto: introduce generic dynamic software fallback and EIP93 support Herbert Xu
2026-08-19  8:05   ` Jihong Min [this message]

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=f3cb693e-341d-4d4d-8eb5-45420dcca3e8@gmail.com \
    --to=hurryman2212@gmail.com \
    --cc=ansuelsmth@gmail.com \
    --cc=atenart@kernel.org \
    --cc=davem@davemloft.net \
    --cc=ebiggers@kernel.org \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.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 NNTP newsgroup(s).