diff options
| author | Valentin Bartenev <vbart@nginx.com> | 2016-07-15 15:18:57 +0300 |
|---|---|---|
| committer | Valentin Bartenev <vbart@nginx.com> | 2016-07-15 15:18:57 +0300 |
| commit | 5c2dd3913aad5c4bf7d9056e1336025c2703586b (patch) | |
| tree | 8569c90681ada207b182ff4b583225c7a70f3d9e /auto/os | |
| parent | b60534e0d8f943740fb6847ac0a1ff3091a373d0 (diff) | |
| download | nginx-5c2dd3913aad5c4bf7d9056e1336025c2703586b.tar.gz nginx-5c2dd3913aad5c4bf7d9056e1336025c2703586b.tar.bz2 | |
Events: support for EPOLLEXCLUSIVE.
This flag appeared in Linux 4.5 and is useful for avoiding thundering herd
problem.
The current Linux kernel implementation walks the list of exclusive waiters,
and queues an event to each epfd, until it finds the first waiter that has
threads blocked on it via epoll_wait().
Diffstat (limited to 'auto/os')
| -rw-r--r-- | auto/os/linux | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/auto/os/linux b/auto/os/linux index 132ce3b42..fae8842c6 100644 --- a/auto/os/linux +++ b/auto/os/linux @@ -70,6 +70,22 @@ if [ $ngx_found = yes ]; then ee.data.ptr = NULL; epoll_ctl(efd, EPOLL_CTL_ADD, fd, &ee)" . auto/feature + + + # EPOLLEXCLUSIVE appeared in Linux 4.5, glibc 2.24 + + ngx_feature="EPOLLEXCLUSIVE" + ngx_feature_name="NGX_HAVE_EPOLLEXCLUSIVE" + ngx_feature_run=no + ngx_feature_incs="#include <sys/epoll.h>" + ngx_feature_path= + ngx_feature_libs= + ngx_feature_test="int efd = 0, fd = 0; + struct epoll_event ee; + ee.events = EPOLLIN|EPOLLEXCLUSIVE; + ee.data.ptr = NULL; + epoll_ctl(efd, EPOLL_CTL_ADD, fd, &ee)" + . auto/feature fi |
