runtime: possible contention on epollwait #48428
Labels
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
I had implement some kind of redis proxy which dose encode/decode on behave of each command.
By doing some benchmark against this tiny project, I found some maybe interesting things.
With redis pipeline disabled(memtier_benchmark --pipeline 1), as concurrent connection increase,
the throughput continue to increasing , until a certain level, with whatever GOMAXPROCESS.
Taking a look at /proc/pid/stack by a bit sampling, I found all of the Ms are sitting in syscall(entry_SYSCALL_64_after_hwframe namely).
Using ebpf to step down the sample call stack:
It appears to be contention on the global single epoll fd used by netpoller.
My suspicion is that:
A possible solution is to associate each M with its private epfd?
Note:
Running on Ubuntu Xenial(kernel 4.15.0)
What did you expect to see?
What did you see instead?
The text was updated successfully, but these errors were encountered: