[rand.eng.philox] Make the round states explicit.#7152
[rand.eng.philox] Make the round states explicit.#7152tkoeppe wants to merge 1 commit intocplusplus:mainfrom
Conversation
|
@villevoutilainen, @iburyl, PTAL? |
|
This looks so non-editorial to me that it isn't even funny. :D |
|
@villevoutilainen: Hm :-) Do you think this changes the normative content? Which part specifically? |
|
@tkoeppe I don't want to figure out whether it does change the normative content, and if so, how. I want LWG to do that. |
|
Got it, thanks! |
|
My problem with this change is that X is now being used
Also not sure why q is being used with parenthesis for V and X and without for key. |
|
Right. The change is a spec revamp. While I have the utmost confidence that @tkoeppe can do it correctly, this sort of changes are in principle something that the spec review group, in this case, LWG, needs to ack. |
|
To be clear:
The upper index in parentheses numbers the rounds, and writing it in parentheses is a not too uncommon style to make it easier to distinguish this kind of "family index" from, say, an exponent. It's ultimately just another sequence index, but into a different kind of sequence (namely the sequence of rounds). |
What I find unclear in the approved wording is what the result of One could argue further that the term "$r$-round substitution-permutation network" isn't defined :-) |
|
My point re paranthesis was, if we start using that for X and V, they should also be used for the key. Now usage is inconsistent. |
OK, sure, we can either drop the parentheses, or also write |
I can agree with that, but it is more a light reference to the original paper rather than something really used in the definition. This sentence can be removed without changing the algorithm definition. Currently it is defined as:
"single round of the generation algorithm" and "single-round function" could probably be called more consistently though. |
|
Yes, indeed, what is a "round", and why is there a "first round", etc. etc. I think "$r$-round network" is a good evocative name after the fact, but the name alone doesn't mean anything. In maths you should generally say what something is, and then you can give it a name for later reference. But names don't make meaning. We can also use a totally different symbol instead of Oh, by the way, note that the drafting directives forbid multiletter variable names, so we'll probably have to do something about |
I would definitely call into question what the result of |
|
Looking into compiled preview it does seem rather readable and several versions of X are not too confusing. |
|
Bullet list:
Since everything around became singular...
|
|
Other than that looks ok for me. But as @villevoutilainen said, there should be some bless from LWG on that change. |
Yes, good call, done. I might even apply this change separately already, since ISO will require the renaming anyway.
Yes, indeed, but I wanted to get some sense of agreement first and flesh out the details -- thanks! |
|
I'll update this now that all your fixes have gone in. |
|
It sounds reasonable to me to open an LWG issue. |
|
I agree |
|
Thanks, will do! @Dani-Hub, how would you like me to describe the proposed wording in the email? Would a link to this PR suffice, or shoudl I transcribe it? |
A link would suffice, maybe you could add some introductory words |
|
Of course, yes, I was just asking about the wording! (The intro will be shamelessly copied from the this PR, of course, but I'll handle that.) |
Oh yes, a link is sufficient |
|
@Dani-Hub Looks good, thank you! |
This clarifies which state is the final result, and avoids the use of
the vaguely defined variable $X'$. It changes the index variable $q$
to be 1-based. The single sequence $V$ is replaced with the sequence
of sequences $V^{(q)}$.
We also rename $\mathit{key}^q_k$ to $K^{(q)}_{k}$, since ISO requires
that variable names consist of only a single letter. This creates a
nice parallel between $X$/$X^{(q)}$ and $K$/$K^{(q)}$.



This clarifies which state is the final result, and avoids the use of the vaguely defined variable$X'$ . It changes the index variable $q$ to be 1-based. The single sequence $V$ is replaced with the sequence of sequences $V^{(q)}$ .
Currently, the definition of the "r-round network", "rounds", and how they fit together, is somewhat informal and imprecise. In particular, the statement that$Y = X'$ " is needlessly ambiguous.
Philox"returns the sequenceIt would be clearer if all involved mathematical entities and operations were clearly spelled out.
Preview: