Closed i-norden closed 2 years ago
Roy has made these changes and more here: https://github.com/vulcanize/smt/pull/5
As seen the new flame charts he has produced, most the time is now being spent hashing so a new line of consideration should be to investigate using faster hash functions.
Another thing to consider is to introduce the concept of an intermediate node to the SMT, analogous to how the MMPT modified the normal patricia trie.
Upstreamed SMT updates: https://github.com/celestiaorg/smt/pull/73
The main task that was remaining was to test in a meaningful environment, e.g. https://github.com/vulcanize/cosmos-sdk/issues/26
IAVL vs SMT
Optimizations relative to IAVL:
The other optimization work is to optimize the SMT implementation, brining it up to speed with IAVL:
Concrete tasks:
At the implementation level, look into:
hash(key) => value
mapping and rely on B1 bucket at SDK layerRelated hackmd: https://hackmd.io/pESkHH3aQhugMLpGH2pBzw