https://bugs.winehq.org/show_bug.cgi?id=44871
Bug ID: 44871 Summary: Age of Empires II HD crashes often when restarting a scenario Product: Wine Version: 3.2 Hardware: x86 URL: http://store.steampowered.com/app/221380/Age_of_Empire s_II_HD/ OS: Linux Status: NEW Keywords: regression Severity: normal Priority: P2 Component: directx-d3d Assignee: wine-bugs@winehq.org Reporter: gyebro69@gmail.com CC: matteo.mystral@gmail.com Regression SHA1: 3d6eb8cf1dc1e509a74f85fd2356c6946372ecc5 Distribution: ArchLinux
Created attachment 60932 --> https://bugs.winehq.org/attachment.cgi?id=60932 backtrace from minidump
Although it is not always reproducible, the crash occurs fairly often (8 times out of 10 attempts) when I select <Restart> from the in-game menu. The Wine debugger never starts, the game simply quits and it creates a minidump in the game directory. There is nothing remarkable in the terminal before the crash. Native d3dx9_43.dll is installed. No demo version is available.
According to my testing the problem was introduced by
commit 3d6eb8cf1dc1e509a74f85fd2356c6946372ecc5 Author: Matteo Bruni mbruni@codeweavers.com Date: Tue Feb 13 01:00:42 2018 +0100
d3d9: Handle D3DUSAGE_AUTOGENMIPMAP textures entirely in d3d9.
Wine 3.5 OpenGL vendor string: NVIDIA Corporation OpenGL renderer string: GeForce GT 730/PCIe/SSE2 OpenGL core profile version string: 4.6.0 NVIDIA 390.48
https://bugs.winehq.org/show_bug.cgi?id=44871
--- Comment #1 from Béla Gyebrószki gyebro69@gmail.com --- Created attachment 60933 --> https://bugs.winehq.org/attachment.cgi?id=60933 +d3d,+d3d9 log (uncompressed 75M)
https://bugs.winehq.org/show_bug.cgi?id=44871
--- Comment #2 from Matteo Bruni matteo.mystral@gmail.com --- Thank you for the nice bug report and the log. Looking at the log, I realized that I forgot to take stateblocks into consideration, which is something that I'll need to fix somehow (and it's probably going to be pretty annoying, I think I'll have to do lots of extra wined3d calls for each draw :/).
That said, it's not clear (but certainly possible) that the crash is due to that issue. It looks like some kind of heap corruption, or accessing freed / reused memory. Does running the game with warn+heap make any difference?
https://bugs.winehq.org/show_bug.cgi?id=44871
--- Comment #3 from Matteo Bruni matteo.mystral@gmail.com --- Created attachment 60977 --> https://bugs.winehq.org/attachment.cgi?id=60977 Patch
Actually, does this patch make any difference?
https://bugs.winehq.org/show_bug.cgi?id=44871
--- Comment #4 from Béla Gyebrószki gyebro69@gmail.com --- (In reply to Matteo Bruni from comment #3)
Created attachment 60977 [details] Patch
Actually, does this patch make any difference?
Looks like the culprit is the game option "Render 3D Water": when it is disabled the game doesn't crash between restarts or when loading a different map.
Using WINEDEBUG=warn+heap I got these messages in the terminal each time a new scenario is loaded (the game still crashes): 0093:warn:heap:HEAP_ValidateInUseArena Heap 0x110000: invalid in-use arena magic 00555555 for 0x80c23f0 0093:warn:heap:HEAP_ValidateInUseArena Heap 0x110000: invalid in-use arena magic 00555555 for 0x80c23f0 0093:warn:heap:HEAP_ValidateInUseArena Heap 0x110000: invalid in-use arena magic 00555555 for 0x82ab668 0093:warn:heap:HEAP_ValidateInUseArena Heap 0x110000: invalid in-use arena magic 00555555 for 0x82ab668 They're also present with that game option disabled.
Your patch indeed fixes the problem, thank you.
https://bugs.winehq.org/show_bug.cgi?id=44871
Béla Gyebrószki gyebro69@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Fixed by SHA1| |6cfab2f7adf8d8a32b5fad6bf75 | |f9859e6fa0b01 Resolution|--- |FIXED
--- Comment #5 from Béla Gyebrószki gyebro69@gmail.com --- Fixed in Wine 3.6. https://source.winehq.org/git/wine.git/commit/6cfab2f7adf8d8a32b5fad6bf75f98...
https://bugs.winehq.org/show_bug.cgi?id=44871
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #6 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 3.7.