Size of SUBHEAP in heap.c

Michael Karcher karcher at
Wed Sep 10 15:10:25 CDT 2008

Am Mittwoch, den 10.09.2008, 18:52 +0200 schrieb Martin Profittlich:
> when trying to fix an issue with Guitar Rig 3 on Wine (Bug 10129,
> "Guitar Rig 3 crashes"), I found out something odd: The crash is
> affected by the size of the SUBHEAP structure in dlls/ntdll/heap.c.
> Just by adding 8 unused bytes to SUBHEAP, GR3 does not crash anymore.
> Add another 8 bytes, GR3 crashes again, yet another 8 bytes - no crash
> and so on.
Have you tried to run with warn+heap? In that case, on each
HeapAlloc/HeapFree, heap integrity will be checked. Also freed blocks
are directly overwritten with dummy data. The behaviour of warn+heap
might be insightful.

The size-dependent behaviour might also indicate alignment issues: There
are SSE instructions that insist on 16-byte alignment. If these are used
and our size of SUBHEAP happens to make the data only 8-byte aligned,
that might cause a crash, too.

In this particular case, I think the crash log does not really indicate
an alignment problem, but a "x/i $eip" in winedbg on the crash might
help to check further. I suspect a [edx-1] address while edx contains a
NULL pointer.

  Michael Karcher
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Dies ist ein digital signierter Nachrichtenteil
Url : 

More information about the wine-devel mailing list