[PATCH 1/6] wined3d: Keep track of a thread's wined3d context.

Alexandre Julliard julliard at winehq.org
Wed Jul 22 06:04:19 CDT 2009


Henri Verbeet <hverbeet at codeweavers.com> writes:

> ---
>  dlls/wined3d/context.c         |   81 +++++++++++++++++++++++++++++----------
>  dlls/wined3d/wined3d_main.c    |   40 ++++++++++++++++++++
>  dlls/wined3d/wined3d_private.h |    5 ++
>  3 files changed, 105 insertions(+), 21 deletions(-)

It doesn't work here:

../../../tools/runtest -q -P wine -M ddraw.dll -T ../../.. -p ddraw_test.exe.so d3d.c && touch d3d.ok
wine: Unhandled page fault on read access to 0x005cab9c at address 0x68e9e94a (thread 0043), starting debugger...
Unhandled exception: page fault on read access to 0x005cab9c in 32-bit code (0x68e9e94a).
Register dump:
 CS:0023 SS:002b DS:002b ES:002b FS:0063 GS:006b
 EIP:68e9e94a ESP:0032f7b0 EBP:0032f7d8 EFLAGS:00010206(  R- --  I   - -P- )
 EAX:0012e9d8 EBX:68ef4194 ECX:00000001 EDX:0012e9d8
 ESI:001bbda0 EDI:00000000
Stack dump:
0x0032f7b0:  000084e0 0032f7c8 00185bf0 0012ea18
0x0032f7c0:  00000000 00000000 0012e9d8 68ef4194
0x0032f7d0:  00000000 001bbda0 0032f908 68ea9045
0x0032f7e0:  0012e9d8 00000000 00000001 0032f8f8
0x0032f7f0:  0032f8f4 0032f8f0 0032f8ec 0032f8e8
0x0032f800:  00000000 00000000 00000000 00000000
Backtrace:
=>0 0x68e9e94a surface_bind_and_dirtify+0x4a(This=0x1bbda0, srgb=0) [/home/julliard/wine/wine/dlls/wined3d/surface.c:321] in wined3d (0x0032f7d8)
  1 0x68ea9045 IWineD3DSurfaceImpl_LoadLocation+0x185(iface=<register EDI not in topmost frame>, flag=64, rect=(nil)) [/home/julliard/wine/wine/dlls/wined3d/surface.c:4878] in wined3d (0x0032f908)
  2 0x68e9b17e IWineD3DSurfaceImpl_LoadTexture+0x5e(iface=<register EDI not in topmost frame>, srgb_mode=0) [/home/julliard/wine/wine/dlls/wined3d/surface.c:2598] in wined3d (0x0032f938)
  3 0x68e9e70b surface_internal_preload+0xcb(iface=<register ESI not in topmost frame>, srgb=SRGB_RGB) [/home/julliard/wine/wine/dlls/wined3d/surface.c:804] in wined3d (0x0032f978)
  4 0x68dfc756 context_apply_attachment_filter_states+0xf6(surface=<register ESI not in topmost frame>, force_preload=<is not available>) [/home/julliard/wine/wine/dlls/wined3d/context.c:181] in wined3d (0x0032f9e8)
  5 0x68dfcd4c context_attach_depth_stencil_fbo+0x9c(context=0x185bf0, fbo_target=36160, depth_stencil=<register ESI not in topmost frame>, use_render_buffer=0) [/home/julliard/wine/wine/dlls/wined3d/context.c:223] in wined3d (0x0032fab8)
  6 0x68ea80e4 surface_load_ds_location+0x414(iface=<register EDI not in topmost frame>, location=4194304) [/home/julliard/wine/wine/dlls/wined3d/surface.c:4448] in wined3d (0x0032fb88)
  7 0x68e1391a IWineD3DDeviceImpl_SetDepthStencilSurface+0x1aa(iface=<register EDI not in topmost frame>, pNewZStencil=(nil)) [/home/julliard/wine/wine/dlls/wined3d/device.c:6613] in wined3d (0x0032fbb8)
  8 0x686b8e2f IDirectDrawSurfaceImpl_Release+0x32f(iface=0x128ab8) [/home/julliard/wine/wine/dlls/ddraw/surface.c:315] in ddraw (0x0032fc08)
  9 0x686550bd func_d3d+0x16ad() [/home/julliard/wine/wine/dlls/ddraw/tests/d3d.c:178] in ddraw_test (0x0032fde8)
  10 0x68674640 run_test+0x130(name="d3d.c") [/home/julliard/wine/wine/dlls/ddraw/tests/../../../include/wine/test.h:456] in ddraw_test (0x0032fe28)
  11 0x6867482e main+0x11e(argc=<register ECX not in topmost frame>, argv=<register ECX not in topmost frame>) [/home/julliard/wine/wine/dlls/ddraw/tests/../../../include/wine/test.h:505] in ddraw_test (0x0032fed8)
  12 0x68675044 __wine_spec_exe_entry+0x84(peb=0x7ffdf000) [/home/julliard/wine/wine/dlls/winecrt0/exe_entry.c:36] in ddraw_test (0x0032ff08)
  13 0x7b878c90 start_process+0x130(arg=(nil)) [/home/julliard/wine/wine/dlls/kernel32/process.c:955] in kernel32 (0x0032ffe8)
  14 0x6802bc7d wine_call_on_stack+0x1d() in libwine.so.1 (0x00000000)
0x68e9e94a surface_bind_and_dirtify+0x4a [/home/julliard/wine/wine/dlls/wined3d/surface.c:321] in wined3d: movl	0xfffe1a64(%edx,%eax,4),%eax
321	    active_sampler = This->resource.wineD3DDevice->rev_tex_unit_map[active_texture - GL_TEXTURE0_ARB];

-- 
Alexandre Julliard
julliard at winehq.org



More information about the wine-devel mailing list