http://bugs.winehq.org/show_bug.cgi?id=60244 Bug ID: 60244 Summary: Deadfall Adventures crashes in new WoW64 on NVIDIA when opengl32 exhausts the BAR1 heap Product: Wine Version: 11.16 Hardware: x86-64 URL: https://store.steampowered.com/app/231330/Deadfall_Adv entures/ OS: Linux Status: NEW Severity: normal Priority: P2 Component: opengl Assignee: wine-bugs@list.winehq.org Reporter: gyebro69@gmail.com Target Milestone: --- Distribution: ArchLinux Created attachment 81951 --> http://bugs.winehq.org/attachment.cgi?id=81951 terminal output 'Deadfall Adventures' is a 32-bit D3D9 game. With current new-WoW64 Wine + wined3d + proprietary NVIDIA, the game crashes while loading the first level. The crash happens with graphical details set to "Very Low" as well as with "Very High". The crash occurs with EGL and with GLX backends too. Reproduced with Wine-11.1, 11.7, 11.16, wine git 11.16-76-g3489c653109 NVIDIA drivers tested: 580.178.04, 595.91.07, 610.57.04. The crash does not occur with: -old-style WoW64 / multilib Wine -nouveau -DXVK d3d9.dll Immediately before the crash: err:opengl:create_buffer_storage vkAllocateMemory failed: -2 fixme:opengl:wow64_map_buffer GL_MAP_PERSISTENT_BIT not supported! So then I asked AI what the issue might be...and it came up with a workaround/diagnostic patch. My NVIDIA GPU has a 256 MiB BAR1 aperture. Vulkan exposes: memory type 5: heapIndex = 2 DEVICE_LOCAL | HOST_VISIBLE | HOST_COHERENT heap 2: size = ~246 MiB During reproduction: main menu: BAR1 Used = 65 MiB second intro video: BAR1 Used = 214 MiB at crash: BAR1 Used = 246 MiB At that exact point vkAllocateMemory() returns VK_ERROR_OUT_OF_DEVICE_MEMORY. As a diagnostic test I changed the default Vulkan memory type selection in create_buffer_storage() in dlls/opengl32/unix_wgl.c: - uint32_t desired_type = type_mask; + uint32_t desired_type = + type_mask & ~VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT; This makes Wine use the HOST_VISIBLE | HOST_COHERENT non-device-local memory type instead. With this one-line change: BAR1 stays at ~19 MiB the first level loads successfully the game runs normally Very Low and Very High graphics settings both work Tested with wine-11.16-76-g3489c653109 NVIDIA GeForce GTX 1660 SUPER NVIDIA 610.57.04 OpenGL 4.60 -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.