Skip to content

cmd/go: GOMIPS environment variable does not affect caching of mipsle code #27260

Closed
@ianlancetaylor

Description

@ianlancetaylor

This script shows that the results of compiling with GOARCH=mipsle are cached without regard to the value of the GOMIPS environment variable.

> cat foo.go
package p

func F(f float64) float64 {
	return f + f
}
> go clean -cache
> GOARCH=mipsle go build -gcflags=-S foo.go 2>&1 | grep F0
	0x0000 00000 (/home/iant/foo10.go:4)	MOVF	"".f(FP), F0
	0x0008 00008 (/home/iant/foo10.go:4)	ADDD	F0, F0, F0
	0x000c 00012 (/home/iant/foo10.go:4)	MOVF	F0, "".~r1+8(FP)
> GOARCH=mipsle GOMIPS=softfloat go build -gcflags=-S foo.go 2>&1 | grep F0
	0x0000 00000 (/home/iant/foo10.go:4)	MOVF	"".f(FP), F0
	0x0008 00008 (/home/iant/foo10.go:4)	ADDD	F0, F0, F0
	0x000c 00012 (/home/iant/foo10.go:4)	MOVF	F0, "".~r1+8(FP)
> go clean -cache
> GOARCH=mipsle GOMIPS=softfloat go build -gcflags=-S foo.go 2>&1 | grep F0
>

Metadata

Metadata

Assignees

No one assigned

    Labels

    FrozenDueToAgeNeedsFixThe path to resolution is known, but the work has not been done.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions