Merge pull request #2751 from filecoin-project/misc/windo-cheaper
Make VerifyPost cheaper
This commit is contained in:
commit
f9863f31fd
@ -197,7 +197,10 @@ func (pl *pricelistV0) OnVerifyPost(info abi.WindowPoStVerifyInfo) GasCharge {
|
|||||||
cost = pl.verifyPostLookup[abi.RegisteredPoStProof_StackedDrgWindow512MiBV1]
|
cost = pl.verifyPostLookup[abi.RegisteredPoStProof_StackedDrgWindow512MiBV1]
|
||||||
}
|
}
|
||||||
|
|
||||||
return newGasCharge("OnVerifyPost", cost.flat+int64(len(info.ChallengedSectors))*cost.scale, 0).
|
gasUsed := cost.flat + int64(len(info.ChallengedSectors))*cost.scale
|
||||||
|
gasUsed /= 2 // XXX: this is an artificial discount
|
||||||
|
|
||||||
|
return newGasCharge("OnVerifyPost", gasUsed, 0).
|
||||||
WithExtra(map[string]interface{}{
|
WithExtra(map[string]interface{}{
|
||||||
"type": sectorSize,
|
"type": sectorSize,
|
||||||
"size": len(info.ChallengedSectors),
|
"size": len(info.ChallengedSectors),
|
||||||
|
Loading…
Reference in New Issue
Block a user