-
Notifications
You must be signed in to change notification settings - Fork 269
golang programs crash with heavy goroutine scheduling #1932
Copy link
Copy link
Closed
Labels
Type: BugError or flaw producing unexpected resultsError or flaw producing unexpected results
Milestone
Description
Broken out from #1549
This breaks in both ptrace and preload mode, though perhaps a bit more consistently in preload mode.
Example program:
package main
import (
"fmt"
"sync"
"time"
)
func worker(wg *sync.WaitGroup, from int) {
defer wg.Done()
for i := 0; i < 10; i++ {
fmt.Println("Worker:", from, " iteration:", i)
time.Sleep(time.Second)
}
}
func main() {
var wg sync.WaitGroup
for i := 0; i < 10; i++ {
wg.Add(1)
go worker(&wg, i)
}
wg.Wait()
fmt.Println("done")
}
general:
stop_time: 2000s
network:
graph:
type: 1_gbit_switch
hosts:
host:
network_node_id: 0
processes:
- path: ./test_goroutines
start_time: 1s
environment: GOMAXPROCS=2
The program often ends up exiting with exit code 139, indicating it was killed by signal 11 (SIGSEGV).
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Type: BugError or flaw producing unexpected resultsError or flaw producing unexpected results