Involved Source Files Package buildcfg provides access to the build configuration
described by the current environment. It is for use by build tools
such as cmd/go or cmd/compile and for setting up go/build's Default context.
Note that it does NOT provide access to the build configuration used to
build the currently-running binary. For that, use runtime.GOOS etc
as well as internal/goexperiment.exp.gozbootstrap.go
Package-Level Type Names (total 4, in which 3 are exported)
/* sort exporteds by: | */
ExperimentFlags represents a set of GOEXPERIMENT flags relative to a baseline
(platform-default) experiment configuration.Flagsgoexperiment.Flags AliasTypeParams enables type parameters for alias types.
Requires that gotypesalias=1 is set with GODEBUG.
This flag will be removed with Go 1.25. Arenas causes the "arena" standard library package to be visible
to the outside world.Flags.BoringCryptobool CacheProg adds support to cmd/go to use a child process to implement
the build cache; see https://github.com/golang/go/issues/59719. CgoCheck2 enables an expensive cgo rule checker.
When this experiment is enabled, cgo rule checks occur regardless
of the GODEBUG=cgocheck setting provided at runtime. CoverageRedesign enables the new compiler-based code coverage
tooling.Flags.FieldTrackbool HeapMinimum512KiB reduces the minimum heap size to 512 KiB.
This was originally reduced as part of PacerRedesign, but
has been broken out to its own experiment that is disabled
by default. LoopVar changes loop semantics so that each iteration gets its own
copy of the iteration variable. NewInliner enables a new+improved version of the function
inlining phase within the Go compiler.Flags.PreemptibleLoopsbool RangeFunc enables range over func. RegabiArgs enables register arguments/results in all
compiled Go functions.
Requires wrappers (to do ABI translation), and reflect (so
reflection calls use registers). RegabiWrappers enables ABI wrappers for calling between
ABI0 and ABIInternal functions. Without this, the ABIs are
assumed to be identical so cross-ABI calls are direct. SpinbitMutex enables the new "spinbit" mutex implementation on supported
platforms. See https://go.dev/issue/68578.Flags.StaticLockRankingbool SwissMap enables the SwissTable-based map implementation. SyncHashTrieMap enables the HashTrieMap sync.Map implementation. Synctest enables the testing/synctest package.baselinegoexperiment.Flags All returns a list of all experiment settings.
Disabled experiments appear in the list prefixed by "no". Enabled returns a list of enabled experiments, as
lower-cased experiment names. String returns the canonical GOEXPERIMENT string to enable this experiment
configuration. (Experiments in the same state as in the baseline are elided.)
*ExperimentFlags : expvar.Var
*ExperimentFlags : fmt.Stringer
*ExperimentFlags : context.stringer
*ExperimentFlags : github.com/aws/smithy-go/middleware.stringer
*ExperimentFlags : runtime.stringer
func ParseGOEXPERIMENT(goos, goarch, goexp string) (*ExperimentFlags, error)
var Experiment
ARM v8.0 Cryptographic Extension. It includes the following features:
* FEAT_AES, which includes the AESD and AESE instructions.
* FEAT_PMULL, which includes the PMULL, PMULL2 instructions.
* FEAT_SHA1, which includes the SHA1* instructions.
* FEAT_SHA256, which includes the SHA256* instructions. Large Systems ExtensionVersionstring( Goarm64Features) String() string Returns true if g supports giving ARM64 ISA
Note that this function doesn't accept / test suffixes (like ",lse" or ",crypto")
Goarm64Features : expvar.Var
Goarm64Features : fmt.Stringer
Goarm64Features : context.stringer
Goarm64Features : github.com/aws/smithy-go/middleware.stringer
Goarm64Features : runtime.stringer
func ParseGoarm64(v string) (g Goarm64Features, e error)
func goarm64() (g Goarm64Features)
var GOARM64
ParseGOEXPERIMENT parses a (GOOS, GOARCH, GOEXPERIMENT)
configuration tuple and returns the enabled and baseline experiment
flag sets.
TODO(mdempsky): Move to internal/goexperiment.
expList returns the list of lower-cased experiment names for
experiments that differ from base. base may be nil to indicate no
experiments. If all is true, then include all experiment flags,
regardless of base.
Package-Level Variables (total 19, all are exported)
Error is one of the errors found (if any) in the build configuration.
Experiment contains the toolchain experiments enabled for the
current build.
(This is not necessarily the set of experiments the compiler itself
was built with.)
experimentBaseline specifies the experiment flags that are enabled by
default in the current toolchain. This is, in effect, the "control"
configuration and any variation from this is an experiment.
FramePointerEnabled enables the use of platform conventions for
saving frame pointers.
This used to be an experiment, but now it's always enabled on
platforms that support it.
Note: must agree with runtime.framepointer_enabled.