Blender Git Loki

Git Commits -> Revision 1b4f0bf

Revision 1b4f0bf by Sergey Sharybin (master)
May 3, 2021, 13:07 (GMT)
Fix T87989: Crash using OpenCL in compositor

Initial report was mentioning the Classroom demo scene, but this is
probably because the scene was pre-configured to be used with OpenCL.
Would expect any OpenCL compositing to be failing prior to this fix.

The reason why crash was happening is due to OpenCL queue being
released from OpenCLDevice destructor. Is not that obvious, but
when Vector (including std::vector) is holding elements by value
a destructor will be called on "old" memory when vector capacitance
changes.

Solved by making forbidding copy semantic for compositor devices and
forcing move semantic to be used.

Also use emplace semantic in the devices vector initialization.

Commit Details:

Full Hash: 1b4f0bf32aa5215325ca33f81898a7eeef9da2f8
Parent Commit: 6899dbe
Lines Changed: +26, -5

4 Modified Paths:

/source/blender/compositor/intern/COM_Device.h (+8, -0) (Diff)
/source/blender/compositor/intern/COM_OpenCLDevice.cc (+10, -0) (Diff)
/source/blender/compositor/intern/COM_OpenCLDevice.h (+3, -0) (Diff)
/source/blender/compositor/intern/COM_WorkScheduler.cc (+5, -5) (Diff)
Tehnyt: Miika HämäläinenViimeksi päivitetty: 07.11.2014 14:18MiikaH:n Sivut a.k.a. MiikaHweb | 2003-2021