gdb: snapshot restore breaks breakpoints
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Anfängerfreundlichkeit
- 45/100
- Issue-Typ
- Bug
- Klarheit
- Größtenteils klar
- Aktivitätsstatus
- Aktiv
- Tech-Stack
- rust
Rechercherichtung
Start with snapshot() and restore() in the host VM code, then trace how gdb breakpoint state is stored and reapplied. Compare the MSHV and WHP reset_vcpu paths with KVM's kvm_guest_debug handling, using the referenced x86_64.rs files and build.rs as entry points. Done means hardware and software breakpoints behave correctly across snapshot and restore, including when a listed breakpoint is removed afterward.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
- Hardware breakpoints are lost on MSHV and WHP. Those backends store gdb hardware breakpoints in the guest's DR0-DR7 (mshv/x86_64.rs#L853, whp/x86_64.rs#L1181).
reset_vcpuzeroes those registers (x86_64.rs#L327). gdb still lists the breakpoints. KVM keeps them inkvm_guest_debug, so they survive there. - Software breakpoints are written into snapshot memory. gdb builds make snapshot memory writable for this (build.rs#L162).
snapshot()captures the0xCCbytes. After restore nothing tracks them.restore()can remove a breakpoint thatsw_breakpointsstill lists. Removing it later writes the saved byte over whatever the restored snapshot holds at that address.
Possible fix: keep breakpoint state on the host and apply it again after restore(). Take software breakpoints out before snapshot().
- Vorherrschende Sprache
- Rust
- Sterne
- 4.8k
- Forks
- 223
- Ø Merge
- 1 T. 18 Std.
- Gemergte PRs (30 T.)
- 65
Entwicklungsumgebung
Startet den Dev-Container des Projekts im Browser, mit Ihrem eigenen GitHub-Konto.
- Kein Dockerfile und keine Docker-Compose-Datei
- Keine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus hyperlight-dev/hyperlight
-
A-api C-bug S-confirmed
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
hyperlight-dev/hyperlight#2135 ·
Maintainer antworten meist innerhalb von 1 Tag
-
C-bug S-confirmed
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
hyperlight-dev/hyperlight#2136 ·
Maintainer antworten meist innerhalb von 1 Tag
-
C-bug S-confirmed
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
hyperlight-dev/hyperlight#2132 ·
Maintainer antworten meist innerhalb von 1 Tag
-
C-bug S-confirmed
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 84/100
hyperlight-dev/hyperlight#2133 ·
Maintainer antworten meist innerhalb von 1 Tag
-
A-ci A-fuzzing C-bug S-confirmed
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
hyperlight-dev/hyperlight#2134 ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in hyperlight-dev/hyperlight
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 83/100
roc-lang/basic-webserver#277 ·
Maintainer antworten meist innerhalb von 1 Tag
-
enhancement
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
samkerrcode/opengent#113 ·
Maintainer antworten meist innerhalb von 1 Tag
-
app bug session
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
Maintainer antworten meist innerhalb von 1 Tag
-
bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 64/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
Maintainer antworten meist innerhalb von 1 Tag