Go to the documentation of this file.
30 unsigned long long *
result);
32 const unsigned long long terms[],
const int n);
44 #define LL_MSW(x) (((unsigned long *)&x)[1])
47 #define MK_XSIG(a,b,c) { c, b, a }
50 #define XSIG_LL(x) (*(unsigned long long *)&x.midw)
62 static inline unsigned long mul_32_32(
const unsigned long arg1,
63 const unsigned long arg2)
66 asm volatile (
"mull %2; movl %%edx,%%eax":
"=a" (
retval)
73 static inline void add_Xsig_Xsig(
Xsig *
dest,
const Xsig *x2)
75 asm volatile (
"movl %1,%%edi; movl %2,%%esi;\n"
76 "movl (%%esi),%%eax; addl %%eax,(%%edi);\n"
77 "movl 4(%%esi),%%eax; adcl %%eax,4(%%edi);\n"
78 "movl 8(%%esi),%%eax; adcl %%eax,8(%%edi);\n":
"=g"
79 (*dest):
"g"(
dest),
"g"(x2)
87 static inline void add_two_Xsig(
Xsig *dest,
const Xsig *x2,
long int *
exp)
89 asm volatile (
"movl %2,%%ecx; movl %3,%%esi;\n"
90 "movl (%%esi),%%eax; addl %%eax,(%%ecx);\n"
91 "movl 4(%%esi),%%eax; adcl %%eax,4(%%ecx);\n"
92 "movl 8(%%esi),%%eax; adcl %%eax,8(%%ecx);\n"
94 "rcrl 8(%%ecx); rcrl 4(%%ecx); rcrl (%%ecx)\n"
95 "movl %4,%%ecx; incl (%%ecx)\n"
96 "movl $1,%%eax; jmp 1f;\n"
97 "0: xorl %%eax,%%eax;\n" "1:\n":
"=g" (*exp),
"=g"(*dest)
104 static inline void negate_Xsig(
Xsig *
x)
106 asm volatile (
"movl %1,%%esi;\n"
107 "xorl %%ecx,%%ecx;\n"
108 "movl %%ecx,%%eax; subl (%%esi),%%eax; movl %%eax,(%%esi);\n"
109 "movl %%ecx,%%eax; sbbl 4(%%esi),%%eax; movl %%eax,4(%%esi);\n"
110 "movl %%ecx,%%eax; sbbl 8(%%esi),%%eax; movl %%eax,8(%%esi);\n":
"=g"
111 (*x):
"g"(
x):
"si",
"ax",
"cx");