0xMiden / 0xMiden/miden-vm

feat(stark): add support for constraint tracking

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

描述

We should add support for naming/tagging constraints in the AirBuilder to improve debugging. When a constraint fails, the debug builder currently reports only `"constraint not satisfied at instance {i}, row {r}"` with no indication of which logical rule was violated.

### Upstream work

- https://github.com/Plonky3/Plonky3/pull/1431 adds `NamedAirBuilder` and related debugging improvements
- https://github.com/0xMiden/miden-vm/pull/2856 refactors the Miden VM's constraint tagging approach (replaces the earlier PR #2713)

### Goals

- [ ] Integrate with Plonky3's `NamedAirBuilder` from https://github.com/Plonky3/Plonky3/pull/1431
- [ ] Improve the debug builder in `debug.rs` to report constraint names on failure
- [ ] Ensure zero overhead in production builds

---

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

贡献指南

打开贡献指南

调研方向

The issue involves integrating Plonky3's NamedAirBuilder from the linked PR. Start by reading the debug.rs file to understand current constraint reporting. Examine the upstream PRs to see how constraint tagging is implemented. The goal is to modify the AirBuilder to support naming constraints and update the debug builder to report these names on failure, ensuring no performance impact in production.

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

评估

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

把新 issue 发到你的邮箱

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