Skip to content

Commit

Permalink
Adds source for wasm gas costs
Browse files Browse the repository at this point in the history
  • Loading branch information
grarco committed Mar 20, 2024
1 parent d591d3c commit 937682f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion crates/namada/src/vm/wasm/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -613,7 +613,9 @@ impl wasm_instrument::gas_metering::Rules for GasRules {
) -> Option<u32> {
// NOTE: costs set to 0 don't actually trigger the injection of a call
// to the gas host function (no useless instructions are
// injected) NOTE: none of these costs should be zero
// injected)
// NOTE: these costs are taken from the benchmarks crate. None of them
// should be zero
let gas = match instruction {
Unreachable => 129_358,
// Just a flag, aribitrary cost of 1
Expand Down

0 comments on commit 937682f

Please sign in to comment.