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: invalid relocation R_DWARFSECREF on windows/arm64 with go test -c #48972

Closed
mknyszek opened this issue Oct 14, 2021 · 1 comment
Closed
Assignees
Milestone

Comments

@mknyszek
Copy link
Contributor

@mknyszek mknyszek commented Oct 14, 2021

In working on #47557 I tried to build the golang.org/x/perf/storage/app tests with go test -c and ran into:

$ gomote run -dir=perf user-mknyszek-windows-arm64-10-0 go/bin/go test -c ./storage/app
# golang.org/x/perf/storage/app.test
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x136463
sym 3263: unsupported obj reloc R_DWARFSECREF/4 to go.info.net/http.(*ServeMux).HandleFunc$abstract
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x136490
sym 3263: unsupported obj reloc R_DWARFSECREF/4 to go.info.net/http.(*ServeMux).HandleFunc$abstract
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x13649e
sym 3263: unsupported obj reloc R_DWARFSECREF/4 to go.info.net/http.(*ServeMux).HandleFunc$abstract
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x136463
sym 3263: unsupported obj reloc R_DWARFSECREF/4 to go.info.net/http.(*ServeMux).HandleFunc$abstract
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x136490
sym 3263: unsupported obj reloc R_DWARFSECREF/4 to go.info.net/http.(*ServeMux).HandleFunc$abstract
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x13649e
sym 3263: unsupported obj reloc R_DWARFSECREF/4 to go.info.net/http.(*ServeMux).HandleFunc$abstract
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x136463
sym 3263: unsupported obj reloc R_DWARFSECREF/4 to go.info.net/http.(*ServeMux).HandleFunc$abstract
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x136490
sym 3263: unsupported obj reloc R_DWARFSECREF/4 to go.info.net/http.(*ServeMux).HandleFunc$abstract
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x13649e
sym 3263: unsupported obj reloc R_DWARFSECREF/4 to go.info.net/http.(*ServeMux).HandleFunc$abstract
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x136463
sym 3263: unsupported obj reloc R_DWARFSECREF/4 to go.info.net/http.(*ServeMux).HandleFunc$abstract
sym 3263: invalid relocation: R_DWARFSECREF .debug_info+0x136490
C:\workdir\go\pkg\tool\windows_arm64\link.exe: too many errors
Error running run: exit status 2

@thanm says in #47557 (comment):

Interesting problem. It looks like one of these tests is failing:

https://go.googlesource.com/go/+/24e798e2876f05d628f1e9a32ce8c7f4a3ed3268/src/cmd/link/internal/arm64/asm.go#610
https://go.googlesource.com/go/+/24e798e2876f05d628f1e9a32ce8c7f4a3ed3268/src/cmd/link/internal/arm64/asm.go#618

meaning that the relocation won't reach, but we can't find the linker-introduced label symbol. Why it is happening with only DWARF relocations is a mystery though.

@mknyszek mknyszek added this to the Backlog milestone Oct 14, 2021
@thanm thanm self-assigned this Oct 14, 2021
@cherrymui
Copy link
Contributor

@cherrymui cherrymui commented Nov 4, 2021

Loading

@cherrymui cherrymui closed this Nov 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants