func benchDouble(curve elliptic.Curve, n int) { x := curve.Params().Gx y := curve.Params().Gy for i := 0; i < n; i++ { curve.Double(x, y) } }
func testDoubleAndAdd(curve elliptic.Curve, x1, y1, ex, ey *big.Int) bool { x, y := curve.Double(x1, y1) x, y = curve.Add(x, y, x1, y1) return x.Cmp(ex) == 0 && y.Cmp(ey) == 0 }