- Status:
Brainstorm
Every time Bitswap receives a new block, it generates the CID from the payload of the block in order to verify that it belongs to a block it has in its wantlists. This means computing a lot of hash functions. This may involve a significant overhead.
Exploring more efficient implementation of hash functions, or alternative hash algorithms to fit different hardware architectures could remove an important overhead for Bitswap (and other modules from the IPFS ecosystem).
- Evaluate the overhead of hashing every block in Bitswap. This can be done by exchaching a large file and precompute the CIDs so computing the CID for every block is not needed.
- If we see that the overhead from hashing every block is significant, explore other hash functions and make a Bitswap implementation able to support other hash algorithms. Perform the same evalution from above and check the difference in the overhead.
- Reduction in the Bitswap protocol overhead. The protocol runs faster.
-
Measurement of the overhead for different file exchanges for different hash algorithms.