ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/libev/ev.c
(Generate patch)

Comparing libev/ev.c (file contents):
Revision 1.490 by root, Thu Jun 20 22:44:59 2019 UTC vs.
Revision 1.492 by root, Sat Jun 22 16:25:53 2019 UTC

115# else 115# else
116# undef EV_USE_EPOLL 116# undef EV_USE_EPOLL
117# define EV_USE_EPOLL 0 117# define EV_USE_EPOLL 0
118# endif 118# endif
119 119
120# if HAVE_LINUX_AIO_ABI_H
121# ifndef EV_USE_LINUXAIO
122# define EV_USE_LINUXAIO EV_FEATURE_BACKENDS
123# endif
124# else
125# undef EV_USE_LINUXAIO
126# define EV_USE_LINUXAIO 0
127# endif
128
120# if HAVE_KQUEUE && HAVE_SYS_EVENT_H 129# if HAVE_KQUEUE && HAVE_SYS_EVENT_H
121# ifndef EV_USE_KQUEUE 130# ifndef EV_USE_KQUEUE
122# define EV_USE_KQUEUE EV_FEATURE_BACKENDS 131# define EV_USE_KQUEUE EV_FEATURE_BACKENDS
123# endif 132# endif
124# else 133# else
316#ifndef EV_USE_PORT 325#ifndef EV_USE_PORT
317# define EV_USE_PORT 0 326# define EV_USE_PORT 0
318#endif 327#endif
319 328
320#ifndef EV_USE_LINUXAIO 329#ifndef EV_USE_LINUXAIO
330# if __linux /* libev currently assumes linux/aio_abi.h is always available on linux */
331# define EV_USE_LINUXAIO 1
332# else
321# define EV_USE_LINUXAIO 0 333# define EV_USE_LINUXAIO 0
334# endif
322#endif 335#endif
323 336
324#ifndef EV_USE_INOTIFY 337#ifndef EV_USE_INOTIFY
325# if __linux && (__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 4)) 338# if __linux && (__GLIBC__ > 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 4))
326# define EV_USE_INOTIFY EV_FEATURE_OS 339# define EV_USE_INOTIFY EV_FEATURE_OS
424 437
425#if !EV_USE_NANOSLEEP 438#if !EV_USE_NANOSLEEP
426/* hp-ux has it in sys/time.h, which we unconditionally include above */ 439/* hp-ux has it in sys/time.h, which we unconditionally include above */
427# if !defined _WIN32 && !defined __hpux 440# if !defined _WIN32 && !defined __hpux
428# include <sys/select.h> 441# include <sys/select.h>
442# endif
443#endif
444
445#if EV_USE_LINUXAIO
446# include <sys/syscall.h>
447# if !SYS_io_getevents
448# undef EV_USE_LINUXAIO
449# define EV_USE_LINUXAIO 0
429# endif 450# endif
430#endif 451#endif
431 452
432#if EV_USE_INOTIFY 453#if EV_USE_INOTIFY
433# include <sys/statfs.h> 454# include <sys/statfs.h>
2785#endif 2806#endif
2786#ifdef __FreeBSD__ 2807#ifdef __FreeBSD__
2787 flags &= ~EVBACKEND_POLL; /* poll return value is unusable (http://forums.freebsd.org/archive/index.php/t-10270.html) */ 2808 flags &= ~EVBACKEND_POLL; /* poll return value is unusable (http://forums.freebsd.org/archive/index.php/t-10270.html) */
2788#endif 2809#endif
2789 2810
2811 /* TODO: linuxaio is very experimental */
2812 flags &= ~EVBACKEND_LINUXAIO;
2813
2790 return flags; 2814 return flags;
2791} 2815}
2792 2816
2793ecb_cold 2817ecb_cold
2794unsigned int 2818unsigned int

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines