]> Cypherpunks repositories - gostls13.git/commit
cmd/go/internal/work: cache cgo invocations for vet, build modes
authorRuss Cox <rsc@golang.org>
Thu, 19 Apr 2018 01:12:19 +0000 (21:12 -0400)
committerRuss Cox <rsc@golang.org>
Thu, 10 May 2018 19:15:33 +0000 (19:15 +0000)
commit4826d20a0953b3682cf6eedd1e9becb68bbb25e9
tree81d930766b35d7142d9772f254db0d1d1c26a30b
parent9ccfde6ee7df654be64a79c79ec4178c10d8fd18
cmd/go/internal/work: cache cgo invocations for vet, build modes

Even if we had an up-to-date package binary, we reran cgo anyway if
(1) we needed a header file for buildmode c-archive or c-shared, or
(2) we needed cgo-translated files source files for input to go vet.

Cache those outputs too, so that we can avoid cgo if possible.

Working toward exposing the cgo-generated files in go list.

Change-Id: I339ecace925d2b0adc235a17977ecadb3d636c73
Reviewed-on: https://go-review.googlesource.com/108015
Run-TryBot: Russ Cox <rsc@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Bryan C. Mills <bcmills@google.com>
src/cmd/go/go_test.go
src/cmd/go/internal/work/exec.go