libretro / libretro/RetroArch

Crash when using Vulkan with Dreamcast Games (Flycast)

Open
#18,026 25 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
14.1k
Forks
2.2k
Avg merge
7h 35m
Merged PRs (30d)
51

Description

Is there an existing issue for this?
  • This is a bug in RetroArch frontend
  • I have searched the existing issues
Description

When setting the Video Output to Vulkan, it just crashes instantly, when using gl/glcore/others it works fine.

Expected behavior

No response

Steps to reproduce the bug

Go to Settings --> Video --> Output --> set to Vulkan
Start a Dreamcast Game using Flycast

Version/Commit

1.21.0

Bisect Results

No response

Present in the nightly version

I don't know

Platform & operating system

Linux amd64

Affected Cores

Flycast

Environment information

Using Linux with Wayland. Vulkan works in other applications fine and the Vulkan tools tell me, that i have working Vulkan Support. Other Cores worked fine with Vulkan so far too, but non of them use 3D Rendering

Relevant log output
[INFO] [Environ]: GET_CORE_OPTIONS_VERSION.
[INFO] [Environ]: GET_LANGUAGE: "1".
[INFO] [Environ]: RETRO_ENVIRONMENT_SET_CORE_OPTIONS_V2_INTL.
[INFO] [Environ]: SET_CONTROLLER_INFO.
[INFO] [Environ]: GET_LOG_INTERFACE.
[libretro INFO] shell/libretro/libretro.cpp:326 N[BOOT]: retro_init
[INFO] [Environ]: GET_PERF_INTERFACE.
[INFO] [Environ]: SET_PIXEL_FORMAT: XRGB8888.
[INFO] [Environ]: SET_KEYBOARD_CALLBACK.
[INFO] [Environ]: GET_DISK_CONTROL_INTERFACE_VERSION.
[INFO] [Environ]: SET_DISK_CONTROL_EXT_INTERFACE.
[libretro INFO] core/hw/mem/addrspace.cpp:425 N[VMEM]: Info: nvmem is enabled
[libretro INFO] core/hw/mem/addrspace.cpp:457 N[VMEM]: BASE 0x7f8b837f0000 RAM(16 MB) 0x7f8b8f7f0000 VRAM64(8 MB) 0x7f8b877f0000 ARAM(2 MB) 0x7f8ba37f0000
[INFO] [Content]: コンテンツのロードがスキップされました。実装は独自にロードされます。
[libretro INFO] shell/libretro/libretro.cpp:2075 N[BOOT]: retro_load_game: /run/media/vamp898/441c2692-2cb5-42d6-a37d-c0df8ed1c574/ゲーム/SEGA/21 - Two One (Japan)/21 - Two One (Japan).cue
[INFO] [Environ]: GET_RUMBLE_INTERFACE.
[INFO] [Environ]: SYSTEM_DIRECTORY: "/home/vamp898/.config/retroarch/system".
[INFO] [Environ]: SAVE_DIRECTORY: "/home/vamp898/.config/retroarch/saves/Flycast".
[INFO] [Environ]: SET_SAVE_STATE_IN_BACKGROUND: no.
[libretro INFO] File extension is: .cue
[INFO] [Environ]: GET_PREFERRED_HW_RENDER, video driver name: vulkan.
[INFO] [Environ]: GET_PREFERRED_HW_RENDER - Context callback set to RETRO_HW_CONTEXT_VULKAN.
[INFO] [Environ]: SET_HW_RENDER, context type: vulkan.
[INFO] Requesting Vulkan context.
[INFO] [Environ]: SET_HW_RENDER_CONTEXT_NEGOTIATION_INTERFACE.
[libretro INFO] core/hw/mem/addrspace.cpp:425 N[VMEM]: Info: nvmem is enabled
[libretro INFO] core/hw/mem/addrspace.cpp:457 N[VMEM]: BASE 0x7f8b837f0000 RAM(32 MB) 0x7f8b8f7f0000 VRAM64(8 MB) 0x7f8b877f0000 ARAM(2 MB) 0x7f8ba37f0000
[libretro INFO] core/emulator.cpp:59 N[BOOT]: Game ID is [T46503M]
[libretro INFO] core/emulator.cpp:215 N[BOOT]: USA region not supported. Using Japan instead
[libretro INFO] core/emulator.cpp:597 N[BOOT]: Did not load BIOS, using reios
[libretro INFO] core/emulator.cpp:59 N[BOOT]: Game ID is [T46503M]
[INFO] [SRAM]: SRAM のロードをスキップしています。
[INFO] [Core]: Libretro API のバージョン: 1, API に対してコンパイル済み: 1
[libretro INFO] shell/libretro/libretro.cpp:2418 N[RENDERER]: retro_get_system_av_info: Res=480
[INFO] [Core]: Geometry: 640x480, Aspect: 1.333, FPS: 60.00, Sample rate: 44100.00 Hz.
[INFO] [Video]: Set video size to: 1440x1080.
[INFO] [Video]: Using HW render, vulkan driver forced.
[INFO] [Wayland]: Registered interface wl_compositor at version 6
[INFO] [Wayland]: Registered interface zxdg_decoration_manager_v1 at version 1
[INFO] [Wayland]: Registered interface wp_viewporter at version 1
[INFO] [Wayland]: Registered interface wp_fractional_scale_manager_v1 at version 1
[INFO] [Wayland]: Registered interface wl_shm at version 1
[INFO] [Wayland]: Registered interface wl_seat at version 9
[INFO] [Wayland]: Registered interface zwp_pointer_constraints_v1 at version 1
[INFO] [Wayland]: Registered interface zwp_relative_pointer_manager_v1 at version 1
[INFO] [Wayland]: Registered interface wl_data_device_manager at version 3
[INFO] [Wayland]: Registered interface wp_cursor_shape_manager_v1 at version 1
[INFO] [Wayland]: Registered interface zwp_idle_inhibit_manager_v1 at version 1
[INFO] [Wayland]: Registered interface wp_content_type_manager_v1 at version 1
[INFO] [Wayland]: Registered interface xdg_wm_base at version 6
[INFO] [Wayland]: Registered interface wl_output at version 4
[INFO] [Wayland]: Compositor doesn't support the wp_single_pixel_buffer_manager_v1 protocol!
[INFO] [Vulkan]: Vulkan dynamic library loaded.
[INFO] [Vulkan]: Found vulkan context: "vk_wayland".
[INFO] [Vulkan]: Detecting screen resolution: 2560x1440.
[INFO] [Vulkan]: Got HW context negotiation interface 1.
[INFO] [Vulkan]: Found GPU at index 0: "AMD Radeon Graphics (RADV RENOIR)".
[INFO] [Vulkan]: Using GPU index 0.
[libretro INFO] core/rend/vulkan/vk_context_lr.cpp:148 N[RENDERER]: Device extension enabled: VK_KHR_swapchain
[libretro INFO] core/rend/vulkan/vk_context_lr.cpp:148 N[RENDERER]: Device extension enabled: VK_EXT_provoking_vertex
[INFO] [Vulkan]: Using semaphores for WSI acquire.
[INFO] [Vulkan]: Using GPU: "AMD Radeon Graphics (RADV RENOIR)".
[INFO] [Vulkan]: Got 3 swapchain images.
[INFO] [Vulkan]: Using resolution 1440x1080.
[INFO] [Vulkan]: Using BGRA8888 format.
[INFO] [Vulkan]: Loading stock shader.
[INFO] [udev]: Pad #0 (/dev/input/event6) supports 0 force feedback effects.
[INFO] [Joypad]: Found joypad driver: "udev".
[INFO] [Wayland]: Enabling idle inhibitor
[INFO] [Video]: Found display server: "null".
[libretro INFO] shell/libretro/libretro.cpp:1883 N[RENDERER]: retro_vk_context_reset
[libretro INFO] core/rend/vulkan/vk_context_lr.cpp:262 N[RENDERER]: GPU Supports Vulkan API: 1.4.311
[libretro INFO] core/rend/vulkan/vk_context_lr.cpp:268 N[RENDERER]: GPU Supports vkGetPhysicalDeviceProperties2
[libretro INFO] core/rend/vulkan/vulkan_context.h:326 N[RENDERER]: Using depth format D32SfloatS8Uint tiling Optimal
[libretro INFO] core/rend/vulkan/vulkan_renderer.cpp:240 N[RENDERER]: VulkanRenderer::Init
[INFO] [Audio]: Set audio input rate to: 44100.00 Hz.
[INFO] [PulseAudio]: Requested 24576 bytes buffer, got 18432.
[INFO] [Audio]: Started synchronous audio driver.
[INFO] [ALSA] Using ALSA version 1.2.14
[INFO] [Microphone]: Initialized microphone driver.
[INFO] [Display]: Found display driver: "vulkan".
[INFO] [Environ]: SET_INPUT_DESCRIPTORS:
[INFO] [Playlist]: 履歴ファイルをロード中: "/home/vamp898/.config/retroarch/content_history.lpl".
[INFO] [Playlist]: 履歴ファイルをロード中: "/home/vamp898/.config/retroarch/content_music_history.lpl".
[INFO] [Playlist]: 履歴ファイルをロード中: "/home/vamp898/.config/retroarch/content_video_history.lpl".
[INFO] [Playlist]: 履歴ファイルをロード中: "/home/vamp898/.config/retroarch/content_image_history.lpl".
[INFO] [Playlist]: お気に入りファイルを読み込み中: "/home/vamp898/.config/retroarch/content_favorites.lpl".
[libretro INFO] core/reios/reios.cpp:633 N[REIOS]: -----------------
[libretro INFO] core/reios/reios.cpp:634 N[REIOS]: REIOS: Booting up
[libretro INFO] core/reios/reios.cpp:635 N[REIOS]: -----------------
[INFO] [Environ]: SET_GEOMETRY: 640x480, Aspect: 1.333.
retroarch: deps/glslang/glslang/SPIRV/GlslangToSpv.cpp:281: spv::ExecutionModel {anonymous}::TranslateExecutionModel(EShLanguage): Assertion `0' failed.
中止

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the crash by launching a Dreamcast game with Vulkan on Linux/Wayland, then inspect the assertion at deps/glslang/glslang/SPIRV/GlslangToSpv.cpp:281. Trace the Flycast Vulkan path through core/rend/vulkan/vk_context_lr.cpp and core/rend/vulkan/vulkan_renderer.cpp; done means the game no longer aborts during Vulkan startup.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
computer-graphics
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.