[PATCH 2/5] d3d10core: Fixup HRESULT in a bunch of error cases.

Michael Mc Donnell michael at mcdonnell.dk
Sat Sep 24 06:31:11 CDT 2011


Hi Stefan

I can't reproduce this. Is there a way that I can download those
patches that provoke the problem?

I ran the test through valgrind just to be safe and found a double
free bug in test_convert_point_reps_to_adjacency. I don't know if that
is causing the problem, but you can try my patch and see if it helps.
I've also sent the patch to wine-patches.

Cheers,
Michael

On Fri, Sep 23, 2011 at 10:07 PM, Stefan Dösinger
<stefandoesinger at gmail.com> wrote:
> (CCing Michael)
>
> Hi Michael,
>
> The Wine buildbot has spotted some heap corruption in the d3dx9 weld vertices
> test. It found those tests when testing one of Matteo's patches, but I doubt
> that the patch itself is flawed.
>
> For more information see the quote below. To try to reproduce this run the
> test with WINEDEBUG=warn+heap, this enables some consistency checking of the
> heap data structures to detect some overruns, acess of freed memory etc. The
> bug could be anywhere in the d3dx9 tests, d3dx9.dll, d3d9 or wined3d. Maybe
> you can spot something - I'll take a look myself too.
>
> Cheers,
> Stefan
>
> On Friday 23 September 2011 19:01:45 Dan Kegel wrote:
>> Hi Matteo,
>> a test failed here under WINEDEBUG=warn+heap,
>> could it be caused by your patch series, or is it unrelated?
>> Thanks,
>> Dan
>>
>>
>> ---------- Forwarded message ----------
>> From:  <buildbot at kegel.com>
>> Date: Fri, Sep 23, 2011 at 9:39 AM
>> Subject: Re: 79237: [PATCH 2/5] d3d10core: Fixup HRESULT in a bunch of
>> error cases.
>> To: dank at kegel.com
>>
>>
>> This is an experimental automated build and test service.
>> Please feel free to ignore this email while we work the kinks out.
>>
>> For more info about this message, see http://wiki.winehq.org/BuildBot
>>
>> The Buildbot has detected a failed build on builder runtests-heaptest
>> while building Wine.
>> Full details are available at:
>> http://buildbot.kegel.com/builders/runtests-heaptest/builds/0 (though
>> maybe not for long, as I'm still reinstalling the buildbot
>> periodically while experimenting)
>> BUILD FAILED: failed shell_3
>>
>> Errors:
>> alarum: failed command was ../../../wine d3dx9_36_test.exe.so mesh.c
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33f47c,0x00000000), stub!
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33f47c,0x00000000), stub!
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33f64c,0x00000000), stub!
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33f67c,0x00000000), stub!
>> fixme:d3dx:D3DXCreateBox (0x13c590, 2.000000, 20.000000, 4.900000,
>> (nil), 0x33fcb0): stub
>> fixme:d3dx:D3DXCreateBox ((nil), 22.000000, 20.000000, 4.900000,
>> 0x33fcb4, 0x33fcb0): stub
>> fixme:d3dx:D3DXCreateBox (0x13c590, -2.000000, 20.000000, 4.900000,
>> 0x33fcb4, 0x33fcb0): stub
>> fixme:d3dx:D3DXCreateBox (0x13c590, 22.000000, -20.000000, 4.900000,
>> 0x33fcb4, 0x33fcb0): stub
>> fixme:d3dx:D3DXCreateBox (0x13c590, 22.000000, 20.000000, -4.900000,
>> 0x33fcb4, 0x33fcb0): stub
>> fixme:d3dx:D3DXCreateBox (0x13c590, 10.900000, 20.000000, 4.900000,
>> 0x33fcb4, 0x33fcb0): stub
>> mesh.c:2496: Tests skipped: D3DXCreateBox failed
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33f6bc,0x00000000), stub!
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33f6bc,0x00000000), stub!
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33f5ac,0x00000000), stub!
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33f21c,0x00000000), stub!
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33f30c,0x00000000), stub!
>> fixme:d3dx:D3DXGetDeclVertexSize Unhandled element type 0x12, size
>> will be incorrect.
>> fixme:d3dx:ID3DXSkinInfoImpl_GetMinBoneInfluence (0x15c3c8): stub
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33e85c,0x00000000), stub!
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33e70c,0x00000000), stub!
>> fixme:win:EnumDisplayDevicesW ((null),0,0x33bd0c,0x00000000), stub!
>> wine: Unhandled page fault on read access to 0xfeeefeee at address
>> 0x7bc4813e (thread 0028), starting debugger...
>> Unhandled exception: page fault on read access to 0xfeeefeee in 32-bit
>> code (0x7bc4813e).
>> Register dump:
>>  CS:0073 SS:007b DS:007b ES:007b FS:0033 GS:003b
>>  EIP:7bc4813e ESP:0033c0d0 EBP:0033c108 EFLAGS:00010202(  R- --  I   - - -
>> ) EAX:feeefeee EBX:7bcb5ff4 ECX:00004008 EDX:00f75ff8
>>  ESI:7ffdf000 EDI:0033e0ec
>> Stack dump:
>> 0x0033c0d0:  00110000 00e96668 50000062 7bc3449a
>> 0x0033c0e0:  00110064 682eeff4 00001302 00e91268
>> 0x0033c0f0:  00e96668 00110000 feeefef4 feeefeee
>> 0x0033c100:  00000000 7bcb5ff4 0033c158 7bc4b741
>> 0x0033c110:  00e66000 00e96668 00e91260 00000000
>> 0x0033c120:  7c8ec470 7ffdf000 002065a8 00e70fa8
>> Backtrace:
>> =>0 0x7bc4813e HEAP_MakeInUseBlockFree+0xf5(subheap=0xe66000,
>> pArena=0xe96668)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/ntdll/he
>> ap.c:640] in ntdll (0x0033c108)
>>  1 0x7bc4b741 RtlFreeHeap+0xdf(heap=0x110000, flags=0x50000062,
>> ptr=0xe91268)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/ntdll/h
>> eap.c:1757] in ntdll (0x0033c158)
>>  2 0x68c39745 wined3d_stateblock_decref+0x308(stateblock=0xe84440)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/wined3d/
>> stateblock.c:529] in wined3d (0x0033c1e8)
>>  3 0x68ba095e wined3d_device_uninit_3d+0x35f(device=0xe81280)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/wined3d/
>> device.c:1521] in wined3d (0x0033c2b8)
>>  4 0x68b27386 IDirect3DDevice9Impl_Release+0x141(iface=0x136d08)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3d9/dev
>> ice.c:263] in d3d9 (0x0033c318)
>>  5 0x68593961 free_test_context+0x30(test_context=0x1bf500)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3dx9_36
>> /tests/mesh.c:169] in d3dx9_36_test (0x0033c348)
>>  6 0x685b6d1f test_weld_vertices+0x7a01()
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3dx9_36
>> /tests/mesh.c:8167] in d3dx9_36_test (0x0033fce8)
>>  7 0x685b6d99 func_mesh+0x6e()
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3dx9_36
>> /tests/mesh.c:8192] in d3dx9_36_test (0x0033fcf8)
>>  8 0x685c6c0e run_test+0x9e(name="mesh.c")
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3dx9_36
>> /tests/../../../include/wine/test.h:556] in d3dx9_36_test (0x0033fd58)
>>  9 0x685c7025 main+0x23a(argc=<couldn't compute location>,
>> argv=0x111eb8)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3dx9_3
>> 6/tests/../../../include/wine/test.h:624] in d3dx9_36_test (0x0033fe28)
>>  10 0x685c70ae __wine_spec_exe_entry+0x69(peb=0x7ffdf000)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/winecrt0
>> /exe_entry.c:36] in d3dx9_36_test (0x0033fe60)
>>  11 0x7b85fc8c call_process_entry+0xb() in kernel32 (0x0033fe78)
>>  12 0x7b85fdd3 start_process+0x144(peb=0x7ffdf000)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/kernel32
>> /process.c:1091] in kernel32 (0x0033fec8)
>>  13 0x7bc7ea30 call_thread_func+0xb() in ntdll (0x0033fed8)
>>  14 0x7bc7ea6e call_thread_entry_point+0x33(entry=0x7b85fc8e,
>> arg=0x7ffdf000)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/ntdll/si
>> gnal_i386.c:2499] in ntdll (0x0033ffb8)
>>  15 0x7bc541ed start_process+0x25(kernel_start=0x7b85fc8e)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/ntdll/lo
>> ader.c:2612] in ntdll (0x0033ffe8)
>>  16 0x68028c09 wine_call_on_stack+0x1c() in libwine.so.1 (0x00000000)
>> 0x7bc4813e HEAP_MakeInUseBlockFree+0xf5
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/ntdll/he
>> ap.c:640] in ntdll: movl     0x0(%eax),%eax
>> 640             size += (pFree->size & ARENA_SIZE_MASK) +
>> sizeof(ARENA_FREE); Modules:
>> Module  Address                 Debug info      Name (66 modules)
>> ELF     40000000-40002000       Deferred        libnvidia-tls.so.270.41.06
>> ELF     40002000-41724000       Deferred
>>  libnvidia-glcore.so.270.41.06 ELF     68000000-6801e000       Deferred
>>      ld-linux.so.2
>> ELF     68020000-68162000       Dwarf           libwine.so.1
>> ELF     68163000-68178000       Deferred        libz.so.1
>> ELF     68179000-68192000       Deferred        libpthread.so.0
>> ELF     68192000-682f3000       Deferred        libc.so.6
>> ELF     682f4000-682f8000       Deferred        libdl.so.2
>> ELF     682f9000-6831f000       Deferred        libm.so.6
>> ELF     6831f000-68327000       Deferred        libnss_compat.so.2
>> ELF     68327000-6833e000       Deferred        libnsl.so.1
>> ELF     6833e000-68349000       Deferred        libnss_nis.so.2
>> ELF     68349000-68355000       Deferred        libnss_files.so.2
>> ELF     68555000-685da000       Dwarf           d3dx9_36_test<elf>
>>  \-PE  68560000-685da000       \               d3dx9_36_test
>> ELF     685da000-6864d000       Deferred        d3dx9_36<elf>
>>  \-PE  685e0000-6864d000       \               d3dx9_36
>> ELF     6864d000-686ac000       Deferred        d3dcompiler_43<elf>
>>  \-PE  68660000-686ac000       \               d3dcompiler_43
>> ELF     686ac000-686d3000       Deferred        d3dxof<elf>
>>  \-PE  686b0000-686d3000       \               d3dxof
>> ELF     686d3000-68803000       Deferred        ole32<elf>
>>  \-PE  686f0000-68803000       \               ole32
>> ELF     68803000-68869000       Deferred        advapi32<elf>
>>  \-PE  68810000-68869000       \               advapi32
>> ELF     68869000-689bf000       Deferred        user32<elf>
>>  \-PE  68880000-689bf000       \               user32
>> ELF     689bf000-68a77000       Deferred        gdi32<elf>
>>  \-PE  689d0000-68a77000       \               gdi32
>> ELF     68a77000-68a92000       Deferred        version<elf>
>>  \-PE  68a80000-68a92000       \               version
>> ELF     68a92000-68b10000       Deferred        rpcrt4<elf>
>>  \-PE  68aa0000-68b10000       \               rpcrt4
>> ELF     68b10000-68b4c000       Dwarf           d3d9<elf>
>>  \-PE  68b20000-68b4c000       \               d3d9
>> ELF     68b4c000-68cb5000       Dwarf           wined3d<elf>
>>  \-PE  68b60000-68cb5000       \               wined3d
>> ELF     68ccc000-68d52000       Deferred        libfreetype.so.6
>> ELF     68d52000-68d81000       Deferred        libfontconfig.so.1
>> ELF     68d81000-68dab000       Deferred        libexpat.so.1
>> ELF     68e01000-68ebc000       Deferred        winex11<elf>
>>  \-PE  68e10000-68ebc000       \               winex11
>> ELF     68ed3000-68edb000       Deferred        libsm.so.6
>> ELF     68edb000-68ef3000       Deferred        libice.so.6
>> ELF     68ef3000-68f02000       Deferred        libxext.so.6
>> ELF     68f02000-6901d000       Deferred        libx11.so.6
>> ELF     6901d000-69022000       Deferred        libuuid.so.1
>> ELF     69022000-6903b000       Deferred        libxcb.so.1
>> ELF     6903b000-6903f000       Deferred        libxau.so.6
>> ELF     6903f000-69045000       Deferred        libxdmcp.so.6
>> ELF     69045000-69067000       Deferred        imm32<elf>
>>  \-PE  69050000-69067000       \               imm32
>> ELF     69067000-6906b000       Deferred        libxinerama.so.1
>> ELF     6906b000-69071000       Deferred        libxxf86vm.so.1
>> ELF     69071000-6907b000       Deferred        libxrender.so.1
>> ELF     6907b000-69083000       Deferred        libxrandr.so.2
>> ELF     69083000-69087000       Deferred        libxcomposite.so.1
>> ELF     69087000-69096000       Deferred        libxi.so.6
>> ELF     69096000-690a0000       Deferred        libxcursor.so.1
>> ELF     690a0000-690a6000       Deferred        libxfixes.so.3
>> ELF     690eb000-691b9000       Deferred        libgl.so.1
>> ELF     7b800000-7b9b2000       Dwarf           kernel32<elf>
>>  \-PE  7b810000-7b9b2000       \               kernel32
>> ELF     7bc00000-7bcd2000       Dwarf           ntdll<elf>
>>  \-PE  7bc10000-7bcd2000       \               ntdll
>> ELF     7bf00000-7bf04000       Deferred        <wine-loader>
>> Threads:
>> process  tid      prio (all id:s are in hex)
>> 0000000e services.exe
>>        00000021    0
>>        00000020    0
>>        00000015    0
>>        00000010    0
>>        0000000f    0
>> 00000012 winedevice.exe
>>        0000001a    0
>>        00000019    0
>>        00000014    0
>>        00000013    0
>> 0000001b plugplay.exe
>>        00000022    0
>>        0000001f    0
>>        0000001c    0
>> 0000001d explorer.exe
>>        0000001e    0
>> 00000027 (D)
>> Z:\home\bob\wineslave.dir\sandbox\slave\runtests-heaptest\build\dlls\d3dx9
>> _36\tests\d3dx9_36_test.exe 00000028    0 <==
>> Backtrace:
>> =>0 0x7bc4813e HEAP_MakeInUseBlockFree+0xf5(subheap=0xe66000,
>> pArena=0xe96668)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/ntdll/he
>> ap.c:640] in ntdll (0x0033c108)
>>  1 0x7bc4b741 RtlFreeHeap+0xdf(heap=0x110000, flags=0x50000062,
>> ptr=0xe91268)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/ntdll/h
>> eap.c:1757] in ntdll (0x0033c158)
>>  2 0x68c39745 wined3d_stateblock_decref+0x308(stateblock=0xe84440)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/wined3d/
>> stateblock.c:529] in wined3d (0x0033c1e8)
>>  3 0x68ba095e wined3d_device_uninit_3d+0x35f(device=0xe81280)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/wined3d/
>> device.c:1521] in wined3d (0x0033c2b8)
>>  4 0x68b27386 IDirect3DDevice9Impl_Release+0x141(iface=0x136d08)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3d9/dev
>> ice.c:263] in d3d9 (0x0033c318)
>>  5 0x68593961 free_test_context+0x30(test_context=0x1bf500)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3dx9_36
>> /tests/mesh.c:169] in d3dx9_36_test (0x0033c348)
>>  6 0x685b6d1f test_weld_vertices+0x7a01()
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3dx9_36
>> /tests/mesh.c:8167] in d3dx9_36_test (0x0033fce8)
>>  7 0x685b6d99 func_mesh+0x6e()
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3dx9_36
>> /tests/mesh.c:8192] in d3dx9_36_test (0x0033fcf8)
>>  8 0x685c6c0e run_test+0x9e(name="mesh.c")
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3dx9_36
>> /tests/../../../include/wine/test.h:556] in d3dx9_36_test (0x0033fd58)
>>  9 0x685c7025 main+0x23a(argc=<couldn't compute location>,
>> argv=0x111eb8)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/d3dx9_3
>> 6/tests/../../../include/wine/test.h:624] in d3dx9_36_test (0x0033fe28)
>>  10 0x685c70ae __wine_spec_exe_entry+0x69(peb=0x7ffdf000)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/winecrt0
>> /exe_entry.c:36] in d3dx9_36_test (0x0033fe60)
>>  11 0x7b85fc8c call_process_entry+0xb() in kernel32 (0x0033fe78)
>>  12 0x7b85fdd3 start_process+0x144(peb=0x7ffdf000)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/kernel32
>> /process.c:1091] in kernel32 (0x0033fec8)
>>  13 0x7bc7ea30 call_thread_func+0xb() in ntdll (0x0033fed8)
>>  14 0x7bc7ea6e call_thread_entry_point+0x33(entry=0x7b85fc8e,
>> arg=0x7ffdf000)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/ntdll/si
>> gnal_i386.c:2499] in ntdll (0x0033ffb8)
>>  15 0x7bc541ed start_process+0x25(kernel_start=0x7b85fc8e)
>> [/home/bob/wineslave.dir/sandbox/slave/runtests-default/build/dlls/ntdll/lo
>> ader.c:2612] in ntdll (0x0033ffe8)
>>  16 0x68028c09 wine_call_on_stack+0x1c() in libwine.so.1 (0x00000000)
>> make: *** [mesh.ok] Error 5
>>
>> _______________________________________________
>> wine-tests-results mailing list
>> wine-tests-results at winehq.org
>> http://www.winehq.org/mailman/listinfo/wine-tests-results
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-d3dx-test-Fixed-adjacency-double-free-valgrind.patch
Type: text/x-patch
Size: 770 bytes
Desc: not available
URL: <http://www.winehq.org/pipermail/wine-tests-results/attachments/20110924/9def42c5/attachment-0001.bin>


More information about the wine-tests-results mailing list