Skip to content

Commit

Permalink
[sync] 4.24
Browse files Browse the repository at this point in the history
  • Loading branch information
Marc Lehmann authored and kindy committed Nov 7, 2017
1 parent ed99020 commit b79fd29
Show file tree
Hide file tree
Showing 7 changed files with 31 additions and 34 deletions.
12 changes: 6 additions & 6 deletions cvs-vers
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
Changes:1.311
Changes:1.315
LICENSE:1.11
Makefile.am:1.9
README:1.21
README.embed:1.29
Symbols.ev:1.14
Symbols.event:1.4
autogen.sh:1.3
configure.ac:1.41
configure.ac:1.42
ev%2B%2B.C:1.3
ev%2B%2B.h:1.62
ev.3:1.99
ev.c:1.480
ev.h:1.184
ev.c:1.481
ev.h:1.187
ev.html:1.80
ev.m4:1.2
ev.pod:1.439
ev_epoll.c:1.71
ev.pod:1.441
ev_epoll.c:1.72
ev_kqueue.c:1.56
ev_poll.c:1.40
ev_port.c:1.29
Expand Down
22 changes: 9 additions & 13 deletions src/Changes
Original file line number Diff line number Diff line change
@@ -1,19 +1,15 @@
Revision history for libev, a high-performance and full-featured event loop.

TODO: ev_loop_wakeup
TODO: EV_STANDALONE == NO_HASSEL (do not use clock_gettime in ev_standalone)
TODO: faq, process a thing in each iteration
TODO: dbeugging tips, ev_verify, ev_init twice
TODO: ev_break for immediate exit (EVBREAK_NOW?)
TODO: ev_feed_child_event
TODO: document the special problem of signals around fork.
TODO: store pid for each signal
TODO: document file descriptor usage per loop
TODO: store loop pid_t and compare isndie signal handler,store 1 for same, 2 for differign pid, clean up in loop_fork
TODO: embed watchers need updating when fd changes
TODO: document portability requirements for atomic pointer access
TODO: document requirements for function pointers and calling conventions.
- ANDROID => __ANDROID__ (reported by [email protected]).
- disable epoll_create1 on android because it has broken header files
and google is unwilling to fix them (reported by [email protected]).

4.24 Wed Dec 28 05:19:55 CET 2016
- bump version to 4.24, as the release tarball inexplicably
didn't have the right version in ev.h, even though the cvs-tagged
version did have the right one (reported by Ales Teska).

4.23 Wed Nov 16 18:23:41 CET 2016
- move some declarations at the beginning to help certain retarded
microsoft compilers, even though their documentation claims
otherwise (reported by Ruslan Osmanov).
Expand Down
2 changes: 1 addition & 1 deletion src/configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ orig_CFLAGS="$CFLAGS"
AC_CONFIG_SRCDIR([ev_epoll.c])

dnl also update ev.h!
AM_INIT_AUTOMAKE(libev,4.22)
AM_INIT_AUTOMAKE(libev,4.24)
AC_CONFIG_HEADERS([config.h])
AM_MAINTAINER_MODE

Expand Down
2 changes: 1 addition & 1 deletion src/ev.c
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@
# define EV_HEAP_CACHE_AT EV_FEATURE_DATA
#endif

#ifdef ANDROID
#ifdef __ANDROID__
/* supposedly, android doesn't typedef fd_mask */
# undef EV_USE_SELECT
# define EV_USE_SELECT 0
Expand Down
8 changes: 4 additions & 4 deletions src/ev.h
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ struct ev_loop;
/*****************************************************************************/

#define EV_VERSION_MAJOR 4
#define EV_VERSION_MINOR 22
#define EV_VERSION_MINOR 24

/* eventmask, revents, events... */
enum {
Expand Down Expand Up @@ -515,10 +515,10 @@ enum {

/* method bits to be ored together */
enum {
EVBACKEND_SELECT = 0x00000001U, /* about anywhere */
EVBACKEND_POLL = 0x00000002U, /* !win */
EVBACKEND_SELECT = 0x00000001U, /* available just about anywhere */
EVBACKEND_POLL = 0x00000002U, /* !win, !aix, broken on osx */
EVBACKEND_EPOLL = 0x00000004U, /* linux */
EVBACKEND_KQUEUE = 0x00000008U, /* bsd */
EVBACKEND_KQUEUE = 0x00000008U, /* bsd, broken on osx */
EVBACKEND_DEVPOLL = 0x00000010U, /* solaris 8 */ /* NYI */
EVBACKEND_PORT = 0x00000020U, /* solaris 10 */
EVBACKEND_ALL = 0x0000003FU, /* all known backends */
Expand Down
17 changes: 9 additions & 8 deletions src/ev.pod
Original file line number Diff line number Diff line change
Expand Up @@ -413,9 +413,10 @@ make libev check for a fork in each iteration by enabling this flag.
This works by calling C<getpid ()> on every iteration of the loop,
and thus this might slow down your event loop if you do a lot of loop
iterations and little real work, but is usually not noticeable (on my
GNU/Linux system for example, C<getpid> is actually a simple 5-insn sequence
without a system call and thus I<very> fast, but my GNU/Linux system also has
C<pthread_atfork> which is even faster).
GNU/Linux system for example, C<getpid> is actually a simple 5-insn
sequence without a system call and thus I<very> fast, but my GNU/Linux
system also has C<pthread_atfork> which is even faster). (Update: glibc
versions 2.25 apparently removed the C<getpid> optimisation again).

The big advantage of this flag is that you can forget about fork (and
forget about forgetting to tell libev about forking, although you still
Expand Down Expand Up @@ -4388,11 +4389,11 @@ in your include path (e.g. in libev/ when using -Ilibev):

ev_win32.c required on win32 platforms only

ev_select.c only when select backend is enabled (which is enabled by default)
ev_poll.c only when poll backend is enabled (disabled by default)
ev_epoll.c only when the epoll backend is enabled (disabled by default)
ev_kqueue.c only when the kqueue backend is enabled (disabled by default)
ev_port.c only when the solaris port backend is enabled (disabled by default)
ev_select.c only when select backend is enabled
ev_poll.c only when poll backend is enabled
ev_epoll.c only when the epoll backend is enabled
ev_kqueue.c only when the kqueue backend is enabled
ev_port.c only when the solaris port backend is enabled

F<ev.c> includes the backend files directly when enabled, so you only need
to compile this single file.
Expand Down
2 changes: 1 addition & 1 deletion src/ev_epoll.c
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ inline_size
int
epoll_init (EV_P_ int flags)
{
#ifdef EPOLL_CLOEXEC
#if defined EPOLL_CLOEXEC && !defined __ANDROID__
backend_fd = epoll_create1 (EPOLL_CLOEXEC);

if (backend_fd < 0 && (errno == EINVAL || errno == ENOSYS))
Expand Down

0 comments on commit b79fd29

Please sign in to comment.