[Bug 33538] rewind-plush 64K demo crashes in wine

wine-bugs at winehq.org wine-bugs at winehq.org
Thu Dec 20 12:27:45 CST 2018


https://bugs.winehq.org/show_bug.cgi?id=33538

Paul Gofman <gofmanp at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |gofmanp at gmail.com

--- Comment #8 from Paul Gofman <gofmanp at gmail.com> ---
Created attachment 63076
  --> https://bugs.winehq.org/attachment.cgi?id=63076
Proof of concept patch

Demo crashes Nvidia opengl driver in glMultiDrawElementsEXT() by enabling
texture coordinate array and not setting a pointer for it for the second
texture (see trace snippet below). Mesa driver lets an application to somehow
get away with that while Nvidia does not. I am attaching a proof of concept
patch which works around the crash.

The rendering is still glitchy though. It can be made better (white screens
avoided) by running with WINDEBUG=warn+heap. I suppose there is some
uninitialized or out of bounds memory access involved which is workarounded by
memory initialization done in heap management code when warnings are on
(somehow it does not like zero initialized memory space). I was not fully
tracking this part of the mess though.

As a bottom line, it does not look like a Wine bug or even something that can
be sensibly worked around on the Wine side. The only "fix" I could imagine is
re-implementing opengl state tracker on the Wine side to workaround the
undefined behaviour cases, which does not make any sense.

---- snip ----
...
0009:trace:opengl:glEnd ()
0009:trace:opengl:glPopMatrix ()
0009:trace:opengl:glMatrixMode (5889)
0009:trace:opengl:glPopMatrix ()
0009:trace:opengl:glMatrixMode (5888)
0009:trace:opengl:glEnable (2929)
0009:trace:opengl:glColor4f (0.937000, 0.686000, 0.086000, 1.000000)
0009:trace:opengl:glActiveTextureARB (33984)
0009:trace:opengl:glEnable (3553)
0009:trace:opengl:glPushMatrix ()
0009:trace:opengl:glRotatef (90.000000, 1.000000, 0.000000, 0.000000)
0009:trace:opengl:glFrontFace (2304)
0009:trace:opengl:glEnableClientState (32884)
0009:trace:opengl:glEnableClientState (32888)
0009:trace:opengl:glClientActiveTextureARB (33985)
0009:trace:opengl:glEnableClientState (32888)
0009:trace:opengl:glClientActiveTextureARB (33984)
0009:trace:opengl:glBindTexture (3553, 8)
0009:trace:opengl:glVertexPointer (3, 5126, 20, 0xe38368)
0009:trace:opengl:glTexCoordPointer (2, 5126, 20, 0xe38374)
0009:trace:opengl:glMultiDrawElementsEXT (5, 0xe38c10, 5125, 0xe38c38, 8)
---- snip ---

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list