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:
authorBrecht Van Lommel <brechtvanlommel@gmail.com>2018-11-30 01:30:17 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2018-11-30 01:43:27 +0300
commita8b8da55672c2177c55709321df3514355b513f4 (patch)
tree97c730a1b39e60ecd15ad5c73b63892329daae1e /intern/cycles/device/opencl
parent8ac2d85d2fd3f8b997e9c9bddadada0dc7bdaf37 (diff)
Fix T58183: crash with CPU + GPU rendering after profiling changes.
Multi-device was not passing along profiler to the CPU.
Diffstat (limited to 'intern/cycles/device/opencl')
-rw-r--r--intern/cycles/device/opencl/opencl.h6
-rw-r--r--intern/cycles/device/opencl/opencl_base.cpp4
-rw-r--r--intern/cycles/device/opencl/opencl_mega.cpp8
-rw-r--r--intern/cycles/device/opencl/opencl_split.cpp10
4 files changed, 14 insertions, 14 deletions
diff --git a/intern/cycles/device/opencl/opencl.h b/intern/cycles/device/opencl/opencl.h
index 8cb7f6d0b82..ea7ed4f1909 100644
--- a/intern/cycles/device/opencl/opencl.h
+++ b/intern/cycles/device/opencl/opencl.h
@@ -333,7 +333,7 @@ public:
void opencl_error(const string& message);
void opencl_assert_err(cl_int err, const char* where);
- OpenCLDeviceBase(DeviceInfo& info, Stats &stats, bool background_);
+ OpenCLDeviceBase(DeviceInfo& info, Stats &stats, Profiler &profiler, bool background_);
~OpenCLDeviceBase();
static void CL_CALLBACK context_notify_callback(const char *err_info,
@@ -568,8 +568,8 @@ protected:
void flush_texture_buffers();
};
-Device *opencl_create_mega_device(DeviceInfo& info, Stats& stats, bool background);
-Device *opencl_create_split_device(DeviceInfo& info, Stats& stats, bool background);
+Device *opencl_create_mega_device(DeviceInfo& info, Stats& stats, Profiler &profiler, bool background);
+Device *opencl_create_split_device(DeviceInfo& info, Stats& stats, Profiler &profiler, bool background);
CCL_NAMESPACE_END
diff --git a/intern/cycles/device/opencl/opencl_base.cpp b/intern/cycles/device/opencl/opencl_base.cpp
index 1e73d37d7a4..d4d7c0f74bc 100644
--- a/intern/cycles/device/opencl/opencl_base.cpp
+++ b/intern/cycles/device/opencl/opencl_base.cpp
@@ -72,8 +72,8 @@ void OpenCLDeviceBase::opencl_assert_err(cl_int err, const char* where)
}
}
-OpenCLDeviceBase::OpenCLDeviceBase(DeviceInfo& info, Stats &stats, bool background_)
-: Device(info, stats, background_),
+OpenCLDeviceBase::OpenCLDeviceBase(DeviceInfo& info, Stats &stats, Profiler &profiler, bool background_)
+: Device(info, stats, profiler, background_),
memory_manager(this),
texture_info(this, "__texture_info", MEM_TEXTURE)
{
diff --git a/intern/cycles/device/opencl/opencl_mega.cpp b/intern/cycles/device/opencl/opencl_mega.cpp
index 89001366d9d..0a7bf96fed7 100644
--- a/intern/cycles/device/opencl/opencl_mega.cpp
+++ b/intern/cycles/device/opencl/opencl_mega.cpp
@@ -33,8 +33,8 @@ class OpenCLDeviceMegaKernel : public OpenCLDeviceBase
public:
OpenCLProgram path_trace_program;
- OpenCLDeviceMegaKernel(DeviceInfo& info, Stats &stats, bool background_)
- : OpenCLDeviceBase(info, stats, background_),
+ OpenCLDeviceMegaKernel(DeviceInfo& info, Stats &stats, Profiler &profiler, bool background_)
+ : OpenCLDeviceBase(info, stats, profiler, background_),
path_trace_program(this, "megakernel", "kernel.cl", "-D__COMPILE_ONLY_MEGAKERNEL__ ")
{
}
@@ -160,9 +160,9 @@ public:
}
};
-Device *opencl_create_mega_device(DeviceInfo& info, Stats& stats, bool background)
+Device *opencl_create_mega_device(DeviceInfo& info, Stats& stats, Profiler &profiler, bool background)
{
- return new OpenCLDeviceMegaKernel(info, stats, background);
+ return new OpenCLDeviceMegaKernel(info, stats, profiler, background);
}
CCL_NAMESPACE_END
diff --git a/intern/cycles/device/opencl/opencl_split.cpp b/intern/cycles/device/opencl/opencl_split.cpp
index adb73bc6e2c..5a2555f9f80 100644
--- a/intern/cycles/device/opencl/opencl_split.cpp
+++ b/intern/cycles/device/opencl/opencl_split.cpp
@@ -79,7 +79,7 @@ public:
OpenCLProgram program_data_init;
OpenCLProgram program_state_buffer_size;
- OpenCLDeviceSplitKernel(DeviceInfo& info, Stats &stats, bool background_);
+ OpenCLDeviceSplitKernel(DeviceInfo& info, Stats &stats, Profiler &profiler, bool background_);
~OpenCLDeviceSplitKernel()
{
@@ -448,17 +448,17 @@ public:
}
};
-OpenCLDeviceSplitKernel::OpenCLDeviceSplitKernel(DeviceInfo& info, Stats &stats, bool background_)
-: OpenCLDeviceBase(info, stats, background_)
+OpenCLDeviceSplitKernel::OpenCLDeviceSplitKernel(DeviceInfo& info, Stats &stats, Profiler &profiler, bool background_)
+: OpenCLDeviceBase(info, stats, profiler, background_)
{
split_kernel = new OpenCLSplitKernel(this);
background = background_;
}
-Device *opencl_create_split_device(DeviceInfo& info, Stats& stats, bool background)
+Device *opencl_create_split_device(DeviceInfo& info, Stats& stats, Profiler &profiler, bool background)
{
- return new OpenCLDeviceSplitKernel(info, stats, background);
+ return new OpenCLDeviceSplitKernel(info, stats, profiler, background);
}
CCL_NAMESPACE_END