fork quiesce barrier can be bypassed
Mantenedores costumam responder em até 2 dias
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Facilidade para iniciantes
- 48/100
- Tipo de issue
- Bug
- Clareza
- Claramente especificada
- Status de atividade
- Ativa
- Stack de tecnologia
- c, macos
- Domínio
- backend, operating-systems
Direção de pesquisa
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.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
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.
- Linguagem predominante
- C
- Estrelas
- 287
- Forks
- 33
- Merge médio
- 2d 17h
- PRs com merge (30d)
- 18
Preparar o ambiente
- Sem Dockerfile nem arquivo Docker Compose
- Sem modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de sysprog21/elfuse
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 64/100
Mantenedores costumam responder em até 2 dias
-
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 80/100
Mantenedores costumam responder em até 2 dias
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 86/100
Mantenedores costumam responder em até 2 dias
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
Mantenedores costumam responder em até 2 dias
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 75/100
Mantenedores costumam responder em até 2 dias
Todas as issues de sysprog21/elfuse
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 70/100
libreswan/libreswan#3185 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 70/100
-
[SDL3pp] update to 0.12.0Abertacategory:port-update
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
Mantenedores costumam responder em até 2 dias
-
[InstCombine] 23.x folds 0.0 * (0.0 / x) to 0.0 when x may be zero (fixed on main by #202482)Abertallvm:instcombine
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 64/100
llvm/llvm-project#246503 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 85/100
Mantenedores costumam responder em até 1 dia