Skip to content
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

Questions on Ryu algorithm #202

Open
zejal opened this issue Sep 3, 2021 · 0 comments
Open

Questions on Ryu algorithm #202

zejal opened this issue Sep 3, 2021 · 0 comments

Comments

@zejal
Copy link

zejal commented Sep 3, 2021

I am trying to take a grasp on how Ryu algorithm reading your publication in 2018 (https://doi.org/10.1145/3192366.3192369) and reading also code you published in GitHub.

There a couple of things I do not understand from the article related to how q is set. In lemma 3.2, it is mentionned that q is set to :
For e2 < 0, choose q = ⌊−e2 log10 5⌋.
But later on in lemma 3.4 and steps 0 and 3’, article reads : q as max (0, ⌊−e2 log5 2⌋ − 1)

Ryu implementation also uses log10 5

// This expression is slightly faster than max(0, log10Pow5(-e2) - 1).
const uint32_t q = log10Pow5(-e2) - (-e2 > 1);

so it is not clear to me why there is this difference between article and implementation.

Rather minor, it seems to me that captions for 2 figures in left column in page 278 are inverted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant