ref-fvm icon indicating copy to clipboard operation
ref-fvm copied to clipboard

FVM: Pick page config params

Open arajasek opened this issue 3 years ago • 3 comments

We need a good number of initial and max pages that can absolutely 100% run any Filecoin message, but also doesn't gobble up too much memory. Experimenting with mainnet state is probably a good start pointe.

arajasek avatar Jan 14 '22 18:01 arajasek

I think @raulk had some thoughts on initial values here.

cryptonemo avatar Jan 14 '22 18:01 cryptonemo

For M1 (nv16), we are going with unlimited max pages given that the system can only run trusted logic via builtin system actors. However, it's not clear how many initial pages should be to avoid excessive memory expansion operations. Opened #369 to track that.

@Stebalien will your benchmarks yield a good value for initial pages?

For M2, there's a proposal here: https://github.com/filecoin-project/FIPs/pull/317.

raulk avatar Mar 09 '22 15:03 raulk

Need to resurrect this issue for M2.1 (FEVM). In discussions over time we have settled on not charging for memory allocated, but rather for memory expansions. Finding the gas value/formula to charge per expansion will be subject of upcoming work, but for now we should at least set a max pages to a reasonable value (in the past we've discussed 64MiB, 256MiB, or 512MiB, IIRC).

raulk avatar Sep 08 '22 18:09 raulk

We're sticking with 2GiB for now. Pending FIP.

Stebalien avatar Dec 09 '22 16:12 Stebalien