linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Jason A. Donenfeld" <Jason@zx2c4.com>
To: "Theodore Ts'o" <tytso@mit.edu>,
	"Jason A. Donenfeld" <Jason@zx2c4.com>,
	LKML <linux-kernel@vger.kernel.org>,
	Hannes Frederic Sowa <hannes@stressinduktion.org>,
	Andy Lutomirski <luto@amacapital.net>
Subject: Re: [PATCH 1/2] random: use chacha20 for get_random_int/long
Date: Sat, 21 Jan 2017 01:16:56 +0100	[thread overview]
Message-ID: <CAHmME9p3xc6Q2Qu6kEP1O3PmvLKhpWcwjHfX8AQyibC0Quh65g@mail.gmail.com> (raw)
In-Reply-To: <20170121001509.fj23eunnkaqj7yce@thunk.org>

On Sat, Jan 21, 2017 at 1:15 AM, Theodore Ts'o <tytso@mit.edu> wrote:
> But there is a shared pointer, which is used both for the dedicated
> u32 array and the dedicated u64 array.  So when you increment the
> pointer for the get_random_u32, the corresponding entry in the u64
> array is wasted, no?

No, it is not a shared pointer. It is a different pointer with a
different batch. The idea is that each function gets its own batch.
That way there's always perfect alignment. This is why I'm suggesting
that my approach is faster.

Would you like me to roll your (slower) bitshifting idea as v2, or can
we stick with my v1?

Jason

  reply	other threads:[~2017-01-21  0:43 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-06 18:32 [PATCH 1/2] random: use chacha20 for get_random_int/long Jason A. Donenfeld
2017-01-06 18:32 ` [PATCH 2/2] random: convert get_random_int/long into get_random_u32/u64 Jason A. Donenfeld
2017-01-18  3:49 ` [PATCH 1/2] random: use chacha20 for get_random_int/long Theodore Ts'o
2017-01-20  5:27   ` Jason A. Donenfeld
2017-01-20 14:28     ` Theodore Ts'o
2017-01-20 15:38       ` Jason A. Donenfeld
2017-01-21  0:10         ` Theodore Ts'o
2017-01-21  0:13           ` Jason A. Donenfeld
2017-01-20 15:47       ` Jason A. Donenfeld
2017-01-21  0:15         ` Theodore Ts'o
2017-01-21  0:16           ` Jason A. Donenfeld [this message]
2017-01-21  6:24             ` Theodore Ts'o
2017-01-21 14:08               ` Jason A. Donenfeld
2017-01-22 11:24                 ` Greg Kroah-Hartman
2017-01-22 12:21                   ` Jason A. Donenfeld
2017-01-22 15:20                     ` Greg Kroah-Hartman
2017-01-22 15:34                       ` Jason A. Donenfeld
2017-01-22 15:34                         ` [PATCH 2/2] random: convert get_random_int/long into get_random_u32/u64 Jason A. Donenfeld
2017-01-22 22:28                       ` [PATCH 1/2] random: use chacha20 for get_random_int/long Theodore Ts'o
2017-01-22 22:49                         ` Jason A. Donenfeld
2017-01-23  0:33                           ` Theodore Ts'o
2017-01-23  8:12                         ` Greg Kroah-Hartman
  -- strict thread matches above, loose matches on Subject: below --
2016-12-22 18:07 Jason A. Donenfeld

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=CAHmME9p3xc6Q2Qu6kEP1O3PmvLKhpWcwjHfX8AQyibC0Quh65g@mail.gmail.com \
    --to=jason@zx2c4.com \
    --cc=hannes@stressinduktion.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luto@amacapital.net \
    --cc=tytso@mit.edu \
    /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).