spacemeshos / svm

SVM - Spacemesh Virtual Machine
https://spacemesh.io
MIT License
85 stars 14 forks source link

Update the encoding of transactions and replace `svm-codec` with SSZ #493

Open neysofu opened 2 years ago

neysofu commented 2 years ago

We are planning on replacing the encoding internally used by SVM both for storage and on-wire entities representation with SZZ. This change would:

SSZ would thus be used to encode:

  1. Template sections.
  2. Transaction execution receipts.
  3. Transaction contents.

(1) and (2) are mostly implementation details, and changing the encoding doesn't have ripple effects across the whole stack. On the other hand, (3) transaction syntax is extremely delicate and it needs to evaluted carefully. A the time of writing, a detailed SMIP documenting the proposed transaction syntax with SSZ is not available, but there is some promising work done by @noamnelke and @lrettig in this regard. See https://docs.google.com/spreadsheets/d/1JjKL9GgYTgNRM_qrkCcpxGeSUnwuhOeTC0dfn16ivHM/edit#gid=1073868340 for more information.

neysofu commented 2 years ago

This issue supersedes https://github.com/spacemeshos/svm/issues/485.

neysofu commented 2 years ago

See https://github.com/spacemeshos/SMIPS/issues/58 for details about how transaction receipts are currently encoded.