mirror of
https://github.com/blender/blender
synced 2026-09-29 04:37:17 +03:00
Fix OpenCL render error in large scenes
In scenes such as Cosmos Laundromat, there were memory allocations bigger than 2GB which would overflow. Problem and solution found by AMD, thanks!
This commit is contained in:
parent
6144b5bd4e
commit
094addfe84
1 changed files with 1 additions and 1 deletions
|
|
@ -65,7 +65,7 @@ void MemoryManager::DeviceBuffer::update_device_memory(OpenCLDevice *device)
|
|||
}
|
||||
|
||||
/* Always allocate non-empty buffer, NULL pointers cause problems with some drivers. */
|
||||
total_size = max(total_size, 16);
|
||||
total_size = std::max(total_size, (size_t)16);
|
||||
|
||||
if (need_realloc) {
|
||||
cl_ulong max_buffer_size;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue