# EPF6 - Week 16&17 Updates ## Summary 1. Finished [PR #15805](https://github.com/OffchainLabs/prysm/pull/15805) 2. Added [PR #15873](https://github.com/OffchainLabs/prysm/pull/15873). ## Details ### 1. SSZ-QL: use FastSSZ-generated HashTreeRoot through SSZObject in sszInfo #15805 In this PR, we discard the previous [PR](https://github.com/OffchainLabs/prysm/pull/15669) to compute the HashTreeRoot with recursion in favor of using the already battle tested FastSSZ library. To do so, it is introduce a new type called `SSZObject`: ```golang type SSZObject interface { HashTreeRoot() ([32]byte, error) } ``` This "generic" name is chosen on purpose as this interface will be extended with different functions from FastSSZ. The approach is very straighforward. At the moment of analyzing the object in SSZ-QL, we store the original object, providing us with Fastssz's HashTreeRoot implementation of each types. ### 2. SSZ-QL: calculate generalized indices for elements This PR is under review currently and it is onboarding the feedback into it. Since we are relying on battle tested FastSSZ for the HashTreeRoot, we are following the same approach for the Merkle (multi)proofs. We basically need to parse the specified paths into generalized indices as FastSSZ consumes them: ```golang // Prove returns a list of sibling values and hashes needed // to compute the root hash for a given general index. func (n *Node) Prove(index int) (*Proof, error) { pathLen := getPathLength(index) proof := &Proof{Index: index} hashes := make([][]byte, 0, pathLen) (...) func (n *Node) ProveMulti(indices []int) (*Multiproof, error) { reqIndices := getRequiredIndices(indices) proof := &Multiproof{Indices: indices, Leaves: make([][]byte, len(indices)), Hashes: make([][]byte, len(reqIndices))} (...) ``` This PR contains the logic to compute the Generalized Index of any path (except from specific items in multi-dimensional arrays). ### Next steps - Integrate Fastssz merkle proofs.