Skip to content

Commit b83a795

Browse files
committed
change op gas cost to match cosmwasm & change version
1 parent b6afab5 commit b83a795

File tree

3 files changed

+5
-4
lines changed

3 files changed

+5
-4
lines changed

packages/vm/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "owasm-vm"
3-
version = "0.1.12"
3+
version = "0.2.0"
44
authors = ["Band Protocol <[email protected]>"]
55
edition = "2021"
66
license = "Apache-2.0"

packages/vm/src/calls.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ mod test {
144144
let mut cache = Cache::new(CacheOptions { cache_size: 10000 });
145145
let env = MockEnv {};
146146
let gas_used = run(&mut cache, &code, u64::MAX, true, env).unwrap();
147-
assert_eq!(gas_used, 800013 as u64);
147+
assert_eq!(gas_used, 2000032500000 as u64);
148148
}
149149

150150
#[test]
@@ -182,7 +182,7 @@ mod test {
182182
let mut cache = Cache::new(CacheOptions { cache_size: 10000 });
183183
let env = MockEnv {};
184184
let gas_used = run(&mut cache, &code, u64::MAX, true, env).unwrap();
185-
assert_eq!(gas_used, 800018 as u64);
185+
assert_eq!(gas_used, 2000045000000 as u64);
186186
}
187187

188188
#[test]

packages/vm/src/store.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ use wasmer_middlewares::Metering;
66

77
fn cost(_operator: &Operator) -> u64 {
88
// A flat fee for each operation
9-
1
9+
// The target is 1 Teragas per millisecond
10+
2_500_000
1011
}
1112

1213
pub fn make_store() -> Store {

0 commit comments

Comments
 (0)