You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, issuance per layer is calculated dynamically every time the methods in this library are called. This is not ideal since the math is expensive and could, in theory, involve rounding errors on different architectures. Also reimplementing precisely the same math in a different language won't be trivial. (See spacemeshos/go-spacemesh#4268)
One easy fix here is to change this library to use lookup tables rather than recalculating per-layer issuance on demand. We could run a tool like the sim.go script here and generate a lookup table with the final per-layer issuance for an arbitrary number of layers and use that as the canonical issuance instead.
The size of such a table for the first ten years of issuance would be approximately [20 bits (layer ID) + 39 bits (layer subsidy)] * 1051200 layers =~ 8mb.
The text was updated successfully, but these errors were encountered:
Right now, issuance per layer is calculated dynamically every time the methods in this library are called. This is not ideal since the math is expensive and could, in theory, involve rounding errors on different architectures. Also reimplementing precisely the same math in a different language won't be trivial. (See spacemeshos/go-spacemesh#4268)
One easy fix here is to change this library to use lookup tables rather than recalculating per-layer issuance on demand. We could run a tool like the
sim.go
script here and generate a lookup table with the final per-layer issuance for an arbitrary number of layers and use that as the canonical issuance instead.The size of such a table for the first ten years of issuance would be approximately [20 bits (layer ID) + 39 bits (layer subsidy)] * 1051200 layers =~ 8mb.
The text was updated successfully, but these errors were encountered: