Combine Go Stacks

Paste Go stack traces in text format, and get a report with the same traces combined. This is useful for figuring out what a big program was doing when it crashed. See my blog post for details. The code powering this is panicparse, which is a great tool!

Example Input

goroutine 182 [semacquire]:
main.b2(0xc000192068)
  /Users/ej/combinestacks/stackdemo/stackdemo.go:86 +0x66
main.b1(0xc000192068)
  /Users/ej/combinestacks/stackdemo/stackdemo.go:82 +0x2b
created by main.main
  /Users/ej/combinestacks/stackdemo/stackdemo.go:41 +0x367

goroutine 182 [semacquire]:
main.b2(0xc000192068)
  /Users/ej/combinestacks/stackdemo/stackdemo.go:86 +0x66
main.b1(0xc000192068)
  /Users/ej/combinestacks/stackdemo/stackdemo.go:82 +0x2b
created by main.main
  /Users/ej/combinestacks/stackdemo/stackdemo.go:41 +0x367

Example Output

Found 2 total goroutines

2 goroutines; example goroutine=182; state=[semacquire]
main.b2(0xc000192068)
	/Users/ej/combinestacks/stackdemo/stackdemo.go:86
main.b1(0xc000192068)
	/Users/ej/combinestacks/stackdemo/stackdemo.go:82
created by main.main
	/Users/ej/combinestacks/stackdemo/stackdemo.go:41