mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2026-04-25 07:46:01 +03:00
[GH-ISSUE #227] Linux - memory.cpp:operator assertion failed error #28
Labels
No labels
Bloodborne
bug
contributor wanted
documentation
enhancement
frontend
good first issue
help wanted
linux
pull-request
question
release
verification progress
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/shadPS4#28
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @gilcel on GitHub (Jul 1, 2024).
Original GitHub issue: https://github.com/shadps4-emu/shadPS4/issues/227
Hi,
Compiled latest shadPS4 commit
20e83b4on Linux (OpenSUSE Tumbleweed). User interface works,but trying to launch "OpenOrbis HelloWorld Sample" or "OpenOrbis Graphics Sample" it crashes with:
[Debug] <Critical> memory.cpp:operator():305: Assertion Failed! Adding a mapping to already mapped regionIt seems to be a problem with AMD Ryzen 5 5600G (APU) (also same error with AMD Ryzen 3400G) and Mesa 24.1.2 (RADV) driver / Linux Kernel 6.9.7, or Vulkan Version is 1.3.278 (but the one in externals is of version 1.3.288).
with clang v18.1.6 / gcc v13.3.0 installed.
shad_log.txt
@raphaelthegreat commented on GitHub (Jul 1, 2024):
Could you launch it with gdb or any debugger and show a stack trace?
@gilcel commented on GitHub (Jul 1, 2024):
Ok launched it with
gdb ./shadPS4, then launched the Graphics demo:(gdb)frame`[Debug] memory.cpp:operator():305: Assertion Failed!
Adding a mapping to already mapped region
[Thread 0x7fff76e006c0 (LWP 8383) exited]
Thread 1 "shadps4" received signal SIGTRAP, Trace/breakpoint trap.
0x00000000004f0656 in assert_fail_impl() ()
Missing separate debuginfos, use: zypper install Mesa-dri-debuginfo-24.1.2-1699.386.pm.1.x86_64 Mesa-libEGL1-debuginfo-24.1.2-1699.386.pm.1.x86_64 Mesa-libglapi0-debuginfo-24.1.2-1699.386.pm.1.x86_64 Mesa-vulkan-device-select-debuginfo-24.1.2-1699.386.pm.1.x86_64......` etc....
Shall I install of of these packages ? The list is quite big :-)
@raphaelthegreat commented on GitHub (Jul 1, 2024):
Not needed. Press
btthe moment it crashes to see the stack trace. If it doesn't have any symbols recompile with debug mode (you can do by runningcmake --build . --config Debugin build folder)@gilcel commented on GitHub (Jul 1, 2024):
(gdb) bt#0 0x00000000004f0656 in assert_fail_impl() ()
#1 0x00000000006f1b41 in Core::MemoryManager::AddMapping(unsigned long, unsigned long) ()`
#2 0x00000000006f1f46 in Core::MemoryManager::MapMemory(void**, unsigned long, unsigned long,
Core::MemoryProt, Core::MemoryMapFlags, Core::VMAType, std::basic_string_view<char, std::char_traits >, bool, unsigned long, unsigned long) ()
#3 0x00000000006f6995 in Core::Module::LoadModuleToMemory(unsigned int&) ()
#4 0x00000000006fa3cd in Core::Module::Module(Core::MemoryManager*, std::filesystem::__cxx11::path const&, unsigned int&) ()
#5 0x00000000006ecebb in Core::Linker::LoadModule(std::filesystem::__cxx11::path const&, bool) ()
#6 0x00000000004dba70 in Core::Emulator::Run(std::filesystem::__cxx11::path const&) ()
#7 0x00000000004819ed in MainWindow::CreateConnects()::{lambda()#1}::operator()() const ()
#8 0x00007ffff4fe7f90 in ??? () at /lib64/libQt6Core.so.6
#9 0x00007ffff66c9652 in QAbstractButton::clicked(bool) () at /lib64/libQt6Widgets.so.6
#10 0x00007ffff66c191a in ??? () at /lib64/libQt6Widgets.so.6
#11 0x00007ffff66c1bd9 in ??? () at /lib64/libQt6Widgets.so.6
#12 0x00007ffff66cd6af in QAbstractButton::mouseReleaseEvent(QMouseEvent*) () at /lib64/libQt6Widgets.so.6
#13 0x00007ffff660f344 in QWidget::event(QEvent*) () at /lib64/libQt6Widgets.so.6
#14 0x00007ffff65c2f6e in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /lib64/libQt6Widgets.so.6
#15 0x00007ffff65c6b87 in QApplication::notify(QObject*, QEvent*) () at /lib64/libQt6Widgets.so.6
#16 0x00007ffff4f8ec30 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /lib64/libQt6Core.so.6
#17 0x00007ffff65c26f8 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer&, bool, bool) () at /lib64/libQt6Widgets.so.6
#18 0x00007ffff6621c77 in ??? () at /lib64/libQt6Widgets.so.6
#19 0x00007ffff6624f55 in ??? () at /lib64/libQt6Widgets.so.6
#20 0x00007ffff65c2f6e in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /lib64/libQt6Widgets.so.6
#21 0x00007ffff4f8ec30 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /lib64/libQt6Core.so.6
#22 0x00007ffff57ed66b in QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent*) () at /lib64/libQt6Gui.so.6
#23 0x00007ffff584983c in QWindowSystemInterface::sendWindowSystemEvents(QFlagsQEventLoop::ProcessEventsFlag) () at /lib64/libQt6Gui.so.6
#24 0x00007ffff5c0b220 in ??? () at /lib64/libQt6Gui.so.6
#25 0x00007ffff5512740 in ??? () at /lib64/libglib-2.0.so.0
#26 0x00007ffff5514388 in ??? () at /lib64/libglib-2.0.so.0
#27 0x00007ffff5514a3c in g_main_context_iteration () at /lib64/libglib-2.0.so.0
#28 0x00007ffff51c1adc in QEventDispatcherGlib::processEvents(QFlagsQEventLoop::ProcessEventsFlag) () at /lib64/libQt6Core.so.6
#29 0x00007ffff4f993db in QEventLoop::exec(QFlagsQEventLoop::ProcessEventsFlag) () at /lib64/libQt6Core.so.6
#30 0x00007ffff4f92bb6 in QCoreApplication::exec() () at /lib64/libQt6Core.so.6
#31 0x00000000004792ba in main ()
@raphaelthegreat commented on GitHub (Jul 1, 2024):
Try launching emulator standalone without the gui (so CLI)
@gilcel commented on GitHub (Jul 1, 2024):
Ok need to recompile it then...will do in debug mode
@gilcel commented on GitHub (Jul 1, 2024):
FYI: When generating cmake build files, it complains with (but build-files are properly written...):
-- Could NOT find magic_enum (missing: magic_enum_DIR)
-- Could NOT find SDL3 (missing: SDL3_DIR)
-- Could NOT find toml11 (missing: toml11_DIR)
CMake Warning at CMakeLists.txt:90 (find_package):
Could not find a configuration file for package "VulkanHeaders" that is
compatible with requested version "1.3.288".
The following configuration files were considered but not accepted:
-- Could NOT find VulkanMemoryAllocator (missing: VulkanMemoryAllocator_DIR)
-- Could NOT find xbyak (missing: xbyak_DIR)
-- Could NOT find xxHash: (Required is at least version "0.8.2") (found )
-- Could NOT find zlib-ng: (Required is at least version "2.1.6") (found )
-- Could NOT find Zydis (missing: Zydis_DIR)
@raphaelthegreat commented on GitHub (Jul 1, 2024):
If it didn't error out it should be fine. Also consider pinging me on discord as github issues isn't the best medium for support
@psucien commented on GitHub (Jul 7, 2024):
Is this resolved?
@gilcel commented on GitHub (Jul 7, 2024):
Unfortunately no...compiled with latest commit
189033awithcmake . --config Debugand now shadPS4 doesn't even display an error message, only "Segmentation fault" with a core dump (compiled and tested with and without GUI)....With gdb :
(gdb) run $HOME/shadPS4/build/shadps4 $HOME/Downloads/PS4/HelloWorld/eboot.bin@ryzendew commented on GitHub (Jul 14, 2024):
This also happens on my RTX 3070 on arch linux
@gilcel commented on GitHub (Aug 22, 2024):
Followup: The Linux shadPS4-v0.20 AppImage works on OpenSUSE Tumbleweed. It runs the OpenOrbis Graphics Sample etc.
Compiled latest v.0.2.1-WIP
83bccedand tried to start the Graphics demo: instead of the previousmemory.cpp:operator()error it crashes again but with the following error:(gdb) bt(gdb) frameIncreasing
max_map_countdidn't change anything=>vm.max_map_count=524288in/etc/sysctl.conf@gilcel commented on GitHub (Sep 12, 2024):
This issue can be closed, since launching the demos works now! But I didn't investigate which commit fixed it (I was away for one week and recompiled with latest code
1b12138today and launched the demos: it just works :-) Thanks for all your effort.