You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed that godef is now conditionally using go/packages . I had an encountered an issue with gogetdoc that is caused by go/packages. go/packages invokes go list -compiled (golang/tools/go/packages/golist.go#L630) unconditionally, which compiles any cgo packages in the list, without any caching.
This can get prohibitively slow to the point that it made gogetdoc unusable when such packages are in the list.
The text was updated successfully, but these errors were encountered:
segevfiner
changed the title
godef might be extremly slow in Go packages using cgo
godef might be extremly slow in Go packages using cgo when using go/packages
Dec 25, 2018
I noticed that godef is now conditionally using
go/packages
. I had an encountered an issue withgogetdoc
that is caused bygo/packages
.go/packages
invokesgo list -compiled
(golang/tools/go/packages/golist.go#L630) unconditionally, which compiles any cgo packages in the list, without any caching.This can get prohibitively slow to the point that it made
gogetdoc
unusable when such packages are in the list.Steps to reproduce
You need to have ImageMagick available. (See https://github.com/gographics/imagick)
main.go
in a new go package directory:dep init
.godef -pos main.go:#87
.I haven't yet gotten around to check if this reproduces.
godetdoc
issue: zmb3/gogetdoc#47The text was updated successfully, but these errors were encountered: