Jason <jasonmoxham at btclick.com> writes: > > note this still may not be correct for all cases as > perhaps (cnt-GMP_NAIL_BITS)*e or bsize*e could overflow ? Yep, they could, for instance when e==ULONG_MAX. It'll need to be a two-limb calculation using umul_ppmm.