fea1d57c2b
First, issue glMemoryBarrier() only if the read-after-write or write-after-write occurs for a write involving incoherent memory access. In practice this means a QRhiTexture with UsedWithLoadStore or a QRhiBuffer used as an SSBO. Doing the barrier call for other types of texture or buffers is pointless, and potentially wasteful. What is more, some OpenGL implementations feature bugs that manifest themselves when glMemoryBarrier() is called, see associated Jira issue for details. Second, reduce GL_ALL_BARRIER_BITS to the ones relevant for the type of the resource, in an attempt to provide a minor optimization. Real fine-grained resource usage tracking is not implemented for OpenGL so this still means specifying all buffer-related or all texture-related barriers together, but this is still better than all. As the usage of compute is quite close to zero in Qt at the moment, this won't make much of a difference in practice. Fixes: QTBUG-96322 Pick-to: 6.2 Change-Id: Ibf794e2e8a4cbc3c69acaa88476e85de6646b605 Reviewed-by: Andy Nichols <andy.nichols@qt.io> |
||
---|---|---|
.github/workflows | ||
bin | ||
cmake | ||
coin | ||
config.tests | ||
dist | ||
doc | ||
examples | ||
lib | ||
libexec | ||
mkspecs | ||
qmake | ||
src | ||
tests | ||
util | ||
.cmake.conf | ||
.gitattributes | ||
.gitignore | ||
.lgtm.yml | ||
.tag | ||
CMakeLists.txt | ||
conanfile.py | ||
config_help.txt | ||
configure | ||
configure.bat | ||
configure.cmake | ||
dependencies.yaml | ||
LICENSE.FDL | ||
LICENSE.GPL2 | ||
LICENSE.GPL3 | ||
LICENSE.GPL3-EXCEPT | ||
LICENSE.LGPL3 | ||
LICENSE.LGPLv3 | ||
LICENSE.QT-LICENSE-AGREEMENT | ||
qt_cmdline.cmake | ||
sync.profile |