MCPcopy Create free account
hub / github.com/Tripwire/tripwire-open-source / LinearMultiply

Function LinearMultiply

src/cryptlib/integer.cpp:219–230  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

217}
218
219static word LinearMultiply(word *C, const word *A, word B, unsigned int N)
220{
221 word carry=0;
222 for(unsigned i=0; i<N; i++)
223 {
224 dword_union p;
225 p.dw = (dword)A[i] * B + carry;
226 C[i] = p.low;
227 carry = p.high;
228 }
229 return carry;
230}
231
232static void AtomicMultiply(word *C, word A0, word A1, word B0, word B1)
233{

Callers 2

AsymmetricMultiplyFunction · 0.85
CorrectQuotientEstimateFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected