|
algebramix_doc 0.3
|
#include <polynomial_unrolled.hpp>
Definition at line 139 of file polynomial_unrolled.hpp.
Definition at line 140 of file polynomial_unrolled.hpp.
Definition at line 143 of file polynomial_unrolled.hpp.
References mmx::C, and mmx::quo().
{
// (s1, n1) contains the numerator on input and the remainder on output
// (s2, n2) contains the denominator. We assume n2>0 and s2[n2-1] != 0
// (dest, n1-n2+1) contains the quotient
while (n1 >= n2 && n1 != 0) {
int d= n1-n2;
C q= quo (s1[n1-1], s2[n2-1]);
dest[d]= q;
Vec::template vec_binary_scalar<mul_add_op,C,C,C> (s1 + d, s2, -q, n2);
n1--;
}
}