1 #ifndef _MONO_THREADPOOL_INTERNALS_H_
2 #define _MONO_THREADPOOL_INTERNALS_H_
5 #include <mono/metadata/object.h>
6 #include <mono/metadata/mono-hash.h>
7 #include <mono/metadata/mono-mlist.h>
8 #include <mono/utils/mono-compiler.h>
9 #include <mono/utils/mono-mutex.h>
12 mono_mutex_t io_lock; /* access to sock_to_state */
13 int inited; // 0 -> not initialized , 1->initializing, 2->initialized, 3->cleaned up
14 MonoGHashTable *sock_to_state;
18 void (*modify) (gpointer p, int fd, int operation, int events, gboolean is_new);
19 void (*wait) (gpointer sock_data);
20 void (*shutdown) (gpointer event_data);
23 void mono_thread_pool_remove_socket (int sock);
24 gboolean mono_thread_pool_is_queue_array (MonoArray *o);
25 void mono_internal_thread_unhandled_exception (MonoObject* exc);
27 //TP internals the impls use
28 void check_for_interruption_critical (void);
29 void socket_io_cleanup (SocketIOData *data);
30 MonoObject *get_io_event (MonoMList **list, gint event);
31 int get_events_from_list (MonoMList *list);
32 void threadpool_append_async_io_jobs (MonoObject **jobs, gint njobs);