diff --git a/src/PikaObj.c b/src/PikaObj.c index 4bfa00b96..729760210 100644 --- a/src/PikaObj.c +++ b/src/PikaObj.c @@ -1944,6 +1944,7 @@ void _do_pks_eventListener_send(PikaEventListener* self, _VMEvent_pickupEvent(); } } +#if PIKA_EVENT_THREAD_ENABLE if (PikaVMSignal.event_thread_inited) { return; } @@ -1956,6 +1957,7 @@ void _do_pks_eventListener_send(PikaEventListener* self, PikaVMSignal.event_thread_inited = 1; } #endif +#endif } void pks_eventListener_send(PikaEventListener* self, diff --git a/src/pika_config_valid.h b/src/pika_config_valid.h index 1c4f7284b..6a9bdeb27 100644 --- a/src/pika_config_valid.h +++ b/src/pika_config_valid.h @@ -76,6 +76,11 @@ #ifdef PIKA_TYPE_FULL_FEATURE_ENABLE #define PIKA_TYPE_FULL_FEATURE_ENABLE 0 #endif + + #ifndef PIKA_EVENT_THREAD_ENABLE + #define PIKA_EVENT_THREAD_ENABLE 0 + #endif + #endif /* default optimize */ @@ -418,6 +423,10 @@ #define PIKA_TYPE_FULL_FEATURE_ENABLE 1 #endif + #ifndef PIKA_EVENT_THREAD_ENABLE + #define PIKA_EVENT_THREAD_ENABLE 1 + #endif + /* configuration validation */ #endif