Skip to content

Panic during compilation of go program #18615

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
jefferai opened this issue Jan 11, 2017 · 4 comments
Closed

Panic during compilation of go program #18615

jefferai opened this issue Jan 11, 2017 · 4 comments

Comments

@jefferai
Copy link

This is a transient error that I received only once out of thousands of compiles, and did not see on my next compile; I'm opening this in case someone is interested in digging into it, but feel free to close if you like!

What version of Go are you using (go version)?

go version go1.7.4 darwin/amd64

What operating system and processor architecture are you using (go env)?

GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/Users/jeff/go"
GORACE=""
GOROOT="/Users/jeff/src/go"
GOTOOLDIR="/Users/jeff/src/go/pkg/tool/darwin_amd64"
CC="clang"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/h0/06d2pyw96751gy0j9t96kvrc0000gn/T/go-build992160106=/tmp/go-build -gno-record-gcc-switches -fno-common"
CXX="clang++"
CGO_ENABLED="1"

What did you do?

I was simply compiling my program, which I've done thousands of times.

What did you expect to see?

Normal behavior.

What did you see instead?

# github.com/hashicorp/vault/vendor/github.com/aws/aws-sdk-go/private/protocol/ec2query
mach error semaphore_wait: 49
fatal error: mach error

runtime stack:
runtime.throw(0x4f8733, 0xa)
	/Users/jeff/src/go/src/runtime/panic.go:566 +0x95
runtime.macherror(0xc400000031, 0x4faccd, 0xe)
	/Users/jeff/src/go/src/runtime/os_darwin.go:221 +0xb7
runtime.semasleep1(0xffffffffffffffff, 0x731680)
	/Users/jeff/src/go/src/runtime/os_darwin.go:442 +0x7c
runtime.semasleep.func1()
	/Users/jeff/src/go/src/runtime/os_darwin.go:451 +0x33
runtime.systemstack(0xc420041dc8)
	/Users/jeff/src/go/src/runtime/asm_amd64.s:314 +0xab
runtime.semasleep(0xffffffffffffffff, 0x0)
	/Users/jeff/src/go/src/runtime/os_darwin.go:452 +0x44
runtime.notesleep(0xc420036510)
	/Users/jeff/src/go/src/runtime/lock_sema.go:166 +0x9f
runtime.stopm()
	/Users/jeff/src/go/src/runtime/proc.go:1594 +0xad
runtime.findrunnable(0xc420022a00, 0x0)
	/Users/jeff/src/go/src/runtime/proc.go:2021 +0x228
runtime.schedule()
	/Users/jeff/src/go/src/runtime/proc.go:2120 +0x14c
runtime.park_m(0xc420000b60)
	/Users/jeff/src/go/src/runtime/proc.go:2183 +0x123
runtime.mcall(0x0)
	/Users/jeff/src/go/src/runtime/asm_amd64.s:240 +0x5b

goroutine 1 [runnable]:
cmd/compile/internal/gc.(*importer).typ(0xc4204a41c0, 0xc4206c8460)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:386
cmd/compile/internal/gc.(*importer).field(0xc4204a41c0, 0x2)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:546 +0x55
cmd/compile/internal/gc.(*importer).fieldList(0xc4204a41c0, 0xffffffffffffff16, 0xc4206d2780, 0x90)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:536 +0x8f
cmd/compile/internal/gc.(*importer).typ(0xc4204a41c0, 0xc4206d25a0)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:483 +0xc77
cmd/compile/internal/gc.(*importer).typ(0xc4204a41c0, 0xffffffffffffff12)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:407 +0x148
cmd/compile/internal/gc.(*importer).typ(0xc4204a41c0, 0x0)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:487 +0xfde
cmd/compile/internal/gc.(*importer).param(0xc4204a41c0, 0x1, 0x2)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:630 +0x40
cmd/compile/internal/gc.(*importer).paramList(0xc4204a41c0, 0xc420721660, 0x1, 0x1)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:623 +0xab
cmd/compile/internal/gc.(*importer).typ(0xc4204a41c0, 0xc4206e4700)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:434 +0x23c
cmd/compile/internal/gc.(*importer).field(0xc4204a41c0, 0x1)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:546 +0x55
cmd/compile/internal/gc.(*importer).fieldList(0xc4204a41c0, 0xffffffffffffff16, 0xc4206df900, 0x90)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:536 +0x8f
cmd/compile/internal/gc.(*importer).typ(0xc4204a41c0, 0xc4206df860)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:483 +0xc77
cmd/compile/internal/gc.(*importer).typ(0xc4204a41c0, 0xffffffffffffff12)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:407 +0x148
cmd/compile/internal/gc.(*importer).typ(0xc4204a41c0, 0x0)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:487 +0xfde
cmd/compile/internal/gc.(*importer).param(0xc4204a41c0, 0x1, 0x2)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:630 +0x40
cmd/compile/internal/gc.(*importer).paramList(0xc4204a41c0, 0xc4206e4620, 0x1, 0x0)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:623 +0xab
cmd/compile/internal/gc.(*importer).method(0xc4204a41c0, 0x1)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:585 +0x6c
cmd/compile/internal/gc.(*importer).methodList(0xc4204a41c0, 0x0, 0xc4206df7c0, 0x0)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:575 +0x8f
cmd/compile/internal/gc.(*importer).typ(0xc4204a41c0, 0xc4204a61e0)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:500 +0x1076
cmd/compile/internal/gc.(*importer).typ(0xc4204a41c0, 0x0)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:407 +0x148
cmd/compile/internal/gc.(*importer).obj(0xc4204a41c0, 0xfffffffffffffffd)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:282 +0x961
cmd/compile/internal/gc.Import(0xc42049e540)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/bimport.go:97 +0x3b2
cmd/compile/internal/gc.importfile(0xc4206e43a0, 0x0, 0x0, 0x0)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/main.go:843 +0x9b1
cmd/compile/internal/gc.(*parser).importdcl(0xc4206e4380)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/parser.go:341 +0x178
cmd/compile/internal/gc.(*parser).import_(0xc4206e4380)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/parser.go:300 +0x71
cmd/compile/internal/gc.(*parser).file(0xc4206e4380)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/parser.go:268 +0x5e
cmd/compile/internal/gc.parse_file(0xc42049e360)
	/Users/jeff/src/go/src/cmd/compile/internal/gc/parser.go:31 +0x54
cmd/compile/internal/gc.Main()
	/Users/jeff/src/go/src/cmd/compile/internal/gc/main.go:334 +0x14f4
cmd/compile/internal/amd64.Main()
	/Users/jeff/src/go/src/cmd/compile/internal/amd64/galign.go:93 +0x2fa
main.main()
	/Users/jeff/src/go/src/cmd/compile/main.go:33 +0x2a3
@bradfitz
Copy link
Contributor

Dup of #17161, fixed in Go 1.8. Please try Go 1.8rc1, released yesterday.

@jefferai
Copy link
Author

Sounds good, sorry for the dup. I could try 1.8 but since I've never seen this before I'm not sure I'd notice a difference :-D

@bradfitz
Copy link
Contributor

Please try 1.8 anyway. It's much better, and we could always use more testers. We're using it by default internally at Google for all Go code at this point. We don't know of any problems with it.

@jefferai
Copy link
Author

@bradfitz sounds good!

@golang golang locked and limited conversation to collaborators Jan 11, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants