diff --git a/src/gctools/threadlocal.cc b/src/gctools/threadlocal.cc index 4017d7c7a1..9ccd67eb31 100644 --- a/src/gctools/threadlocal.cc +++ b/src/gctools/threadlocal.cc @@ -25,9 +25,6 @@ THREAD_LOCAL gctools::ThreadLocalStateLowLevel* my_thread_low_level; THREAD_LOCAL core::ThreadLocalState* my_thread; -namespace gctools { -thread_pool* global_thread_pool; -}; namespace core { #ifdef DEBUG_VIRTUAL_MACHINE @@ -244,11 +241,7 @@ pid_t ThreadLocalState::safe_fork() { // Wrap fork in code that turns guards off and on this->_VM.disable_guards(); - // shut down llvm thread pool - gctools::global_thread_pool->~thread_pool(); pid_t result = fork(); - // start up llvm thread pool - gctools::global_thread_pool = new thread_pool(thread_pool::sane_number_of_threads()); if (result==-1) { // error printf("%s:%d:%s fork failed errno = %d\n", __FILE__, __LINE__, __FUNCTION__, errno ); diff --git a/src/llvmo/runtimeJit.cc b/src/llvmo/runtimeJit.cc index 881df43271..2678b0b5e2 100644 --- a/src/llvmo/runtimeJit.cc +++ b/src/llvmo/runtimeJit.cc @@ -679,8 +679,8 @@ namespace llvmo { /*! Call this after fork() to create a thread-pool for lljit */ CL_DEFUN void llvm_sys__create_lljit_thread_pool() { - gctools::global_thread_pool = new thread_pool(thread_pool::sane_number_of_threads()); #if 0 + gctools::global_thread_pool = new thread_pool(thread_pool::sane_number_of_threads()); ClaspJIT_O* jit = &*gctools::As(_lisp->_Roots._ClaspJIT); jit->_LLJIT->getExecutionSession().setDispatchTask([jit](std::unique_ptr T) { DEBUG_OBJECT_FILES_PRINT(("%s:%d:%s pushing an LLJIT task\n", __FILE__, __LINE__, __FUNCTION__ ));