10.6.1 A Prolog thread for each native thread (one-to-one)
AllApplicationManualNameSummaryHelp

  • Documentation
    • Reference manual
      • Multithreaded applications
        • Multithreaded mixed C and Prolog applications
          • A Prolog thread for each native thread (one-to-one)
            • PL_thread_self()
            • PL_unify_thread_id()
            • PL_thread_attach_engine()
            • PL_thread_destroy_engine()
            • PL_thread_at_exit()
    • Packages
Availability:C-language interface function
int PL_thread_destroy_engine()
Destroy the Prolog engine in the calling thread. Only takes effect if PL_thread_destroy_engine() is called as many times as PL_thread_attach_engine() in this thread. Returns TRUE on success and FALSE if the calling thread has no engine or this Prolog does not support threads.

Please note that construction and destruction of engines are relatively expensive operations. Only destroy an engine if performance is not critical and memory is a critical resource.