aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/go/internal/envcmd/env.go
diff options
context:
space:
mode:
authorCarlos Eduardo Seo <cseo@linux.vnet.ibm.com>2019-01-11 17:16:28 -0200
committerLynn Boger <laboger@linux.vnet.ibm.com>2019-03-13 14:44:02 +0000
commit4ba69a9a17d643e2e18acebac7b176746564b897 (patch)
tree8086f5a435ba430173c75bc07b67bfe39b3aca8e /src/cmd/go/internal/envcmd/env.go
parent82af9e67493b14ad1e10f28a384645e904a88d6f (diff)
downloadgo-4ba69a9a17d643e2e18acebac7b176746564b897.tar.gz
go-4ba69a9a17d643e2e18acebac7b176746564b897.zip
cmd/compile: add processor level selection support to ppc64{,le}
ppc64{,le} processor level selection allows the compiler to generate instructions targeting newer processors and processor-specific optimizations without breaking compatibility with our current baseline. This feature introduces a new environment variable, GOPPC64. GOPPC64 is a GOARCH=ppc64{,le} specific option, for a choice between different processor levels (i.e. Instruction Set Architecture versions) for which the compiler will target. The default is 'power8'. Change-Id: Ic152e283ae1c47084ece4346fa002a3eabb3bb9e Reviewed-on: https://go-review.googlesource.com/c/go/+/163758 Run-TryBot: Carlos Eduardo Seo <cseo@linux.vnet.ibm.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: David Chase <drchase@google.com>
Diffstat (limited to 'src/cmd/go/internal/envcmd/env.go')
-rw-r--r--src/cmd/go/internal/envcmd/env.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/cmd/go/internal/envcmd/env.go b/src/cmd/go/internal/envcmd/env.go
index ae98d3999a..08291dfb14 100644
--- a/src/cmd/go/internal/envcmd/env.go
+++ b/src/cmd/go/internal/envcmd/env.go
@@ -81,6 +81,8 @@ func MkEnv() []cfg.EnvVar {
env = append(env, cfg.EnvVar{Name: "GOMIPS", Value: cfg.GOMIPS})
case "mips64", "mips64le":
env = append(env, cfg.EnvVar{Name: "GOMIPS64", Value: cfg.GOMIPS64})
+ case "ppc64", "ppc64le":
+ env = append(env, cfg.EnvVar{Name: "GOPPC64", Value: cfg.GOPPC64})
}
cc := cfg.DefaultCC(cfg.Goos, cfg.Goarch)