Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Dmitry Baryshkov
nettle
Commits
19f7da48
Commit
19f7da48
authored
Jul 02, 2014
by
Niels Möller
Browse files
Use mpz_submul_ui.
parent
02416dc7
Changes
2
Hide whitespace changes
Inline
Side-by-side
ChangeLog
View file @
19f7da48
2014-07-02 Niels Möller <nisse@lysator.liu.se>
* eccdata.c (ecc_dup): Use mpz_submul_ui, now available in
mini-gmp.
2014-06-30 Niels Möller <nisse@lysator.liu.se>
* camellia-absorb.c: Include <limits.h>, needed for correct use of
...
...
eccdata.c
View file @
19f7da48
...
...
@@ -151,9 +151,7 @@ ecc_dup (const struct ecc_curve *ecc,
/* x' = t^2 - 2 x */
mpz_mul
(
x
,
t
,
t
);
/* mpz_submul_ui (x, p->x, 2); not available in mini-gmp */
mpz_mul_ui
(
m
,
p
->
x
,
2
);
mpz_sub
(
x
,
x
,
m
);
mpz_submul_ui
(
x
,
p
->
x
,
2
);
mpz_mod
(
x
,
x
,
ecc
->
p
);
/* y' = (x - x') * t - y */
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment