From 6b016a888116a12909412a0abf945d5ece4e1ba1 Mon Sep 17 00:00:00 2001 From: samkim-crypto Date: Thu, 12 Jan 2023 08:40:27 +0900 Subject: [PATCH] [curve25519 syscalls] update compute costs (#29610) * update curve25519 syscall compute costs * update msm compute costs --- program-runtime/src/compute_budget.rs | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/program-runtime/src/compute_budget.rs b/program-runtime/src/compute_budget.rs index 47bdd01522..249227656c 100644 --- a/program-runtime/src/compute_budget.rs +++ b/program-runtime/src/compute_budget.rs @@ -165,18 +165,18 @@ impl ComputeBudget { sysvar_base_cost: 100, secp256k1_recover_cost: 25_000, syscall_base_cost: 100, - curve25519_edwards_validate_point_cost: 111, - curve25519_edwards_add_cost: 331, - curve25519_edwards_subtract_cost: 329, - curve25519_edwards_multiply_cost: 1_753, - curve25519_edwards_msm_base_cost: 1_870, - curve25519_edwards_msm_incremental_cost: 670, - curve25519_ristretto_validate_point_cost: 117, - curve25519_ristretto_add_cost: 367, - curve25519_ristretto_subtract_cost: 366, - curve25519_ristretto_multiply_cost: 1_804, - curve25519_ristretto_msm_base_cost: 1_870, - curve25519_ristretto_msm_incremental_cost: 670, + curve25519_edwards_validate_point_cost: 159, + curve25519_edwards_add_cost: 473, + curve25519_edwards_subtract_cost: 475, + curve25519_edwards_multiply_cost: 2_177, + curve25519_edwards_msm_base_cost: 2_273, + curve25519_edwards_msm_incremental_cost: 758, + curve25519_ristretto_validate_point_cost: 169, + curve25519_ristretto_add_cost: 521, + curve25519_ristretto_subtract_cost: 519, + curve25519_ristretto_multiply_cost: 2_208, + curve25519_ristretto_msm_base_cost: 2303, + curve25519_ristretto_msm_incremental_cost: 788, heap_size: None, heap_cost: 8, mem_op_base_cost: 10,