-
Notifications
You must be signed in to change notification settings - Fork 17.7k
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: external linking is nondeterministic on linux-arm64-longtest builder #57035
Comments
Do you have the |
In any case, the And looking at the GNU linker, this may be https://sourceware.org/bugzilla/show_bug.cgi?id=26822. It looks like that was fixed in the GNU binutils 2.36 release (current release is 2.39, I think). The linux-arm64-longtest builder is running GNU ld version 2.35.2. So that is likely where the symbol is coming from. |
Yeah, it looks exactly like https://sourceware.org/bugzilla/show_bug.cgi?id=26822 . Thanks @ianlancetaylor ! Perhaps we could skip the test with older BFD linkers. Or use gold linker on that builder. cc @bcmills (since this is a test in cmd/go) |
The name of the file suggests that this must be coming from |
Yeah, the file is from hostobjCopy, and it is from that assembly file. I'll try adding the |
Yeah, that does work! Thanks, @ianlancetaylor ! I'll send a CL tomorrow. |
Change https://go.dev/cl/454838 mentions this issue: |
Split from #49649.
On the linux-arm64-longtest builder, cmd/go's TestScript/build_issue48319 fails. https://build.golang.org/log/7b3bdfcc706b20aeb4deb0a6b7fb6c73d75670d9
The binary differ because externally-linked binary seems to contain a path of a temporary file.
Build the following code
The resulting binary contains a symbol (from
objdump -t
)which causes the binary content to differ each time.
The builder by default uses the BFD linker, which is
GNU ld (GNU Binutils for Debian) 2.35.2
.Interestingly, using the gold linker the resulting binary does not have such a symbol.
@ianlancetaylor @thanm do you know why the BFD linker creates such a symbol, and if there is any way to make it not do so (besides stripping out all the symbols)? Thanks.
The text was updated successfully, but these errors were encountered: