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

Machine-dependent use of n_precomp functions #2183

Open
fredrik-johansson opened this issue Jan 24, 2025 · 1 comment
Open

Machine-dependent use of n_precomp functions #2183

fredrik-johansson opened this issue Jan 24, 2025 · 1 comment

Comments

@fredrik-johansson
Copy link
Collaborator

On my machine n_*_preinv functions are often faster than the n_*_precomp versions, e.g. a 54-bit primality test is faster than a 52-bit one because of this.

We ought to profile these on various current machines and choose the precomp functions conditionally based a flag that we define in flint-mparam.h.

@fredrik-johansson
Copy link
Collaborator Author

One could also see if the precomp versions run faster when reimplemented using floating-point FMA. However, keeping residues in double format through a whole algorithm as in fft_small ought to be better than converting back and forth between ulong and double.

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