MCPcopy Create free account
hub / github.com/JeanLucPons/VanitySearch / ModExp

Method ModExp

IntMod.cpp:571–584  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

569// ------------------------------------------------
570
571void Int::ModExp(Int *e) {
572
573 Int base(this);
574 SetInt32(1);
575 uint32_t i = 0;
576
577 uint32_t nbBit = e->GetBitLength();
578 for(int i=0;i<(int)nbBit;i++) {
579 if (e->GetBit(i))
580 ModMul(&base);
581 base.ModMul(&base);
582 }
583
584}
585
586// ------------------------------------------------
587

Callers 4

IsProbablePrimeMethod · 0.80
CheckMethod · 0.80
HasSqrtMethod · 0.80
ModSqrtMethod · 0.80

Calls 3

GetBitLengthMethod · 0.80
GetBitMethod · 0.80
ModMulMethod · 0.80

Tested by

no test coverage detected