From: "Jason A. Donenfeld" <Jason@zx2c4.com>
To: Eric Biggers <ebiggers@kernel.org>
Cc: Linux Crypto Mailing List <linux-crypto@vger.kernel.org>,
Herbert Xu <herbert@gondor.apana.org.au>
Subject: Re: [PATCH crypto-next v2 1/3] crypto: poly1305 - add new 32 and 64-bit generic versions
Date: Sat, 14 Dec 2019 14:05:10 +0100 [thread overview]
Message-ID: <CAHmME9p-dBVbCBoX+p4n3meC5n_GjCuZgMiUfUqG2-G-wqLbyQ@mail.gmail.com> (raw)
In-Reply-To: <20191213032849.GC1109@sol.localdomain>
Hi Eric,
On Fri, Dec 13, 2019 at 4:28 AM Eric Biggers <ebiggers@kernel.org> wrote:
> Now, it's possible that the performance gain outweighs this, and I too would
> like to have the C implementation of Poly1305 be faster. So if you'd like to
> argue for the performance gain, fine, and if there's a significant performance
> gain I don't have an objection. But I'm not sure why you're at the same time
> trying to argue that *adding* an extra implementation somehow makes the code
> easier to audit and doesn't add complexity...
Sorry, I don't mean to be confusing, but I clearly haven't written
very well. There are two things being discussed here, 32-bit and
64-bit, rather than just one. Let me clarify:
- The motivation for the 64-bit version is primarily performance. Its
performance isn't really in dispute. It's significant and good. I'll
put this in the commit message of the next series I send out.
- The motivation for the 32-bit version is primarily to have code that
can be compared line by line to the 64-bit version, in order to make
auditing easier given the situation with two implementations and also
for general cleanliness. I think there's enormous value in having the
other implementation be "parallel". Rather than two totally different
and foreign implementations, we have two related and comparable ones.
That's a good thing. As a *side note*, it might also be slightly
faster than the one it replaces, which is great and all I guess, but
not the primary motivation of the 32-bit version.
Does that make sense? That's why I appear to simultaneously be arguing
that performance matters and doesn't matter. The motivation for the
64-bit version is performance. The motivation for the 32-bit version
is cleanliness. Two things, which are related.
I'll make this clear in the commit message of the next series I send.
Sorry again for being confusing.
Jason
prev parent reply other threads:[~2019-12-14 13:05 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-11 17:09 [PATCH crypto-next v1] crypto: poly1305 - add new 32 and 64-bit generic versions Jason A. Donenfeld
2019-12-11 19:06 ` Eric Biggers
2019-12-11 22:04 ` Jason A. Donenfeld
2019-12-12 9:30 ` [PATCH crypto-next v2 1/3] " Jason A. Donenfeld
2019-12-12 9:30 ` [PATCH crypto-next v2 2/3] crypto: x86_64/poly1305 - add faster implementations Jason A. Donenfeld
2019-12-12 10:26 ` Jason A. Donenfeld
2019-12-12 15:34 ` Martin Willi
2019-12-12 15:39 ` Jason A. Donenfeld
2019-12-15 17:04 ` Andy Polyakov
2019-12-12 9:30 ` [PATCH crypto-next v2 3/3] crypto: arm/arm64/mips/poly1305 - remove redundant non-reduction from emit Jason A. Donenfeld
2019-12-12 14:59 ` Ard Biesheuvel
2019-12-12 12:03 ` [PATCH crypto-next v2 1/3] crypto: poly1305 - add new 32 and 64-bit generic versions Martin Willi
2019-12-12 13:08 ` Jason A. Donenfeld
2019-12-12 13:46 ` Jason A. Donenfeld
2019-12-12 14:26 ` Ard Biesheuvel
2019-12-12 14:30 ` Jason A. Donenfeld
2019-12-12 15:30 ` Martin Willi
2019-12-12 15:35 ` Jason A. Donenfeld
2019-12-13 3:28 ` Eric Biggers
2019-12-14 8:56 ` Herbert Xu
2019-12-14 12:21 ` Jason A. Donenfeld
2019-12-14 13:05 ` Jason A. Donenfeld [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=CAHmME9p-dBVbCBoX+p4n3meC5n_GjCuZgMiUfUqG2-G-wqLbyQ@mail.gmail.com \
--to=jason@zx2c4.com \
--cc=ebiggers@kernel.org \
--cc=herbert@gondor.apana.org.au \
--cc=linux-crypto@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).