The core protocol of WoopChain
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
woop/internal/params/gas_table.go

51 lines
1018 B

package params
8 months ago
// GasTable organizes gas prices for different woop phases.
type GasTable struct {
ExtcodeSize uint64
ExtcodeCopy uint64
ExtcodeHash uint64
Balance uint64
SLoad uint64
Calls uint64
Suicide uint64
ExpByte uint64
// CreateBySuicide occurs when the
// refunded account is one that does
// not exist. This logic is similar
// to call. May be left nil. Nil means
// not charged.
CreateBySuicide uint64
}
8 months ago
// Variables containing gas prices for different woop phases.
var (
// GasTableR3 contain the gas prices for
// the r3 phase.
GasTableR3 = GasTable{
ExtcodeSize: 20,
ExtcodeCopy: 20,
Balance: 20,
SLoad: 50,
Calls: 40,
Suicide: 0,
ExpByte: 10,
}
// GasTableS3 contain the gas re-prices for
// the s3 phase.
GasTableS3 = GasTable{
ExtcodeSize: 700,
ExtcodeCopy: 700,
ExtcodeHash: 400,
Balance: 400,
SLoad: 200,
Calls: 700,
Suicide: 5000,
ExpByte: 50,
CreateBySuicide: 25000,
}
)