ValveSoftware / Source-1-Games

Source 1 based games such as TF2 and Counter-Strike: Source
643 stars 74 forks source link

[L4D2] Frequent crashes during map transitions (VK_ERROR_MEMORY_MAP_FAILED) #3923

Open ChrisDeadman opened 2 years ago

ChrisDeadman commented 2 years ago

I' running RX 6900XT with RADV and Mesa 22.1.1 (altho this issue also occurs with Mesa 22.0.4) on Manjaro Linux.

Sometimes I can play for hours, sometimes I can only play for minutes before this happens but when it crashes it's always at the end of a map right before transitioning to the next map.

Looks like memory allocation error and since L4D2 is still 32bit #3847 this might be having something to do with it maybe? I am playing in 1440p with everything on max. settings. (This happens with and without mods enabled so mods are not at fault here)

hl2_linux_d3d9.log: ``` info: Game: hl2_linux info: DXVK: v1.9.2-32-ga2dc99c info: Built-in extension providers: info: SDL2 WSI info: Enabled instance extensions: info: VK_KHR_get_surface_capabilities2 info: VK_KHR_surface info: VK_KHR_xlib_surface info: D3D9: VK_FORMAT_D24_UNORM_S8_UINT -> VK_FORMAT_D32_SFLOAT_S8_UINT info: AMD RADV SIENNA_CICHLID: info: Driver: 22.1.1 info: Vulkan: 1.3.211 info: Memory Heap[0]: info: Size: 67043328 MiB info: Flags: 0x0 info: Memory Type[1]: Property Flags = 0x6 info: Memory Type[3]: Property Flags = 0xe info: Memory Type[5]: Property Flags = 0xc6 info: Memory Type[7]: Property Flags = 0xce info: Memory Heap[1]: info: Size: 16368 MiB info: Flags: 0x1 info: Memory Type[0]: Property Flags = 0x1 info: Memory Type[2]: Property Flags = 0x7 info: Memory Type[4]: Property Flags = 0xc1 info: Memory Type[6]: Property Flags = 0xc7 info: Device properties: info: Device name: : AMD RADV SIENNA_CICHLID info: Driver version : 22.1.1 info: Enabled device extensions: info: VK_AMD_memory_overallocation_behavior info: VK_AMD_shader_fragment_mask info: VK_EXT_4444_formats info: VK_EXT_conservative_rasterization info: VK_EXT_custom_border_color info: VK_EXT_depth_clip_enable info: VK_EXT_extended_dynamic_state info: VK_EXT_host_query_reset info: VK_EXT_memory_priority info: VK_EXT_robustness2 info: VK_EXT_shader_demote_to_helper_invocation info: VK_EXT_shader_stencil_export info: VK_EXT_shader_viewport_index_layer info: VK_EXT_transform_feedback info: VK_EXT_vertex_attribute_divisor info: VK_KHR_create_renderpass2 info: VK_KHR_depth_stencil_resolve info: VK_KHR_draw_indirect_count info: VK_KHR_driver_properties info: VK_KHR_image_format_list info: VK_KHR_sampler_mirror_clamp_to_edge info: VK_KHR_shader_float_controls info: VK_KHR_swapchain info: Device features: info: robustBufferAccess : 1 info: fullDrawIndexUint32 : 1 info: imageCubeArray : 1 info: independentBlend : 1 info: geometryShader : 1 info: tessellationShader : 0 info: sampleRateShading : 1 info: dualSrcBlend : 0 info: logicOp : 0 info: multiDrawIndirect : 0 info: drawIndirectFirstInstance : 0 info: depthClamp : 1 info: depthBiasClamp : 1 info: fillModeNonSolid : 1 info: depthBounds : 1 info: multiViewport : 1 info: samplerAnisotropy : 1 info: textureCompressionBC : 1 info: occlusionQueryPrecise : 1 info: pipelineStatisticsQuery : 1 info: vertexPipelineStoresAndAtomics : 1 info: fragmentStoresAndAtomics : 0 info: shaderImageGatherExtended : 0 info: shaderStorageImageExtendedFormats : 0 info: shaderStorageImageReadWithoutFormat : 0 info: shaderStorageImageWriteWithoutFormat : 1 info: shaderClipDistance : 1 info: shaderCullDistance : 1 info: shaderFloat64 : 0 info: shaderInt64 : 0 info: variableMultisampleRate : 0 info: VK_EXT_4444_formats info: formatA4R4G4B4 : 1 info: formatA4B4G4R4 : 1 info: VK_EXT_custom_border_color info: customBorderColors : 1 info: customBorderColorWithoutFormat : 1 info: VK_EXT_depth_clip_enable info: depthClipEnable : 1 info: VK_EXT_extended_dynamic_state info: extendedDynamicState : 1 info: VK_EXT_host_query_reset info: hostQueryReset : 1 info: VK_EXT_memory_priority info: memoryPriority : 1 info: VK_EXT_robustness2 info: robustBufferAccess2 : 1 info: robustImageAccess2 : 0 info: nullDescriptor : 1 info: VK_EXT_shader_demote_to_helper_invocation info: shaderDemoteToHelperInvocation : 1 info: VK_EXT_transform_feedback info: transformFeedback : 0 info: geometryStreams : 0 info: VK_EXT_vertex_attribute_divisor info: vertexAttributeInstanceRateDivisor : 1 info: vertexAttributeInstanceRateZeroDivisor : 1 info: VK_KHR_buffer_device_address info: bufferDeviceAddress : 0 info: Queue families: info: Graphics : 0 info: Transfer : 1 info: DXVK: Read 18713 valid state cache entries info: DXVK: Using 16 compiler threads info: D3D9DeviceEx::ResetSwapChain: info: Requested Presentation Parameters info: - Width: 2560 info: - Height: 1440 info: - Format: D3D9Format::A8R8G8B8 info: - Auto Depth Stencil: true info: ^ Format: D3D9Format::D24S8 info: - Windowed: false info: Presenter: Actual swap chain properties: info: Format: VK_FORMAT_B8G8R8A8_UNORM info: Present mode: VK_PRESENT_MODE_IMMEDIATE_KHR info: Buffer size: 2560x1440 info: Image count: 3 info: Exclusive FS: 0 warn: D3D9Cursor::ShowCursor: Not supported on native info: Presenter: Actual swap chain properties: info: Format: VK_FORMAT_B8G8R8A8_UNORM info: Present mode: VK_PRESENT_MODE_FIFO_KHR info: Buffer size: 2560x1440 info: Image count: 4 info: Exclusive FS: 0 err: DxvkMemoryAllocator: Mapping memory failed with VK_ERROR_MEMORY_MAP_FAILED err: DxvkMemoryAllocator: Mapping memory failed with VK_ERROR_MEMORY_MAP_FAILED err: DxvkMemoryAllocator: Mapping memory failed with VK_ERROR_MEMORY_MAP_FAILED err: DxvkMemoryAllocator: Mapping memory failed with VK_ERROR_MEMORY_MAP_FAILED err: DxvkMemoryAllocator: Mapping memory failed with VK_ERROR_MEMORY_MAP_FAILED err: DxvkMemoryAllocator: Mapping memory failed with VK_ERROR_MEMORY_MAP_FAILED err: DxvkMemoryAllocator: Mapping memory failed with VK_ERROR_MEMORY_MAP_FAILED err: DxvkMemoryAllocator: Mapping memory failed with VK_ERROR_MEMORY_MAP_FAILED err: DxvkMemoryAllocator: Mapping memory failed with VK_ERROR_MEMORY_MAP_FAILED err: DxvkMemoryAllocator: Mapping memory failed with VK_ERROR_MEMORY_MAP_FAILED err: DxvkMemoryAllocator: Memory allocation failed err: Size: 33554432 err: Alignment: 16 err: Mem flags: 0xe err: Mem types: 0xff err: Heap 0: 1760 MB allocated, 310 MB used, 1912 MB allocated (driver), 67043284 MB budget (driver), 67043328 MB total err: Heap 1: 2496 MB allocated, 767 MB used, 2619 MB allocated (driver), 14897 MB budget (driver), 16368 MB total ```
Stacktrace: ``` #0 0x00000000f7f95549 __kernel_vsyscall (linux-gate.so.1 + 0x549) #1 0x00000000f7c8b227 n/a (libc.so.6 + 0x8b227) #2 0x00000000f7c37557 raise (libc.so.6 + 0x37557) #3 0x00000000f7c2011d abort (libc.so.6 + 0x2011d) #4 0x00000000f7878912 _ZN9__gnu_cxx27__verbose_terminate_handlerEv (libstdc++.so.6 + 0x78912) #5 0x00000000f7886387 _ZN10__cxxabiv111__terminateEPFvvE (libstdc++.so.6 + 0x86387) #6 0x00000000f7886413 _ZSt9terminatev (libstdc++.so.6 + 0x86413) #7 0x00000000f7886745 __cxa_throw (libstdc++.so.6 + 0x86745) #8 0x00000000d2dae6f5 n/a (libdxvk_d3d9.so + 0xad6f5) #9 0x00000000d2e398ff _ZNK4dxvk10DxvkBuffer11allocBufferEy (libdxvk_d3d9.so + 0x1388ff) #10 0x00000000d2e39b6b _ZN4dxvk10DxvkBufferC1EPNS_10DxvkDeviceERKNS_20DxvkBufferCreateInfoERNS_19DxvkMemoryAllocatorEj (libdxvk_d3d9.so + 0x138b6b) #11 0x00000000d2e5ab5b _ZN4dxvk10DxvkDevice12createBufferERKNS_20DxvkBufferCreateInfoEj (libdxvk_d3d9.so + 0x159b5b) #12 0x00000000d2df9b0b _ZN4dxvk17D3D9CommonTexture23CreateBufferSubresourceEj (libdxvk_d3d9.so + 0xf8b0b) #13 0x00000000d2de1c92 _ZN4dxvk12D3D9DeviceEx9LockImageEPNS_17D3D9CommonTextureEjjP14_D3DLOCKED_BOXPK7_D3DBOXj (libdxvk_d3d9.so + 0xe0c92) #14 0x00000000d2dfe6e4 _ZN4dxvk11D3D9Surface8LockRectEP15_D3DLOCKED_RECTPK4RECTj (libdxvk_d3d9.so + 0xfd6e4) #15 0x00000000d30a0006 n/a (shaderapivk.so + 0x59006) #16 0x00000000d308bad4 n/a (shaderapivk.so + 0x44ad4) #17 0x00000000d4adae73 n/a (materialsystem.so + 0x7ce73) #18 0x00000000d4adbd96 n/a (materialsystem.so + 0x7dd96) #19 0x00000000d4adbf28 n/a (materialsystem.so + 0x7df28) #20 0x00000000d4adbf7c n/a (materialsystem.so + 0x7df7c) #21 0x00000000d4aee20a n/a (materialsystem.so + 0x9020a) #22 0x00000000d4aef39a n/a (materialsystem.so + 0x9139a) #23 0x00000000d4ae846e n/a (materialsystem.so + 0x8a46e) #24 0x00000000cf7b51a6 n/a (stdshader_dx9.so + 0xcc1a6) #25 0x00000000cf76cc47 n/a (stdshader_dx9.so + 0x83c47) #26 0x00000000cf786f0c n/a (stdshader_dx9.so + 0x9df0c) #27 0x00000000cf7b401d n/a (stdshader_dx9.so + 0xcb01d) #28 0x00000000d4ae7f17 n/a (materialsystem.so + 0x89f17) #29 0x00000000d4a92d9e n/a (materialsystem.so + 0x34d9e) #30 0x00000000d4a923f5 n/a (materialsystem.so + 0x343f5) #31 0x00000000d3658e86 n/a (studiorender.so + 0x8fe86) #32 0x00000000d365914a n/a (studiorender.so + 0x9014a) #33 0x00000000d365c639 n/a (studiorender.so + 0x93639) #34 0x00000000e8dac0c2 n/a (datacache.so + 0x420c2) #35 0x00000000e8db183a n/a (datacache.so + 0x4783a) #36 0x00000000e8dafe1b n/a (datacache.so + 0x45e1b) #37 0x00000000e8db0946 n/a (datacache.so + 0x46946) #38 0x00000000e8db0d4c n/a (datacache.so + 0x46d4c) #39 0x00000000d55d3f69 n/a (engine.so + 0x451f69) #40 0x00000000d55d8501 n/a (engine.so + 0x456501) #41 0x00000000d55d889c n/a (engine.so + 0x45689c) #42 0x00000000d5491db4 n/a (engine.so + 0x30fdb4) #43 0x00000000d54bd090 n/a (engine.so + 0x33b090) #44 0x00000000d5495195 n/a (engine.so + 0x313195) #45 0x00000000d549580f n/a (engine.so + 0x31380f) #46 0x00000000d558db97 n/a (engine.so + 0x40bb97) #47 0x00000000d55902ef n/a (engine.so + 0x40e2ef) #48 0x00000000d55a98d0 n/a (engine.so + 0x4278d0) #49 0x00000000d55a9c06 n/a (engine.so + 0x427c06) #50 0x00000000d55a9c4d n/a (engine.so + 0x427c4d) #51 0x00000000d569bc77 n/a (engine.so + 0x519c77) #52 0x00000000d5697bbc n/a (engine.so + 0x515bbc) #53 0x00000000d5697ccf n/a (engine.so + 0x515ccf) #54 0x00000000d570d4c8 n/a (engine.so + 0x58b4c8) #55 0x00000000d569946f n/a (engine.so + 0x51746f) #56 0x00000000f61e3aa8 n/a (/run/media/deadman/LinuxGames/steam/steamapps/common/Left 4 Dead 2/bin/launcher.so + 0x2aaa8) #57 0x00000000f61e3aa8 n/a (/run/media/deadman/LinuxGames/steam/steamapps/common/Left 4 Dead 2/bin/launcher.so + 0x2aaa8) #58 0x00000000f61c9a7e LauncherMain (/run/media/deadman/LinuxGames/steam/steamapps/common/Left 4 Dead 2/bin/launcher.so + 0x10a7e) #59 0x00000000080484c4 main (hl2_linux + 0x4c4) #60 0x00000000f7c21159 n/a (libc.so.6 + 0x21159) #61 0x00000000f7c2122d __libc_start_main (libc.so.6 + 0x2122d) #62 0x00000000080485c5 _start (hl2_linux + 0x5c5) ELF object binary architecture: Intel 80386 ```
ChrisDeadman commented 7 months ago

Considering the quite frequent updates to L42D, I assume you are currently porting or preparing to port the game to your newest engine. If so, feel free to close this issue, since it's not really relevant anymore 😉