0xMiden / 0xMiden/miden-debug

Track call frames using VM debug metadata

Offen
#109 1 Kommentar 0 Reaktionen 1 zugewiesene Person Beansprucht von @djolertrk Auf GitHub ansehen
Vorherrschende Sprache
Rust
Sterne
1
Forks
8
Ø Merge
2 T. 13 Std.
Gemergte PRs (30 T.)
16

Beschreibung

The debugger currently relies on runtime events to detect function entry and exit. This is fragile because events may be missing or delayed, and they add unnecessary work to normal execution.

We should extend Miden VM package debug information with compact source call-frame ranges. The debugger can inspect the current execution context and reconstruct the active physical call stack directly from those ranges. Expired ranges naturally remove frames, while newly active ranges add them.

This should work for nested calls, recursion, linked packages, and instruction padding without adding overhead to the Processor’s normal execution path. Inline frames remain separate and continue using inline-call metadata.

The result should be consistent backtraces in both the REPL/TUI and DAP without requiring compiler-emitted frame start/end events.

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

The issue describes extending the Miden VM package debug information. Start by examining the existing debug metadata structures in the codebase, likely in the `miden-debug` crate. Look for how runtime events are currently handled and where call frames are tracked. The goal is to add source call-frame ranges to the metadata and modify the debugger to reconstruct the stack from these ranges. Testing will involve nested calls, recursion, and linked packages to ensure backtraces are consistent in the REPL/TUI and DAP without frame events.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
rust
Bereich
devtools
Issue-Typ
Feature
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Ruhig
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
45/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.