https://bugs.winehq.org/show_bug.cgi?id=53995
Bug ID: 53995 Summary: d2d1:d2d1 runs out of GL memory and crashes on the debian 11 VM Product: Wine Version: unspecified Hardware: x86-64 OS: Linux Status: NEW Severity: normal Priority: P2 Component: d2d Assignee: wine-bugs@winehq.org Reporter: fgouget@codeweavers.com Distribution: ---
d2d1:d2d1 runs out of GL memory and crashes on the debian 11 VM:
d2d1.c:7145: Test marked todo: Figure does not match. Unhandled exception: page fault on write access to 0x00000000 in 32-bit code (0x6ab30fe4). [...] Backtrace: =>0 0x6ab30fe4 memset+0x24(dst=0x000000000, c=0, n=0x12c000) [Z:\home\winetest\tools\testbot\var\wine\dlls\msvcrt\string.c:3205] in ucrtbase (0x0685f908) 1 0x008a9073 wined3d_texture_load_location+0x423(texture=002CB990, sub_resource_idx=0, context=00289F90, location=0x8) [Z:\home\winetest\tools\testbot\var\wine\dlls\wined3d\texture.c:862] in wined3d (0x0685f9a8) 2 0x00897fce surface_cpu_blt+0x9ee(dst_texture=002CB990, dst_sub_resource_idx=0, dst_box=0685FB38, src_texture=0028D170, src_sub_resource_idx=0, src_box=0685FB50, flags=0x20000000, fx=0685FB68, filter=WINED3D_TEXF_POINT) [Z:\home\winetest\tools\testbot\var\wine\dlls\wined3d\surface.c:752] in wined3d (0x0685faf8) 3 0x00899ac2 cpu_blitter_blit+0xc2(blitter=002BB820, op=WINED3D_BLIT_OP_RAW_BLIT, context=00289F90, src_texture=0028D170, src_sub_resource_idx=0, src_location=0x10, src_rect=0685FE10, dst_texture=002CB990, dst_sub_resource_idx=<is not available>, dst_location=0x8, dst_rect=0685FE20, color_key=00000000, filter=WINED3D_TEXF_POINT, resolve_format=00000000) [Z:\home\winetest\tools\testbot\var\wine\dlls\wined3d\surface.c:1328] in wined3d (0x0685fb98) 4 0x008b7622 ffp_blitter_blit+0xa2(blitter=002BB838, op=WINED3D_BLIT_OP_RAW_BLIT, context=00289F90, src_texture=0028D170, src_sub_resource_idx=0, src_location=0x10, src_rect=0685FE10, dst_texture=002CB990, dst_sub_resource_idx=0, dst_location=0x8, dst_rect=0685FE20, colour_key=00000000, filter=WINED3D_TEXF_POINT, resolve_format=00000000) [Z:\home\winetest\tools\testbot\var\wine\dlls\wined3d\texture.c:6190] in wined3d (0x0685fc58) 5 0x0085d36d glsl_blitter_blit+0x1ad(blitter=002BB850, op=WINED3D_BLIT_OP_RAW_BLIT, context=00289F90, src_texture=0028D170, src_sub_resource_idx=0, src_location=0x10, src_rect=0685FE10, dst_texture=002CB990, dst_sub_resource_idx=0, dst_location=0x8, dst_rect=0685FE20, colour_key=00000000, filter=WINED3D_TEXF_POINT, resolve_format=00000000) [Z:\home\winetest\tools\testbot\var\wine\dlls\wined3d\glsl_shader.c:13270] in wined3d (0x0685fd78) 6 0x0089ada1 texture2d_blt+0x3c1(dst_texture=002CB990, dst_sub_resource_idx=0, dst_box=05B678B4, src_texture=0028D170, src_sub_resource_idx=0, src_box=05B678D4, flags=0x20000000, fx=05B678F0, filter=WINED3D_TEXF_POINT) [Z:\home\winetest\tools\testbot\var\wine\dlls\wined3d\surface.c:1639] in wined3d (0x0685fe48) 7 0x0081b8ad wined3d_cs_exec_blt_sub_resource+0xcd(cs=05B50020, data=05B678A8) [Z:\home\winetest\tools\testbot\var\wine\dlls\wined3d\cs.c:2579] in wined3d (0x0685fec8) 8 0x0081d37b wined3d_cs_command_unlock(queue=<internal error>, cs=<internal error>) [Z:\home\winetest\tools\testbot\var\wine\dlls\wined3d\cs.c:3310] in wined3d (0x0685ff28) 9 0x0081d37b wined3d_cs_execute_next+0x53(ctx=<couldn't compute location>) [Z:\home\winetest\tools\testbot\var\wine\dlls\wined3d\cs.c:3309] in wined3d (0x0685ff28) 10 0x0081d37b wined3d_cs_run+0x13b(ctx=<couldn't compute location>) [Z:\home\winetest\tools\testbot\var\wine\dlls\wined3d\cs.c:3376] in wined3d (0x0685ff28) [...]
7145 is the most common last trace seen, though 7033 also appears at least once, but running with WINETEST_REPORT_SUCCESS I get different locations.
See https://test.winehq.org/data/patterns.html#d2d1:d2d1
Furthermore when reproducing this I saw out-of-memory traces right before the crash. For instance:
d2d1.c:601: Test succeeded 01d8:err:d3d:wined3d_debug_callback 00291C38: "GL_OUT_OF_MEMORY in glBufferStorage". 01d8:err:d3d:wined3d_debug_callback 00291C38: "GL_INVALID_VALUE in glMapBufferRange(offset 0 + length 67108864 > buffer_size 0)". 01d8:err:d3d:wined3d_allocator_chunk_gl_map Failed to map chunk memory. 01d8:err:d3d:wined3d_bo_gl_map Failed to map chunk. 01d8:err:d3d:wined3d_context_gl_map_bo_address Failed to map bo. wine: Unhandled page fault on write access to 00000000 at address 6AB30FE4 (thread 01d8), starting debugger...
It's not clear why only the debian11 VM is impacted: it has a dual-screen configuration but so does debiant so it does not appear to be a multi-monitor thing, and this does not happen on fgtb-debian11 or debian11b so it's not a Debian version issue.