Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Mours <pmours@nvidia.com>2022-09-12 19:46:20 +0300
committerPatrick Mours <pmours@nvidia.com>2022-09-13 11:59:28 +0300
commita45c36efae07f22dd1da1ebac728324aeafce85e (patch)
tree842f27474a4b011786da5ef07ed5c6630e8203a9 /intern/cycles/device/cpu
parent8e03df9bbc22baaf9d538e01c44f6857a8c9b43a (diff)
Cycles: Make OSL implementation independent from SVM
Cleans up the file structure to be more similar to that of the SVM and also makes it possible to build kernels with OSL support, but without having to include SVM support. This patch was split from D15902. Differential Revision: https://developer.blender.org/D15949
Diffstat (limited to 'intern/cycles/device/cpu')
-rw-r--r--intern/cycles/device/cpu/device_impl.cpp1
-rw-r--r--intern/cycles/device/cpu/device_impl.h1
-rw-r--r--intern/cycles/device/cpu/kernel_thread_globals.cpp7
3 files changed, 2 insertions, 7 deletions
diff --git a/intern/cycles/device/cpu/device_impl.cpp b/intern/cycles/device/cpu/device_impl.cpp
index 1e4b9baa0c0..a2b8d1cbbfa 100644
--- a/intern/cycles/device/cpu/device_impl.cpp
+++ b/intern/cycles/device/cpu/device_impl.cpp
@@ -28,7 +28,6 @@
#include "kernel/device/cpu/kernel.h"
#include "kernel/types.h"
-#include "kernel/osl/shader.h"
#include "kernel/osl/globals.h"
// clang-format on
diff --git a/intern/cycles/device/cpu/device_impl.h b/intern/cycles/device/cpu/device_impl.h
index 5c1f3cc6ce5..e7e77f18194 100644
--- a/intern/cycles/device/cpu/device_impl.h
+++ b/intern/cycles/device/cpu/device_impl.h
@@ -23,7 +23,6 @@
#include "kernel/device/cpu/kernel.h"
#include "kernel/device/cpu/globals.h"
-#include "kernel/osl/shader.h"
#include "kernel/osl/globals.h"
// clang-format on
diff --git a/intern/cycles/device/cpu/kernel_thread_globals.cpp b/intern/cycles/device/cpu/kernel_thread_globals.cpp
index 89545399602..99af1525d92 100644
--- a/intern/cycles/device/cpu/kernel_thread_globals.cpp
+++ b/intern/cycles/device/cpu/kernel_thread_globals.cpp
@@ -3,10 +3,7 @@
#include "device/cpu/kernel_thread_globals.h"
-// clang-format off
-#include "kernel/osl/shader.h"
#include "kernel/osl/globals.h"
-// clang-format on
#include "util/profiling.h"
@@ -20,7 +17,7 @@ CPUKernelThreadGlobals::CPUKernelThreadGlobals(const KernelGlobalsCPU &kernel_gl
reset_runtime_memory();
#ifdef WITH_OSL
- OSLShader::thread_init(this, reinterpret_cast<OSLGlobals *>(osl_globals_memory));
+ OSLGlobals::thread_init(this, static_cast<OSLGlobals *>(osl_globals_memory));
#else
(void)osl_globals_memory;
#endif
@@ -35,7 +32,7 @@ CPUKernelThreadGlobals::CPUKernelThreadGlobals(CPUKernelThreadGlobals &&other) n
CPUKernelThreadGlobals::~CPUKernelThreadGlobals()
{
#ifdef WITH_OSL
- OSLShader::thread_free(this);
+ OSLGlobals::thread_free(this);
#endif
}