Commit 7f8a7a8
Merge #4182
4182: Replace delta view with spockState and storageState r=pattyshack a=pattyshack
Changes relative to delta view:
- encode operation type as part of spock hash. This prevents operation substitution / omission. In particular, the original implementation generate identical hashes for:
1. Get(registerId) and Set(registerId, "")
2. with vs without DropChanges()
- encode register id / value length as part of spock hash to guard against string injection attack
- the spock mutex in delta view is no longer needed. Result collector refactoring + explicit finalized execution snapshots eliminated the accidential data race.
- spockState is no longer accessible once Finalize is called. We can't safely support mutation after Finalize since the SumHash is not idempotent.
- storageState keeps track of the read (from the underlying storage) set rather than the touch set. Note that the touch set can be constructed from the read and write sets (e.g., execution snapshot's AllRegisterIDs), but not vice versa.
Co-authored-by: Patrick Lee <[email protected]>File tree
11 files changed
+986
-939
lines changed- engine/execution/state/delta
- fvm
- state
- storage/testutils
11 files changed
+986
-939
lines changedThis file was deleted.
This file was deleted.
0 commit comments