Open
Description
godebug's current procedure for running instrumented code for a package x
is:
- make a temp directory
- make a subdirectory
$TMP/src/x
containing instrumented versions of the source files forx
- run the
go
command, settingGOPATH=$TMP:$GOPATH
. Thego
command finds our instrumented packages in$TMP/src
and finds any other un-instrumented packages in the normal GOPATH.
That process does not work for standard library packages, though, because $GOROOT
has to be a single directory.
Here's my current plan for working around this:
- Implement the proposal from UX improvement:
godebug <run, test, build>
#8 of having a permanent godebug directory that contains instrumented versions of all the packages we have seen so far. Put standard library packages in the same place, or possibly in their own/goroot
or/std
directory. - From the same proposal, generate a temporary directory for every invocation of godebug and fill it with symlinks to the packages we want to instrument. The only new thing is that for all standard library packages we don't want to instrument, we will need to add a symlink to the real package in
$GOROOT
.
Metadata
Metadata
Assignees
Labels
No labels