commit 2c182b701fcbbbbea04ce3b9fd14e0bbafb4083c parent f1ab44abe2f24f01ef09312c9f962c6f3666b5fe Author: Jared Tobin <jared@jtobin.io> Date: Fri, 14 Mar 2025 14:14:11 +0400 bench: add weigh case Diffstat:
M | bench/Weight.hs | | | 10 | ++++++++++ |
1 file changed, 10 insertions(+), 0 deletions(-)
diff --git a/bench/Weight.hs b/bench/Weight.hs @@ -33,6 +33,7 @@ main = W.mainWith $ do derive_pub schnorr ecdsa + ecdh remQ :: W.Weigh () remQ = W.wgroup "remQ" $ do @@ -97,6 +98,15 @@ ecdsa = W.wgroup "ecdsa" $ do msg = "i approve of this message" sig = S.sign_ecdsa big s_msg +ecdh :: W.Weigh () +ecdh = W.wgroup "ecdh" $ do + W.func "ecdh (small)" (S.ecdh pub) 2 + W.func "ecdh (large)" (S.ecdh pub) b + where + b = 0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffed + Just pub = S.parse_point . B16.decodeLenient $ + "bd02b9dfc8ef760708950bd972f2dc244893b61b6b46c3b19be1b2da7b034ac5" + s_sk :: Integer s_sk = S.parse_int256 . B16.decodeLenient $ "B7E151628AED2A6ABF7158809CF4F3C762E7160F38B4DA56A784D9045190CFEF"