Commit 12aead29 authored by Joseph Noir's avatar Joseph Noir

the OpenCL context is now created for all devices

The clCreateContext previously ignored all devices but the first,
a context should now be created for all present devices.
parent c5e6d286
......@@ -95,7 +95,12 @@ void opencl_metainfo::initialize()
// create a context
m_context.adopt(clCreateContext(0, 1, devices.data(), nullptr, nullptr, &err));
m_context.adopt(clCreateContext(0,
devices.size(),
devices.data(),
nullptr,
nullptr,
&err));
if (err != CL_SUCCESS) {
ostringstream oss;
oss << "clCreateContext: " << get_opencl_error(err);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment