Skip to content

Linker Warnings when using go race detector #1774

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

Open
oreissig opened this issue Mar 12, 2025 · 1 comment
Open

Linker Warnings when using go race detector #1774

oreissig opened this issue Mar 12, 2025 · 1 comment
Labels

Comments

@oreissig
Copy link

Since upgrading to client_golang v1.21.0 (still present in v1.21.1) I'm seeing strange linker warnings in my console output when running go test -race:

go test -race ./pkg/...
# [...pkg path...]
ld: warning: '/private/var/folders/fq/r4cfy5dn7pv9gtjn9m87qrp00000gn/T/go-link-2788382549/000013.o' has malformed LC_DYSYMTAB, expected 98 undefined symbols to start at index 1626, found 95 undefined symbols starting at index 1626

It does not occur when

  • using client_golang v1.20.5 or below
  • using go test without -race

My environment:
go version go1.24.1 darwin/arm64

Copy link

dosubot bot commented Mar 12, 2025

Hey @oreissig! I'm here to help you with any bugs, questions, or contributions you have. Let's tackle this issue together!

The linker warnings you're encountering when using the Go race detector with client_golang v1.21.0 and v1.21.1 might be related to the concurrency optimizations introduced in these versions. Specifically, the Inc, Add, and Observe cumulative metrics were optimized to be up to 50% faster under high concurrent contention, which could potentially affect the behavior observed by the Go race detector [1].

These optimizations were reverted in version 1.21.1 due to causing regressions on low contention cases, but it seems the issue with the race detector persists. Since the warnings do not occur with client_golang v1.20.5 or below, you might consider using that version as a temporary workaround until the issue is resolved. Additionally, the problem does not appear when running go test without the -race flag, indicating a specific interaction with the race detector.

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Bug Report | Other

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant