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:
authorLukas Stockner <lukas.stockner@freenet.de>2016-10-17 12:48:24 +0300
committerLukas Stockner <lukas.stockner@freenet.de>2016-10-17 12:51:18 +0300
commitd5dd12e56cd142c8d95cdb538658bae45a3f510c (patch)
tree24e34936c1ae49a8a0e58e10fdc427134e9d77ed /intern/cycles/device/opencl/opencl.h
parent2a6ec00b9b083e8c235ec4721d6fa67b9bee4794 (diff)
Cycles: Improve OpenCL kernel compilation logging
The previous refactor changed the code to use a separate logging mechanism to support multithreaded compilation. However, since that's not supported by any frameworks yes, it just resulted in bad logging behaviour. So, this commit changes the logging to go diectly to stdout/stderr once again by default.
Diffstat (limited to 'intern/cycles/device/opencl/opencl.h')
-rw-r--r--intern/cycles/device/opencl/opencl.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/intern/cycles/device/opencl/opencl.h b/intern/cycles/device/opencl/opencl.h
index 032a97aba67..30a35acbb2a 100644
--- a/intern/cycles/device/opencl/opencl.h
+++ b/intern/cycles/device/opencl/opencl.h
@@ -191,7 +191,8 @@ public:
OpenCLProgram(OpenCLDeviceBase *device,
string program_name,
string kernel_name,
- string kernel_build_options);
+ string kernel_build_options,
+ bool use_stdout = true);
~OpenCLProgram();
void add_kernel(ustring name);
@@ -212,6 +213,9 @@ public:
bool load_binary(const string& clbin, const string *debug_src = NULL);
bool save_binary(const string& clbin);
+ void add_log(string msg, bool is_debug);
+ void add_error(string msg);
+
bool loaded;
cl_program program;
OpenCLDeviceBase *device;
@@ -220,8 +224,10 @@ public:
string program_name;
string kernel_file, kernel_build_options, device_md5;
- string error_msg, output_msg;
- string log;
+
+ bool use_stdout;
+ string log, error_msg;
+ string compile_output;
map<ustring, cl_kernel> kernels;
};