]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: renovate GOSSAHASH
authorDavid Chase <drchase@google.com>
Fri, 14 Oct 2022 16:04:52 +0000 (12:04 -0400)
committerDavid Chase <drchase@google.com>
Wed, 2 Nov 2022 17:01:39 +0000 (17:01 +0000)
commit03f6d81fc7d52ec53deb94cff69b63d04e689c24
tree1cb8e96371331cfba7778b4f83a67ed374c6837c
parent3ba3b4893f3630b2bd78ec6f4f366d60e16bd636
cmd/compile: renovate GOSSAHASH

Randomized feature enable/disable might be something we use to
help users debug any problems with changed loop variable capture,
and there's another CL that would like to use it to help in
locating places where "fused" multiply add instructions change
program behavior.

This CL:
- adds the ability to include an integer parameter (e.g. line number)
- replumbed the environment variable into a flag to simplify go build cache management
- but added an environment variable to allow flag setting through the environment
- which adds the possibility of switching on a different variable
  (if there's one built-in for variable capture, it shouldn't be GOSSAHASH)
- cleaned up the checking code
- adds tests for all the intended behavior
- removes the case for GSHS_LOGFILE; TBD whether we'll need to put that back
  or if there is another way.

Change-Id: I8503e1bb3dbc4a743aea696e04411ea7ab884787
Reviewed-on: https://go-review.googlesource.com/c/go/+/443063
Reviewed-by: Keith Randall <khr@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Russ Cox <rsc@golang.org>
Run-TryBot: David Chase <drchase@google.com>
src/cmd/compile/internal/base/debug.go
src/cmd/compile/internal/base/flag.go
src/cmd/compile/internal/base/hashdebug.go
src/cmd/compile/internal/base/hashdebug_test.go [new file with mode: 0644]
src/cmd/compile/internal/ssa/func.go
src/cmd/go/internal/work/exec.go