Skip to content
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

cmd/link: testDWARF in c-archive mode fails on Linux (but not Darwin) #31363

Open
eliasnaur opened this Issue Apr 9, 2019 · 0 comments

Comments

Projects
None yet
2 participants
@eliasnaur
Copy link
Contributor

commented Apr 9, 2019

From the discussion in https://go-review.googlesource.com/c/go/+/170377:

$ git diff
diff --git a/src/cmd/link/dwarf_test.go b/src/cmd/link/dwarf_test.go
index ecc96019be..ffdad6ce10 100644
--- a/src/cmd/link/dwarf_test.go
+++ b/src/cmd/link/dwarf_test.go
@@ -148,6 +148,7 @@ func testDWARF(t *testing.T, buildmode string, expectDWARF bool, env ...string)
 
 func TestDWARF(t *testing.T) {
        testDWARF(t, "", true)
+       testDWARF(t, "c-archive", true)
 }
 
 func TestDWARFiOS(t *testing.T) {
$ ./make.bash 
Building Go cmd/dist using /home/elias/dev/go-1.7.
Building Go toolchain1 using /home/elias/dev/go-1.7.
Building Go bootstrap cmd/go (go_bootstrap) using Go toolchain1.
Building Go toolchain2 using go_bootstrap and Go toolchain1.
Building Go toolchain3 using go_bootstrap and Go toolchain2.
Building packages and commands for linux/amd64.
---
Installed Go for linux/amd64 in /home/elias/dev/go-tip
Installed commands in /home/elias/dev/go-tip/bin
$ go test cmd/link
--- FAIL: TestDWARF (0.09s)
    --- FAIL: TestDWARF/testprog#01 (3.02s)
        dwarf_test.go:130: ErrUnknownPC
    --- FAIL: TestDWARF/testprogcgo#01 (4.01s)
        dwarf_test.go:130: ErrUnknownPC
FAIL
FAIL	cmd/link	4.248s

On the other hand, testDWARF successfully runs on Darwin as demonstrated by CL 170377. It also successfully runs in the related testDWARFiOS test.

@eliasnaur eliasnaur changed the title cmd/link: testDWARF is c-archive mode fails on Linux (but not Darwin) cmd/link: testDWARF in c-archive mode fails on Linux (but not Darwin) Apr 9, 2019

@bcmills bcmills added this to the Go1.13 milestone Apr 10, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.