Fix T53017: Cycles not detecting AMD GPU when there is an NVidia GPU too.
Best guess is that cuInit() somehow interferes with the AMD graphics driver on Windows, and switching the initialization order to do OpenCL first seems to solve the issue.
This commit is contained in:
parent
4f247ed07a
commit
1f50f0676a
|
@ -324,16 +324,17 @@ vector<DeviceInfo>& Device::available_devices()
|
|||
{
|
||||
if(need_devices_update) {
|
||||
devices.clear();
|
||||
#ifdef WITH_CUDA
|
||||
if(device_cuda_init())
|
||||
device_cuda_info(devices);
|
||||
#endif
|
||||
|
||||
#ifdef WITH_OPENCL
|
||||
if(device_opencl_init())
|
||||
device_opencl_info(devices);
|
||||
#endif
|
||||
|
||||
#ifdef WITH_CUDA
|
||||
if(device_cuda_init())
|
||||
device_cuda_info(devices);
|
||||
#endif
|
||||
|
||||
device_cpu_info(devices);
|
||||
|
||||
#ifdef WITH_NETWORK
|
||||
|
@ -350,12 +351,6 @@ string Device::device_capabilities()
|
|||
{
|
||||
string capabilities = "CPU device capabilities: ";
|
||||
capabilities += device_cpu_capabilities() + "\n";
|
||||
#ifdef WITH_CUDA
|
||||
if(device_cuda_init()) {
|
||||
capabilities += "\nCUDA device capabilities:\n";
|
||||
capabilities += device_cuda_capabilities();
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef WITH_OPENCL
|
||||
if(device_opencl_init()) {
|
||||
|
@ -364,6 +359,13 @@ string Device::device_capabilities()
|
|||
}
|
||||
#endif
|
||||
|
||||
#ifdef WITH_CUDA
|
||||
if(device_cuda_init()) {
|
||||
capabilities += "\nCUDA device capabilities:\n";
|
||||
capabilities += device_cuda_capabilities();
|
||||
}
|
||||
#endif
|
||||
|
||||
return capabilities;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue