8#include "../common/fp/avx2/fp-avx2.h"
10#include "../common/fp/gmp/fp-gmp.h"
12#include "../common/fp/mulx/fp.h"
22 fp_double2(&
A24->x, &A->z);
23 fp_double2(&
A24->z, (
const fp *)&
A24->x);
24 fp_add2(&
A24->x, &A->x);
29 fp_add3(&
P2->x, &
P->x, &
P->z);
31 fp_sub3(&
P2->z, &
P->x, &
P->z);
38 fp_sub3(&c, &
P2->x, &
P2->z);
40 fp_quadruple2(&b, &
P2->z);
42 fp_mul3(&b, &
A24->z, &
P2->z);
43 fp_mul3(&
Q->x, &
P2->x, (
const fp *)&b);
44 fp_mul3(&
a, (
const fp *)&c, &
A24->x);
45 fp_add2(&
a, (
const fp *)&b);
46 fp_mul3(&
Q->z, (
const fp *)&
a, (
const fp *)&c);
53 fp_add3(&
tmp0, &
P->x, &
P->z);
54 fp_sub3(&
tmp1, &
P->x, &
P->z);
55 fp_sq2(&
R->x, (
const fp *)&
tmp0);
56 fp_sub3(&
tmp2, &
Q->x, &
Q->z);
57 fp_add3(&
S->x, &
Q->x, &
Q->z);
59 fp_sq2(&
R->z, (
const fp *)&
tmp1);
60 fp_mul2(&
tmp1, (
const fp *)&
S->x);
61 fp_sub3(&
tmp2, (
const fp *)&
R->x, (
const fp *)&
R->z);
65 fp_mul2(&
R->z, &
A24->z);
66 fp_mul2(&
R->x, (
const fp *)&
R->z);
69 fp_add2(&
R->z, (
const fp *)&
S->x);
71 fp_mul2(&
R->z, (
const fp *)&
tmp2);
74 fp_mul2(&
S->z, &
PQ->x);
75 fp_mul2(&
S->x, &
PQ->z);
88 fp_add3(&
a, &
P->x, &
P->z);
89 fp_sub3(&b, &
P->x, &
P->z);
90 fp_add3(&c, &
Q->x, &
Q->z);
91 fp_sub3(&d, &
Q->x, &
Q->z);
92 fp_mul2(&
a, (
const fp *)&d);
93 fp_mul2(&b, (
const fp *)&c);
94 fp_add3(&c, (
const fp *)&
a, (
const fp *)&b);
95 fp_sub3(&d, (
const fp *)&
a, (
const fp *)&b);
98 fp_mul3(&
S->x, &
PQ->z, (
const fp *)&c);
99 fp_mul3(&
S->z, &
PQ->x, (
const fp *)&d);
132 proj_cswap(&
P1, &
P2, 1 - (
dac & 1));
207 fp_sq2(&x2, (
const fp *)x);
209 fp_mul3(&
x3, (
const fp *)&x2, (
const fp *)x);
233 fp_mul2(x, (
const fp *)&
ram0);
261 fp_sq2(&
PxPx, &
P->x);
263 fp_sq2(&
PzPz, &
P->z);
370 fp_sub2(&out[1], (
const fp *)&
v);
374 fp_sub2(&out[2], (
const fp *)&
v);
376 fp_add2(&out[2], (
const fp *)&
v);
379 fp_add2(&out[0], (
const fp *)&out[2]);
455 fp_double2(&
Aed.z, (
const fp *)&A->z);
458 fp_add3(&
Aed.x, (
const fp *)&A->x, (
const fp *)&
Aed.z);
464 fp_double2(&
A24.z, (
const fp *)&
Aed.z);
467 fp_sub3(&
Aed.z, (
const fp *)&A->x, (
const fp *)&
Aed.z);
553 else if (
s == 4 *
bs)
562 else if (
s == 6 *
bs)
572 else if (
s % (4 *
bs) == 2 *
bs)
635 fp_neg2(&
TI[2 *
i], (
const fp *)&
M[2 *
i + 1].x);
648 biquad_precompute_curve(
Aprecomp[
j], &
M[2 *
bs * (2 *
j + 1)], A);
700 fp_sub3(&
tmp4, (
const fp *)&
M[2 *
i + 2].x, (
const fp *)&
M[2 *
i + 2].z);
701 fp_add3(&
tmp3, (
const fp *)&
M[2 *
i + 2].x, (
const fp *)&
M[2 *
i + 2].z);
725 fp_sub3(&
tmp4, (
const fp *)&
M[1].x, (
const fp *)&
M[1].z);
726 fp_add3(&
tmp3, (
const fp *)&
M[1].x, (
const fp *)&
M[1].z);
743 fp_sub3(&
tmp4, (
const fp *)&
M[
i].x, (
const fp *)&
M[
i].z);
744 fp_add3(&
tmp3, (
const fp *)&
M[
i].x, (
const fp *)&
M[
i].z);
784 fp_add3(&A->x, (
const fp *)&
Aed.x, (
const fp *)&
Aed.z);
785 fp_sub3(&A->z, (
const fp *)&
Aed.x, (
const fp *)&
Aed.z);
802 fp_add3(&
Aed.z, (
const fp *)&A->z, (
const fp *)&A->z);
803 fp_add3(&
Aed.x, (
const fp *)&A->x, (
const fp *)&
Aed.z);
804 fp_sub3(&
Aed.z, (
const fp *)&A->x, (
const fp *)&
Aed.z);
806 fp_add3(&
Psum, (
const fp *)&
P->x, (
const fp *)&
P->z);
807 fp_sub3(&
Pdif, (
const fp *)&
P->x, (
const fp *)&
P->z);
809 fp_sub3(&
prod.x, &
K->x, &
K->z);
810 fp_add3(&
prod.z, &
K->x, &
K->z);
830 fp_sub3(&
tmp1, (
const fp *)&
M[
i].x, (
const fp *)&
M[
i].z);
831 fp_add3(&
tmp0, (
const fp *)&
M[
i].x, (
const fp *)&
M[
i].z);
837 fp_mul2(&
Q.x, (
const fp *)&
tmp2);
839 fp_mul2(&
Q.z, (
const fp *)&
tmp2);
845 fp_mul2(&
P->x, (
const fp *)&
Q.x);
846 fp_mul2(&
P->z, (
const fp *)&
Q.z);
849 exp_by_squaring_(&
Aed.x, &
Aed.z,
k);
864 fp_add3(&A->x, (
const fp *)&
Aed.x, (
const fp *)&
Aed.z);
865 fp_sub3(&A->z, (
const fp *)&
Aed.x, (
const fp *)&
Aed.z);
866 fp_add2(&A->x, (
const fp *)&A->x);
uint64_t fp[NUMBER_OF_WORDS]
#define poly_multieval_postcompute
#define poly_multiprod2_selfreciprocal
#define poly_multieval_precomputesize
#define poly_multieval_precompute