0xMiden / 0xMiden/miden-vm

feat(stark): implement StatefulBlake3Hasher

未关闭
#3,518 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
on hold starks
主要语言
Rust
星标
772
派生
352
平均合并
1 天 7 小时
30 天内合并 PR
84

描述

This is somewhat intentional and a conscious design decision motivated by the alignment property we get with sponge-based constructions.

The chaining hasher was meant as an easy compatibility layer for existing CryptographicHashers, which unfortunately does have different semantics, though hopefully not too big of a performance impact.

We should be able to define an actually custom StatefulBlake3Hasher using the `hazmat` API. I think this would be good to investigate if we notice a performance difference between the LMCS and MMCS. The trade off for better performance would be memory footprint (256 byte state vs 32 digest size) and unsafe-ish code manually implementing the hash.

But to answer your question, these are indeed semantically different Merkle trees, but from the caller of the MMCS/LMCS they're functionally the same. As mentioned above, this benchmark is actually useful for comparing the different approaches to absorbing rows of multiple matrices.

---

Ported from https://github.com/0xMiden/p3-miden/issues/63

贡献指南

打开贡献指南

调研方向

The issue discusses implementing a StatefulBlake3Hasher using the hazmat API for performance in Merkle tree constructions. Start by examining the existing CryptographicHasher implementations and the hazmat module. Look at the LMCS and MMCS code to understand the matrix absorption context. A successful implementation will need to manage a 256-byte state and integrate with the benchmark for comparison.

由索引模型根据 Issue 内容生成。

评估

技术栈
rust
领域
cryptography
Issue 类型
功能
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。