ondrajz / go-callvis

Visualize call graph of a Go program using Graphviz
https://ofabry.github.io/go-callvis
MIT License
5.94k stars 409 forks source link

Hang with high cpu usage, no io #62

Open Gnoale opened 4 years ago

Gnoale commented 4 years ago

Hello, I tried the tool on 2 different projects, Ok : go-callvis -group pkg,type github.com/jtbonhomme/gotp/cmd/gotp KO (hang with 100% cpu) go-callvis -debug -nostd -group pkg,type -focus="store" github.com/thanos-io/thanos/cmd/thanos

ondrajz commented 4 years ago

Try using -limit/-ignore/-include to filter out non-interesting parts of callgraph.

exapsy commented 3 years ago

@ofabry I dont think that's the problem. @Gnoale uses -nostd. For some reason when I use -nostd and I go to a complex package, it hangs. I can wait for minutes, but no result. When I don't use -nostd, I may wait for 5-20 seconds, but I eventually I get an output.

So, this makes it an interesting case.

suntong commented 3 years ago

Ah, thanks for the reporting @exapsy, my cmd hang too, and I was using all sorts of combination to figure out what is the cause, and never occurs to me that, -nostd, which is meant to simplify the graph, actually is the cause of the hang.

So, yeah, I've duplicated exactly what you've found.

suntong commented 3 years ago

BTW,

ondrajz commented 3 years ago

Thanks for reporting I will investigate.