fork quiesce barrier can be bypassed
Les mainteneurs répondent en général sous 2 jours
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Accessibilité débutants
- 48/100
- Type d'issue
- Bug
- Clarté
- Clairement spécifiée
- Activité
- Active
- Stack technique
- c, macos
- Domaine
- backend, operating-systems
Piste de recherche
Start with thread_quiesce_siblings and thread_fork_barrier_check, then read src/syscall/proc.c around handle_canceled and the thread_exec_de_thread comment. Trace the exit and run-loop paths for each described kick timing, plus the case where a sibling remains parked across fork windows. Done means siblings reliably park before snapshots and back-to-back forks no longer wait for the 100 ms timeout.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
fork quiesce barrier can be bypassed, so the snapshot runs beside a live sibling
thread_quiesce_siblings kicks every sibling with hv_vcpus_exit and waits up to 100 ms for each to reach thread_fork_barrier_check. That check only runs in the CANCELED exit handler (src/syscall/proc.c, handle_canceled), so a kicked sibling can return to guest code without parking:
- The kick lands while the sibling is in a host syscall. As the thread_exec_de_thread comment notes, such a kick is lost, and the run loop top has no fork check before hv_vcpu_run.
- The kick lands at EL1, and the handler returns VCPU_RESUME before the barrier.
- A signal is pending, and the handler delivers it and returns VCPU_RESUME before the barrier.
The forker then times out and takes the snapshot while that sibling keeps running guest code, although the barrier comment says the quiet is load-bearing.
Reproduction: one sibling loops on nanosleep(200us) while the main thread calls fork() repeatedly and times each call (macOS 15.4.1, Apple M4, median of 21):
sibling in compute loop: fork() 13 ms
sibling in nanosleep loop: fork() 112 ms (every fork hits the 100 ms timeout)
A smaller issue in the same code: if a sibling is still parked from the previous fork window, it is counted again when the next one arms and never answers, so back-to-back forks each pay the 100 ms timeout.
- Langage dominant
- C
- Étoiles
- 287
- Forks
- 33
- Merge moyen
- 2 j 17 h
- PR mergées (30 j)
- 18
Préparer son environnement
- Aucun Dockerfile ni fichier Docker Compose
- Aucun modèle de pull request
- Lire le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de sysprog21/elfuse
-
Difficulté 2/5 1-3 heures Accessibilité débutants 64/100
Les mainteneurs répondent en général sous 2 jours
-
Difficulté 1/5 Moins d'une heure Accessibilité débutants 80/100
Les mainteneurs répondent en général sous 2 jours
-
bug
Difficulté 2/5 1-3 heures Accessibilité débutants 86/100
Les mainteneurs répondent en général sous 2 jours
-
bug
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
Les mainteneurs répondent en général sous 2 jours
-
bug
Difficulté 2/5 1-3 heures Accessibilité débutants 75/100
Les mainteneurs répondent en général sous 2 jours
Toutes les issues de sysprog21/elfuse
Issues similaires
-
Difficulté 2/5 1-3 heures Accessibilité débutants 70/100
libreswan/libreswan#3185 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 70/100
-
[SDL3pp] update to 0.12.0Ouvertecategory:port-update
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
Les mainteneurs répondent en général sous 2 jours
-
[InstCombine] 23.x folds 0.0 * (0.0 / x) to 0.0 when x may be zero (fixed on main by #202482)Ouvertellvm:instcombine
Difficulté 2/5 1-3 heures Accessibilité débutants 64/100
llvm/llvm-project#246503 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 85/100
Les mainteneurs répondent en général sous 1 jour