Module: wine Branch: master Commit: 5529b00a4479948d279ccc8cad0a53de01a97f46 URL: https://gitlab.winehq.org/wine/wine/-/commit/5529b00a4479948d279ccc8cad0a53d...
Author: Aida Jonikienė aidas957@gmail.com Date: Sun Nov 26 11:51:27 2023 +0200
opengl32: Add a FIXME when doing a mapped buffer copy.
The copies of mapped buffers introduce significant performance overhead.
---
dlls/opengl32/unix_wgl.c | 5 +++++ 1 file changed, 5 insertions(+)
diff --git a/dlls/opengl32/unix_wgl.c b/dlls/opengl32/unix_wgl.c index e03bbc0a9c0..453a9824046 100644 --- a/dlls/opengl32/unix_wgl.c +++ b/dlls/opengl32/unix_wgl.c @@ -1855,10 +1855,15 @@ static void unmap_named_buffer( TEB *teb, GLint buffer ) static NTSTATUS wow64_map_buffer( TEB *teb, GLint buffer, GLenum target, void *ptr, SIZE_T size, GLbitfield access, PTR32 *ret ) { + static unsigned int once; + if (*ret) /* wow64 pointer provided, map buffer to it */ { if (!(access & (GL_MAP_INVALIDATE_RANGE_BIT | GL_MAP_INVALIDATE_BUFFER_BIT))) { + if (!once++) + FIXME( "Doing a copy of a mapped buffer (expect performance issues)\n" ); + TRACE( "Copying %#zx from buffer at %p to wow64 buffer %p\n", size, ptr, UlongToPtr(*ret) ); memcpy( UlongToPtr(*ret), ptr, size ); }