summaryrefslogtreecommitdiffhomepage
path: root/src/nxt_event_engine.h
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2017-01-27 11:35:11 +0300
committerIgor Sysoev <igor@sysoev.ru>2017-01-27 11:35:11 +0300
commitba0391577b06446307fa073f856f57748557e0dd (patch)
treeb2b871a041edee242662c95197bed292531c3a9a /src/nxt_event_engine.h
parent6886b83c1f3bfdc514d58ad6e9ab40873cafcb54 (diff)
downloadunit-ba0391577b06446307fa073f856f57748557e0dd.tar.gz
unit-ba0391577b06446307fa073f856f57748557e0dd.tar.bz2
Work queues refactoring.
Diffstat (limited to 'src/nxt_event_engine.h')
-rw-r--r--src/nxt_event_engine.h19
1 files changed, 6 insertions, 13 deletions
diff --git a/src/nxt_event_engine.h b/src/nxt_event_engine.h
index 1ff1399a..54b3bcde 100644
--- a/src/nxt_event_engine.h
+++ b/src/nxt_event_engine.h
@@ -33,6 +33,9 @@ struct nxt_event_engine_s {
*/
nxt_event_engine_pipe_t *pipe;
+ nxt_work_queue_cache_t work_queue_cache;
+ nxt_work_queue_t *current_work_queue;
+ nxt_work_queue_t fast_work_queue;
nxt_work_queue_t accept_work_queue;
nxt_work_queue_t read_work_queue;
nxt_work_queue_t socket_work_queue;
@@ -40,8 +43,9 @@ struct nxt_event_engine_s {
nxt_work_queue_t write_work_queue;
nxt_work_queue_t shutdown_work_queue;
nxt_work_queue_t close_work_queue;
+ nxt_work_queue_t final_work_queue;
- nxt_locked_work_queue_t work_queue;
+ nxt_locked_work_queue_t locked_work_queue;
nxt_event_signals_t *signals;
@@ -68,8 +72,7 @@ NXT_EXPORT void nxt_event_engine_free(nxt_event_engine_t *engine);
NXT_EXPORT void nxt_event_engine_start(nxt_event_engine_t *engine);
NXT_EXPORT void nxt_event_engine_post(nxt_event_engine_t *engine,
- nxt_work_handler_t handler, nxt_task_t *task, void *obj, void *data,
- nxt_log_t *log);
+ nxt_work_t *work);
NXT_EXPORT void nxt_event_engine_signal(nxt_event_engine_t *engine,
nxt_uint_t signo);
@@ -84,14 +87,4 @@ nxt_thread_event_engine(void)
}
-nxt_inline nxt_work_queue_t *
-nxt_thread_main_work_queue(void)
-{
- nxt_thread_t *thr;
-
- thr = nxt_thread();
- return &thr->work_queue.main;
-}
-
-
#endif /* _NXT_EVENT_ENGINE_H_INCLUDED_ */