|
|
Subscribe / Log in / New account

Two performance-oriented patches: epoll and NUMA balancing

Two performance-oriented patches: epoll and NUMA balancing

Posted Nov 5, 2022 23:01 UTC (Sat) by developer122 (guest, #152928)
Parent article: Two performance-oriented patches: epoll and NUMA balancing

>whether the minimum timeout should be set once with epoll_ctl(), or whether it should instead be provided with each epoll_wait() call.
a global setting sounds like a great way to cause multithreading pain


to post comments

Two performance-oriented patches: epoll and NUMA balancing

Posted Nov 6, 2022 1:10 UTC (Sun) by xi0n (subscriber, #138144) [Link] (2 responses)

It’s „global” per epoll fd, and these are typically local to a thread (at least in the common event loop scenarios).

Two performance-oriented patches: epoll and NUMA balancing

Posted Nov 10, 2022 16:35 UTC (Thu) by tleb (subscriber, #157207) [Link] (1 responses)

And it's recommended to avoid sharing epoll fd across threads: https://idea.popcount.org/2017-02-20-epoll-is-fundamental...

Two performance-oriented patches: epoll and NUMA balancing

Posted Nov 19, 2022 17:55 UTC (Sat) by wtarreau (subscriber, #51152) [Link]

> And it's recommended to avoid sharing epoll fd across threads

Agreed! We did this mistake of sharing epoll in haproxy for its early thread support. That lasted maybe one month before we switched to one poller per thread and never looked back. Shared epoll doesn't scale at all and causes lots of complicated races that you need to take care of in your application. No thanks, never again!


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds