-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
explicitly note source of magic numbers in Hashing Limit section #29
Comments
Note from Calin:
|
The algorithm is also now detailed in |
The linkages are still not clear to me. To the point that I tried to write a normal-human readable explanation and wasn't totally confident about what I tried to write. For example for 64, do a ctrl-f and imagine the reader doesn't know everything in full detail. There are a handful of 64's spread all over the place. Which one is it? None of them? One of them? A few? Same for the |
The "Hashing Limit" section has a handful of unnamed, bare constants that I didn't find an explanation for:
((41 + unlocking_bytecode_length) * 7) / 2
1 + ((message_length + 8) / 64) + (is_double ? 1 : 0);
(the first 1+, not the conditional)Each of them deserves a name and/or explanation. In contrast, e.g. the numbers 41, 800 have explanations.
I can guess at or infer the source of them based on other parts of the spec, but I'm not totally confident about my inference. It should be in the spec even if it's explained here.
My guess is that 7 is a conservatively selected tuning number to match up with previous implicit limits.
1, 8 and 64 though... I dunno. I think 64 is explained in a note, but the linkage isn't explicit, at least not for someone with my level of knowledge.
The text was updated successfully, but these errors were encountered: