Home
last modified time | relevance | path

Searched refs:events (Results 1 – 25 of 49) sorted by relevance

12

/libuv/src/win/
H A Dpoll.c166 unsigned char events = 0; in uv__fast_poll_process_poll_req() local
170 events |= UV_READABLE; in uv__fast_poll_process_poll_req()
177 events |= UV_WRITABLE; in uv__fast_poll_process_poll_req()
180 events &= handle->events & ~mask_events; in uv__fast_poll_process_poll_req()
184 handle->events = 0; in uv__fast_poll_process_poll_req()
189 if (events != 0) { in uv__fast_poll_process_poll_req()
393 int events = req->u.io.overlapped.InternalHigh & handle->events & ~mask_events; in uv__slow_poll_process_poll_req() local
394 if (events != 0) { in uv__slow_poll_process_poll_req()
449 handle->events = 0; in uv_poll_init_socket()
495 handle->events = events; in uv__poll_set()
[all …]
/libuv/src/unix/
H A Dpoll.c47 if ((events & POLLERR) && !(events & UV__POLLPRI)) { in uv__poll_io()
55 if (events & POLLIN) in uv__poll_io()
57 if (events & UV__POLLPRI) in uv__poll_io()
59 if (events & POLLOUT) in uv__poll_io()
61 if (events & UV__POLLRDHUP) in uv__poll_io()
122 int events; in uv_poll_start() local
140 events = 0; in uv_poll_start()
142 events |= POLLIN; in uv_poll_start()
144 events |= UV__POLLPRI; in uv_poll_start()
146 events |= POLLOUT; in uv_poll_start()
[all …]
H A Dkqueue.c243 w->events = w->pevents; in uv__io_poll()
287 events, in uv__io_poll()
289 events, in uv__io_poll()
336 ev = events + i; in uv__io_poll()
480 struct kevent* events; in uv__platform_invalidate_fd() local
489 if (events == NULL) in uv__platform_invalidate_fd()
494 if ((int) events[i].ident == fd && events[i].filter != EVFILT_PROC) in uv__platform_invalidate_fd()
495 events[i].ident = -1; in uv__platform_invalidate_fd()
502 int events; in uv__fs_event() local
512 events = UV_CHANGE; in uv__fs_event()
[all …]
H A Dos390.c598 if (events != NULL) in uv__platform_invalidate_fd()
602 events[i].fd = -1; in uv__platform_invalidate_fd()
615 p[0].events = POLLIN; in uv__io_check_fd()
750 int events; in os390_message_queue_handler() local
764 events = 0; in os390_message_queue_handler()
766 events = UV_CHANGE; in os390_message_queue_handler()
768 events = UV_RENAME; in os390_message_queue_handler()
776 events = UV_RENAME; in os390_message_queue_handler()
856 if (w->events == 0) in uv__io_poll()
964 pe = events + i; in uv__io_poll()
[all …]
H A Dsunos.c115 struct port_event* events; in uv__platform_invalidate_fd() local
124 if (events == NULL) in uv__platform_invalidate_fd()
190 w->events = w->pevents; in uv__io_poll()
225 events[0].portev_source = 0; in uv__io_poll()
234 events, in uv__io_poll()
287 pe = events + i; in uv__io_poll()
455 int events; in uv__fs_event_read() local
490 events = 0; in uv__fs_event_read()
492 events |= UV_CHANGE; in uv__fs_event_read()
494 events |= UV_RENAME; in uv__fs_event_read()
[all …]
H A Daix.c118 pc.events = POLLIN; in uv__io_check_fd()
135 struct pollfd events[1024]; in uv__io_poll() local
170 pc.events = w->pevents; in uv__io_poll()
174 if (w->events == 0) { in uv__io_poll()
216 w->events = w->pevents; in uv__io_poll()
297 pe = events + i; in uv__io_poll()
660 *events = 0; in uv__parse_data()
723 int events = 0; in uv__ahafs_event() local
1297 struct pollfd* events; in uv__platform_invalidate_fd() local
1308 if (events != NULL) in uv__platform_invalidate_fd()
[all …]
H A Dstream.c52 int events; member
150 int events; in uv__stream_osx_select() local
214 events = 0; in uv__stream_osx_select()
216 events |= POLLIN; in uv__stream_osx_select()
221 if (events != 0) { in uv__stream_osx_select()
222 ACCESS_ONCE(int, s->events) = events; in uv__stream_osx_select()
237 int events; in uv__stream_osx_select_cb() local
243 events = s->events; in uv__stream_osx_select_cb()
246 assert(events != 0); in uv__stream_osx_select_cb()
247 assert(events == (events & (POLLIN | POLLOUT))); in uv__stream_osx_select_cb()
[all …]
H A Dos390-syscalls.c224 lst->items[lst->size - 1].events = POLLIN; in epoll_create1()
262 lst->items[fd].events = event->events; in epoll_ctl()
270 lst->items[fd].events = event->events; in epoll_ctl()
282 int epoll_wait(uv__os390_epoll* lst, struct epoll_event* events, in epoll_wait() argument
294 if (!lst || !lst->items || !events) { in epoll_wait()
335 ev.events = pfd->revents; in epoll_wait()
339 events[nevents++] = ev; in epoll_wait()
345 ev.events = msg_fd.revents; in epoll_wait()
347 events[nevents++] = ev; in epoll_wait()
H A Dposix-poll.c71 loop->poll_fds[i].events = 0; in uv__pollfds_maybe_resize()
94 loop->poll_fds[i].events = w->pevents; in uv__pollfds_add()
103 pe->events = w->pevents; in uv__pollfds_add()
116 loop->poll_fds[loop->poll_fds_used].events = 0; in uv__pollfds_del()
171 w->events = w->pevents; in uv__io_poll()
357 loop->poll_fds[i].events = 0; in uv__platform_invalidate_fd()
372 p[0].events = POLLIN; in uv__io_check_fd()
H A Dlinux.c584 e.events = POLLIN; in uv__iou_init()
738 e.events = POLLIN; in uv__io_check_fd()
1310 memcpy(oldevents, *events, sizeof(*events)); in uv__epoll_ctl_flush()
1412 if (w->events == 0) in uv__io_poll()
1436 inv.events = events; in uv__io_poll()
1498 pe = events + i; in uv__io_poll()
1552 if (pe->events == POLLERR || pe->events == POLLHUP) in uv__io_poll()
1553 pe->events |= in uv__io_poll()
2575 events = 0; in uv__inotify_read()
2634 int events; in uv_fs_event_start() local
[all …]
H A Dfsevents.c90 int events; member
153 struct uv__queue events; \
159 uv__queue_move(&(handle)->cf_events, &events); \
165 while (!uv__queue_empty(&events)) { \
189 handle->cb(handle, event->path[0] ? event->path : NULL, event->events, 0); in uv__fsevents_cb()
196 struct uv__queue* events, in uv__fsevents_push_event() argument
198 assert(events != NULL || err != 0); in uv__fsevents_push_event()
202 if (events != NULL) in uv__fsevents_push_event()
203 uv__queue_add(&handle->cf_events, events); in uv__fsevents_push_event()
309 event->events = UV_RENAME; in uv__fsevents_event_cb()
[all …]
H A Dos390-syscalls.h42 int events; member
57 int epoll_wait(uv__os390_epoll* ep, struct epoll_event *events, int maxevents, int timeout);
H A Dinternal.h71 # define reqevents events
260 void uv__io_start(uv_loop_t* loop, uv__io_t* w, unsigned int events);
261 void uv__io_stop(uv_loop_t* loop, uv__io_t* w, unsigned int events);
264 int uv__io_active(const uv__io_t* w, unsigned int events);
288 void uv__server_io(uv_loop_t* loop, uv__io_t* w, unsigned int events);
/libuv/test/
H A Dtest-poll.c66 unsigned int events, delayed_events; member
158 context->events = 0; in create_connection_context()
213 ASSERT(events & context->events);
214 ASSERT(!(events & ~context->events));
216 new_events = context->events;
218 if (events & UV_READABLE) {
297 if (events & UV_WRITABLE) {
413 if (events & UV_DISCONNECT) {
426 context->events = 0;
430 context->events = new_events;
[all …]
H A Dbenchmark-queue-work.c26 static unsigned events = 0; variable
41 events++; in after_work_cb()
65 fmt(&fmtbuf[0], events), in BENCHMARK_IMPL()
67 fmt(&fmtbuf[1], events / (timeout / 1000.))); in BENCHMARK_IMPL()
H A Dtest-metrics.c161 ASSERT_UINT64_GT(metrics.events, last_events_count); in close_cb()
164 last_events_count = metrics.events; in close_cb()
173 ASSERT_UINT64_GT(metrics.events, last_events_count); in write_cb()
177 last_events_count = metrics.events; in write_cb()
195 last_events_count = metrics.events; in create_cb()
215 ASSERT_UINT64_EQ(0, metrics.events); in prepare_cb()
251 ASSERT_EQ(metrics.events, metrics.events_waiting); in fs_prepare_cb()
377 ASSERT_GE(metrics.events, 7); in TEST_IMPL()
H A Dtest-fs-event.c55 int events, in fs_event_fail() argument
128 int events, in fail_cb() argument
134 int events, int status) { in fs_event_cb_dir() argument
138 ASSERT_EQ(events, UV_CHANGE); in fs_event_cb_dir()
150 int events, in fs_event_cb_del_dir() argument
155 ASSERT(events == UV_CHANGE || events == UV_RENAME); in fs_event_cb_del_dir()
227 ASSERT(events == UV_CHANGE || events == UV_RENAME); in fs_event_cb_dir_multi_file()
321 ASSERT(events == UV_CHANGE || events == UV_RENAME); in fs_event_cb_dir_multi_file_in_subdir()
350 int events, int status) { in fs_event_cb_file() argument
354 ASSERT_EQ(events, UV_CHANGE); in fs_event_cb_file()
[all …]
H A Dtest-poll-oob.c68 static void poll_cb(uv_poll_t* handle, int status, int events) { in poll_cb() argument
76 if (events & UV_PRIORITIZED) { in poll_cb()
87 if (events & UV_READABLE) { in poll_cb()
127 if (events & UV_WRITABLE) { in poll_cb()
H A Dtest-poll-multiple-handles.c41 static void poll_cb(uv_poll_t* handle, int status, int events) { in poll_cb() argument
43 ASSERT_EQ(events, UV_READABLE); in poll_cb()
/libuv/docs/code/onchange/
H A Dmain.c9 void run_command(uv_fs_event_t *handle, const char *filename, int events, int status) { in run_command() argument
17 if (events & UV_RENAME) in run_command()
19 if (events & UV_CHANGE) in run_command()
/libuv/docs/src/
H A Dpoll.rst44 .. c:type:: void (*uv_poll_cb)(uv_poll_t* handle, int status, int events)
86 .. c:function:: int uv_poll_start(uv_poll_t* handle, int events, uv_poll_cb cb)
88 Starts polling the file descriptor. `events` is a bitmask made up of
91 and the detected events set on the `events` field.
105 file handle and no further events will be reported. The user should
110 fine. Doing so will update the events mask that is being watched for.
114 will not be set on the `events` field in the callback.
117 If one of the events `UV_READABLE` or `UV_WRITABLE` are set, the
135 events set in the bitmask). This behaviour is known as level
H A Dmetrics.rst24 uint64_t events;
38 .. c:member:: uint64_t uv_metrics_t.events
40 Number of events that have been processed by the event handler.
44 Number of events that were waiting to be processed when the event provider
H A Dfs_event.rst22 The z/OS file system events monitoring infrastructure does not notify of file
39 .. c:type:: void (*uv_fs_event_cb)(uv_fs_event_t* handle, const char* filename, int events, int sta…
48 The `events` parameter is an ORed mask of :c:enum:`uv_fs_event` elements.
71 * watch for all events in that directory. This flags overrides this behavior
79 * or kqueue to detect events. This may not work on remote file systems such
116 .. note:: On macOS, events collected by the OS immediately before calling
/libuv/docs/code/uvwget/
H A Dmain.c81 void curl_perform(uv_poll_t *req, int status, int events) { in curl_perform() argument
86 if (!status && events & UV_READABLE) flags |= CURL_CSELECT_IN; in curl_perform()
87 if (!status && events & UV_WRITABLE) flags |= CURL_CSELECT_OUT; in curl_perform()
/libuv/docs/src/guide/
H A Dbasics.rst12 In event-driven programming, an application expresses interest in certain events
13 and respond to them when they occur. The responsibility of gathering events
14 from the operating system or monitoring other sources of events is handled by
20 while there are still events to process:
25 Some examples of events are:
53 queue. The application can inspect the events at its convenience (perhaps doing
59 events can be treated as just another libuv event. The non-blocking ensures
60 that other events can continue to be handled as fast as they come in [#]_.
93 This program quits immediately because it has no events to process. A libuv
94 event loop has to be told to watch out for events using the various API
[all …]

Completed in 53 milliseconds

12