From 5ce9edee820aa3765ffeb02363fbb2b0bcfabd1f Mon Sep 17 00:00:00 2001 From: Miroslaw Pawlowski Date: Tue, 13 Aug 2024 18:26:16 +0200 Subject: [PATCH] Explicit shutdownTaskingSystem() call --- cmake/ospray_options.cmake | 2 +- ospray/api/Device.cpp | 6 ++++++ ospray/api/Device.h | 2 +- scripts/superbuild/CMakeLists.txt | 6 +++--- 4 files changed, 11 insertions(+), 5 deletions(-) diff --git a/cmake/ospray_options.cmake b/cmake/ospray_options.cmake index ab28134f8..cae4c0fce 100644 --- a/cmake/ospray_options.cmake +++ b/cmake/ospray_options.cmake @@ -12,7 +12,7 @@ set(OSPRAY_CMAKECONFIG_DIR "${CMAKE_INSTALL_LIBDIR}/cmake/ospray-${OSPRAY_VERSION}") set(ISPC_VERSION_REQUIRED 1.23.0) -set(RKCOMMON_VERSION_REQUIRED 1.14.1) +set(RKCOMMON_VERSION_REQUIRED 1.14.2) set(EMBREE_VERSION_REQUIRED 4.3.3) set(OPENVKL_VERSION_REQUIRED 2.0.1) set(OIDN_VERSION_REQUIRED 2.3.0) diff --git a/ospray/api/Device.cpp b/ospray/api/Device.cpp index 6ec994d77..40cf1bf3c 100644 --- a/ospray/api/Device.cpp +++ b/ospray/api/Device.cpp @@ -47,6 +47,12 @@ Device *Device::createInstance(const char *type) memory::IntrusivePtr Device::current; uint32_t Device::logLevel = OSP_LOG_NONE; +Device::~Device() +{ + // Terminate all worker threads + tasking::shutdownTaskingSystem(); +} + Device *Device::createDevice(const char *type) { // NOTE(jda) - If a user is manually creating the device (i.e. not using diff --git a/ospray/api/Device.h b/ospray/api/Device.h index 2b2aad924..a068a02a2 100644 --- a/ospray/api/Device.h +++ b/ospray/api/Device.h @@ -35,7 +35,7 @@ struct OSPRAY_CORE_INTERFACE Device : public memory::RefCountedObject, static memory::IntrusivePtr current; Device() = default; - virtual ~Device() override = default; + virtual ~Device() override; static Device *createDevice(const char *type); diff --git a/scripts/superbuild/CMakeLists.txt b/scripts/superbuild/CMakeLists.txt index c896c2033..88b953480 100644 --- a/scripts/superbuild/CMakeLists.txt +++ b/scripts/superbuild/CMakeLists.txt @@ -110,9 +110,9 @@ else() mark_as_advanced(FORCE ISPC_VERSION) endif() -set(RKCOMMON_VERSION "1.14.1" CACHE STRING "Which version of rkcommon to build?") -if (RKCOMMON_VERSION STREQUAL "1.14.1") - set(RKCOMMON_HASH "39f69a9434cf8ad3d3d7c8413f47395f6d693b415559a178c391e4833721ebf3") +set(RKCOMMON_VERSION "1.14.2" CACHE STRING "Which version of rkcommon to build?") +if (RKCOMMON_VERSION STREQUAL "1.14.2") + set(RKCOMMON_HASH "79334ef3dadddb03ec0483fbf49bf690fb8902d5c2732d977b2c116651484cc6") endif() option(DOWNLOAD_TBB "Download TBB or use the one found in the system environment?" ON)