libretro / pcsx_rearmed

ARM optimized PCSX fork
GNU General Public License v2.0
168 stars 120 forks source link

[Lightrec] Castlevania - Symphony of the Night is unplayable with Richter when dynarec is enabled #647

Closed bslenul closed 2 years ago

bslenul commented 2 years ago

Saw this issue few days ago: https://www.reddit.com/r/RetroArch/comments/u5uvta/trying_to_pay_castlevania_symphony_of_the_night/

When playing as Richter you're stuck mid-air after a jump if the dynarec core option is enabled, and if you manage to touch the ground again there are some graphical glitches, the game can even crash.

https://user-images.githubusercontent.com/33353403/164433173-5b4cbe93-1a3c-43a8-9a34-de8eca8bc35e.mp4

GDB output when triggering a crash ``` (gdb) thread apply all bt full Thread 53 (Thread 10396.0x2660): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 52 (Thread 10396.0x18a4): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 51 (Thread 10396.0x2144): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 50 (Thread 10396.0x88c): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 49 (Thread 10396.0xbf8): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 48 (Thread 10396.0x4794 "NVFBCAsyncThread"): #0 0x00007ff99f92d8c4 in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5ccb10 in WaitForMultipleObjectsEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff99d5cca0e in WaitForMultipleObjects () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #3 0x00007ff951b5f8a7 in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff951dbb48a in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #5 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #6 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #7 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #8 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 47 (Thread 10396.0x30f4): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff669433d2f in _scond_wait_win32 (cond=0x1cae021e450, lock=0x1cae021e3f0, dwMilliseconds=10000) at libretro-common/rthreads/rthreads.c:685 myentry = {next = 0x0} ptr = 0x1cae021e460 performanceCounterFrequency = {{LowPart = 10000000, HighPart = 0}, u = {LowPart = 10000000, HighPart = 0}, QuadPart = 10000000} tsBegin = {{LowPart = 3267988186, HighPart = 9}, u = {LowPart = 3267988186, HighPart = 9}, QuadPart = 41922693850} first_init = false waitResult = 0 dwFinalTimeout = 10000 #3 0x00007ff669433f9f in scond_wait_timeout (cond=0x1cae021e450, lock=0x1cae021e3f0, timeout_us=10000000) at libretro-common/rthreads/rthreads.c:848 dwMilliseconds = 10000 #4 0x00007ff669090e74 in autosave_thread (data=0x1cae021e310) at tasks/task_save.c:234 timeout_us = 1000000 differ = false save = 0x1cae021e310 #5 0x00007ff669433636 in thread_wrap (data_=0x1cae021e510) at libretro-common/rthreads/rthreads.c:143 data = 0x1cae021e510 #6 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #7 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #8 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 46 (Thread 10396.0x3ed8): #0 0x00007ff99f92d8c4 in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5ccb10 in WaitForMultipleObjectsEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff99d5cca0e in WaitForMultipleObjects () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #3 0x00007ff8f6072891 in xaudio2!DllUnregisterServer () from C:\WINDOWS\system32\XAudio2_7.dll No symbol table info available. #4 0x00007ff8f6072b8a in xaudio2!DllUnregisterServer () from C:\WINDOWS\system32\XAudio2_7.dll No symbol table info available. #5 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #6 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #7 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 45 (Thread 10396.0x1f10): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 44 (Thread 10396.0x3dc4): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 43 (Thread 10396.0x360c): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 42 (Thread 10396.0x448c): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 41 (Thread 10396.0x300c): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 40 (Thread 10396.0x1ad8): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff9523b4bcb in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff9523b3daa in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff9523a8b3d in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #5 0x00007ff951dbb48a in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #6 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #7 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #8 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #9 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 39 (Thread 10396.0x43cc): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951c91c7f in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 38 (Thread 10396.0xab8): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 37 (Thread 10396.0x4504): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 36 (Thread 10396.0x3864): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 35 (Thread 10396.0x3260): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff951dce1df in nvwgf2umx!NVDEV_Thunk () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #3 0x00007ff952b37778 in nvwgf2umx!OpenAdapter12 () from C:\WINDOWS\System32\DriverStore\FileRepository\nvddi.inf_amd64_0e2fb78c67ddb7a5\nvwgf2umx.dll No symbol table info available. #4 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #5 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 33 (Thread 10396.0x7bc): #0 0x00007ff99d85a104 in win32u!NtUserMsgWaitForMultipleObjectsEx () from C:\WINDOWS\System32\win32u.dll No symbol table info available. #1 0x00007ff99e58078e in USER32!MsgWaitForMultipleObjectsEx () from C:\WINDOWS\System32\user32.dll No symbol table info available. #2 0x00007ff96b2b200b in GetdfDIJoystick () from C:\WINDOWS\SYSTEM32\dinput8.dll No symbol table info available. #3 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #4 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #5 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 32 (Thread 10396.0x508): #0 0x00007ff99f92d8c4 in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5ccb10 in WaitForMultipleObjectsEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff99d5cca0e in WaitForMultipleObjects () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #3 0x00007ff96cc81e48 in ?? () from G:\msys64\mingw64\bin\libwinpthread-1.dll No symbol table info available. #4 0x00007ff96cc82186 in ?? () from G:\msys64\mingw64\bin\libwinpthread-1.dll No symbol table info available. #5 0x00007ff96cc827bc in ?? () from G:\msys64\mingw64\bin\libwinpthread-1.dll No symbol table info available. #6 0x00007ff8f5c0dfd3 in lightrec_recompiler_thd (d=0x1cadf000278) at deps/lightrec/recompiler.c:119 thd = 0x1cadf000278 rec = 0x1cadf000240 #7 0x00007ff96cc84f33 in ?? () from G:\msys64\mingw64\bin\libwinpthread-1.dll No symbol table info available. #8 0x00007ff99dc0af5a in msvcrt!_beginthreadex () from C:\WINDOWS\System32\msvcrt.dll No symbol table info available. #9 0x00007ff99dc0b02c in msvcrt!_endthreadex () from C:\WINDOWS\System32\msvcrt.dll No symbol table info available. #10 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #11 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #12 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 30 (Thread 10396.0x30a0): #0 0x00007ff99f92cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5a1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff669433d2f in _scond_wait_win32 (cond=0x1cad397ff50, lock=0x1cad3985be0, dwMilliseconds=4294967295) at libretro-common/rthreads/rthreads.c:685 myentry = {next = 0x0} ptr = 0x1cad397ff60 performanceCounterFrequency = {{LowPart = 10000000, HighPart = 0}, u = {LowPart = 10000000, HighPart = 0}, QuadPart = 10000000} tsBegin = {{LowPart = 0, HighPart = 0}, u = {LowPart = 0, HighPart = 0}, QuadPart = 0} first_init = false waitResult = 0 dwFinalTimeout = 4294967295 #3 0x00007ff669433e1f in scond_wait (cond=0x1cad397ff50, lock=0x1cad3985be0) at libretro-common/rthreads/rthreads.c:731 No locals. #4 0x00007ff669088f54 in threaded_worker (userdata=0x0) at libretro-common/queues/task_queue.c:489 task = 0x0 finished = false #5 0x00007ff669433636 in thread_wrap (data_=0x1cad38c4c10) at libretro-common/rthreads/rthreads.c:143 data = 0x1cad38c4c10 #6 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #7 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #8 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 23 (Thread 10396.0x2070): #0 0x00007ff99f9307c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99f8e2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 6 (Thread 10396.0x1a40): #0 0x00007ff99f92d8c4 in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99d5ccb10 in WaitForMultipleObjectsEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff99a617fff in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #3 0x00007ff99a617ce9 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #4 0x00007ff99a617471 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #5 0x00007ff99a616744 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #6 0x00007ff99a61996b in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #7 0x00007ff99a616c28 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #8 0x00007ff99a64ebf5 in CoreUICreateEx () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #9 0x00007ff99a64da7b in CoreUICreateEx () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #10 0x00007ff9932f25ba in SetInputFocus () from C:\WINDOWS\SYSTEM32\InputHost.dll No symbol table info available. #11 0x00007ff9932f6809 in InputHost!DllGetActivationFactory () from C:\WINDOWS\SYSTEM32\InputHost.dll No symbol table info available. #12 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #13 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #14 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 5 (Thread 10396.0x648): #0 0x00007ff99f9307c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ff99f8e2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ff99f147034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ff99f8e2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 1 (Thread 10396.0x2dc8): #0 0x000001ca824a0083 in ?? () No symbol table info available. Backtrace stopped: previous frame identical to this frame (corrupt stack?) ```

During another crash I didn't get anything, GDB just said "No stack" with this before:

ERROR: Segmentation fault in recompiled code: invalid load/store at address 0xee66eef2
ERROR: Was executing block PC 0x80014154
Exiting at cycle 0x89afe4da

Tested on Windows 10. No idea when it started, latest working version I can test is 641d7badb70e58c4fbab04fa70212e6e7b7cdaaa, after that either the core doesn't build, or the game crashes on launch or the glitch happens.

@pcercuei

bslenul commented 2 years ago

https://www.reddit.com/r/RetroArch/comments/u9k7pj/after_this_monster_kills_me_a_cutscene_is/

Silent Hill has issues as well, after dying in the intro a FMV should be playing where Harry wakes up in a bar, with dynarec enabled you're stuck on the floor and you can "slide" in circle:

https://user-images.githubusercontent.com/33353403/164791572-3e9773e4-80d1-4634-ad3f-acb1131c79ba.mp4

pcercuei commented 2 years ago

@bslenul Castlevania fixed in the latest Lightrec master. It might have fixed the Silent Hill bug as well. If it didn't, can you provide me with a savestate?

bslenul commented 2 years ago

Hm, so I did:

cd deps
rm -rf lightrec
git clone https://github.com/pcercuei/lightrec.git
cd ..
make -f Makefile.libretro clean
make -f Makefile.libretro -j4

Is that correct? It compiled fine but it crashes on launch.

GDB output ``` (gdb) thread apply all bt full Thread 32 (Thread 1516.0x27c8): #0 0x00007ffe9ff11750 in ntdll!RtlCompareMemoryUlong () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fe9dd00 in ntdll!RtlAllocateHeap () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9fe9b44d in ntdll!RtlAllocateHeap () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #3 0x00007ffe9ff687d8 in ntdll!RtlRegisterSecureMemoryCacheCallback () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x00007ffe9fe9d255 in ntdll!RtlAllocateHeap () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #5 0x00007ffe9fe9b44d in ntdll!RtlAllocateHeap () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #6 0x00007ffe9ee39d40 in msvcrt!malloc () from C:\WINDOWS\System32\msvcrt.dll No symbol table info available. #7 0x00007ffdf731b90b in jit_default_alloc_func (size=49152) at deps/lightning/lib/jit_memory.c:110 No locals. #8 0x00007ffdf731b823 in jit_alloc (ptr=0x1f7fa5c22b0, size=49152) at deps/lightning/lib/jit_memory.c:86 No locals. #9 0x00007ffdf732034a in _new_pool (_jit=0x1f7fa5c0ac0) at deps/lightning/lib/lightning.c:770 list = 0xa0 offset = 0 #10 0x00007ffdf732043a in _new_node (_jit=0x1f7fa5c0ac0, code=jit_code_prolog) at deps/lightning/lib/lightning.c:786 node = 0x1f7fb417fe0 #11 0x00007ffdf7320cb1 in _jit_new_node_no_link (_jit=0x1f7fa5c0ac0, code=jit_code_prolog) at deps/lightning/lib/lightning.c:984 No locals. #12 0x00007ffdf7327e8f in _jit_prolog (_jit=0x1f7fa5c0ac0) at deps/lightning/lib/jit_x86.c:430 offset = 0 #13 0x00007ffdf7367b39 in lightrec_compile_block (cstate=0x1f7eec9f270, block=0x1f7fa5bf9f0) at deps/lightrec/lightrec.c:1195 state = 0x1f7fa9c8040 target = 0x59611ffc00 op_list_freed = false fully_tagged = true block2 = 0x1f7fb417fe0 elm = 0x0 _jit = 0x1f7fa5c0ac0 oldjit = 0x0 start_of_block = 0x7ffdf736e7e7 skip_next = false code_size = 329 i = 4214990824 j = 503 offset = 503 #14 0x00007ffdf736e8a4 in lightrec_compile_list (rec=0x1f7fb40e0b0, thd=0x1f7fb40e0e8) at deps/lightrec/recompiler.c:94 block_rec = 0x1f7fb3ba7e0 next = 0x1f7fb3ba7e8 block = 0x1f7fa5bf9f0 ret = 0 #15 0x00007ffdf736ea33 in lightrec_recompiler_thd (d=0x1f7fb40e0e8) at deps/lightrec/recompiler.c:126 thd = 0x1f7fb40e0e8 rec = 0x1f7fb40e0b0 #16 0x00007ffe86b94f33 in ?? () from G:\msys64\mingw64\bin\libwinpthread-1.dll No symbol table info available. #17 0x00007ffe9ee5af5a in msvcrt!_beginthreadex () from C:\WINDOWS\System32\msvcrt.dll No symbol table info available. #18 0x00007ffe9ee5b02c in msvcrt!_endthreadex () from C:\WINDOWS\System32\msvcrt.dll No symbol table info available. #19 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #20 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #21 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 30 (Thread 1516.0x457c): #0 0x00007ffe9ff0cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9d6f1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff66e8c3d2f in _scond_wait_win32 (cond=0x1f7fb3cd300, lock=0x1f7f019c4f0, dwMilliseconds=4294967295) at libretro-common/rthreads/rthreads.c:685 myentry = {next = 0x0} ptr = 0x1f7fb3cd310 performanceCounterFrequency = {{LowPart = 10000000, HighPart = 0}, u = {LowPart = 10000000, HighPart = 0}, QuadPart = 10000000} tsBegin = {{LowPart = 0, HighPart = 0}, u = {LowPart = 0, HighPart = 0}, QuadPart = 0} first_init = false waitResult = 0 dwFinalTimeout = 4294967295 #3 0x00007ff66e8c3e1f in scond_wait (cond=0x1f7fb3cd300, lock=0x1f7f019c4f0) at libretro-common/rthreads/rthreads.c:731 No locals. #4 0x00007ff66e518f54 in threaded_worker (userdata=0x0) at libretro-common/queues/task_queue.c:489 task = 0x0 finished = false #5 0x00007ff66e8c3636 in thread_wrap (data_=0x1f7eec97d80) at libretro-common/rthreads/rthreads.c:143 data = 0x1f7eec97d80 #6 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #7 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #8 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 23 (Thread 1516.0x77c): #0 0x00007ffe9ff107c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fec2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 9 (Thread 1516.0x2454): #0 0x00007ffe9ff0d8c4 in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9d71cb10 in WaitForMultipleObjectsEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ffe9da6bee7 in CertFreeCTLContext () from C:\WINDOWS\System32\crypt32.dll No symbol table info available. #3 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #4 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #5 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 6 (Thread 1516.0x1208): #0 0x00007ffe9ff0d8c4 in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9d71cb10 in WaitForMultipleObjectsEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ffe9abf7fff in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #3 0x00007ffe9abf7ce9 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #4 0x00007ffe9abf7471 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #5 0x00007ffe9abf6744 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #6 0x00007ffe9abf996b in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #7 0x00007ffe9abf6c28 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #8 0x00007ffe9ac2ebf5 in CoreUICreateEx () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #9 0x00007ffe9ac2da7b in CoreUICreateEx () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #10 0x00007ffe934b25ba in SetInputFocus () from C:\WINDOWS\SYSTEM32\InputHost.dll No symbol table info available. #11 0x00007ffe934b6809 in InputHost!DllGetActivationFactory () from C:\WINDOWS\SYSTEM32\InputHost.dll No symbol table info available. #12 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #13 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #14 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 5 (Thread 1516.0x1298): #0 0x00007ffe9ff107c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fec2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 4 (Thread 1516.0x2210): #0 0x00007ffe9ff107c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fec2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 3 (Thread 1516.0x36b4): #0 0x00007ffe9ff107c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fec2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 2 (Thread 1516.0x2d00): #0 0x00007ffe9ff107c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fec2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 1 (Thread 1516.0x658): #0 0x000001f7f0af0051 in ?? () No symbol table info available. Backtrace stopped: previous frame identical to this frame (corrupt stack?) ```
pcercuei commented 2 years ago

Probably #645, try again.

bslenul commented 2 years ago

That issue mentions states, I'm not trying to load any, RA simply crashes when I attempt to load any game.

I tried changing #define ENABLE_THREADED_COMPILER 1 to #define ENABLE_THREADED_COMPILER 0 but then compilation fails:

In file included from deps/lightrec/recompiler.c:13:
deps/lightrec/recompiler.c: In function 'lightrec_recompiler_run_first_pass':
deps/lightrec/recompiler.c:366:43: error: 'struct block' has no member named 'op_list_freed'
  366 |    freed = atomic_flag_test_and_set(&block->op_list_freed);
      |                                           ^~
deps/lightrec/recompiler.c:384:41: error: 'struct block' has no member named 'op_list_freed'
  384 |  freed = atomic_flag_test_and_set(&block->op_list_freed);
      |                                         ^~
deps/lightrec/recompiler.c:390:27: error: 'struct block' has no member named 'op_list_freed'
  390 |   atomic_flag_clear(&block->op_list_freed);
      |                           ^~
deps/lightrec/recompiler.c:395:38: error: 'struct block' has no member named 'op_list_freed'
  395 |      !atomic_flag_test_and_set(&block->op_list_freed)) {
      |                                      ^~
pcercuei commented 2 years ago

@bslenul remove deps/lightrec/recompiler.o from the list of objects to build in the Makefile

bslenul commented 2 years ago

OK, it compiled this time but still crashes on launch.

GDB output ``` (gdb) thread apply all bt full Thread 30 (Thread 17084.0x4f4): #0 0x00007ffe9ff0cdf4 in ntdll!ZwWaitForSingleObject () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9d6f1a5e in WaitForSingleObjectEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ff66e8c3d2f in _scond_wait_win32 (cond=0x24010e4cff0, lock=0x24005c8c4f0, dwMilliseconds=4294967295) at libretro-common/rthreads/rthreads.c:685 myentry = {next = 0x0} ptr = 0x24010e4d000 performanceCounterFrequency = {{LowPart = 10000000, HighPart = 0}, u = {LowPart = 10000000, HighPart = 0}, QuadPart = 10000000} tsBegin = {{LowPart = 0, HighPart = 0}, u = {LowPart = 0, HighPart = 0}, QuadPart = 0} first_init = false waitResult = 0 dwFinalTimeout = 4294967295 #3 0x00007ff66e8c3e1f in scond_wait (cond=0x24010e4cff0, lock=0x24005c8c4f0) at libretro-common/rthreads/rthreads.c:731 No locals. #4 0x00007ff66e518f54 in threaded_worker (userdata=0x0) at libretro-common/queues/task_queue.c:489 task = 0x0 finished = false #5 0x00007ff66e8c3636 in thread_wrap (data_=0x24004637d80) at libretro-common/rthreads/rthreads.c:143 data = 0x24004637d80 #6 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #7 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #8 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 23 (Thread 17084.0x3174): #0 0x00007ffe9ff107c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fec2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 9 (Thread 17084.0x2c70): #0 0x00007ffe9ff0d8c4 in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9d71cb10 in WaitForMultipleObjectsEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ffe9da6bee7 in CertFreeCTLContext () from C:\WINDOWS\System32\crypt32.dll No symbol table info available. #3 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #4 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #5 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 6 (Thread 17084.0x4648): #0 0x00007ffe9ff0d8c4 in ntdll!ZwWaitForMultipleObjects () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9d71cb10 in WaitForMultipleObjectsEx () from C:\WINDOWS\System32\KernelBase.dll No symbol table info available. #2 0x00007ffe9abf7fff in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #3 0x00007ffe9abf7ce9 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #4 0x00007ffe9abf7471 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #5 0x00007ffe9abf6744 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #6 0x00007ffe9abf996b in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #7 0x00007ffe9abf6c28 in CreateDispatcherQueueController () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #8 0x00007ffe9ac2ebf5 in CoreUICreateEx () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #9 0x00007ffe9ac2da7b in CoreUICreateEx () from C:\WINDOWS\SYSTEM32\CoreMessaging.dll No symbol table info available. #10 0x00007ffe934b25ba in SetInputFocus () from C:\WINDOWS\SYSTEM32\InputHost.dll No symbol table info available. #11 0x00007ffe934b6809 in InputHost!DllGetActivationFactory () from C:\WINDOWS\SYSTEM32\InputHost.dll No symbol table info available. #12 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #13 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #14 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 5 (Thread 17084.0x31b4): #0 0x00007ffe9ff107c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fec2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 4 (Thread 17084.0x45cc): #0 0x00007ffe9ff107c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fec2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 3 (Thread 17084.0x16e4): #0 0x00007ffe9ff107c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fec2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 2 (Thread 17084.0x744): #0 0x00007ffe9ff107c4 in ntdll!ZwWaitForWorkViaWorkerFactory () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #1 0x00007ffe9fec2dc7 in ntdll!TpReleaseCleanupGroupMembers () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #2 0x00007ffe9e077034 in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll No symbol table info available. #3 0x00007ffe9fec2651 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll No symbol table info available. #4 0x0000000000000000 in ?? () No symbol table info available. Backtrace stopped: previous frame inner to this frame (corrupt stack?) Thread 1 (Thread 17084.0x4054): #0 0x0000024011640051 in ?? () No symbol table info available. Backtrace stopped: previous frame identical to this frame (corrupt stack?) ```
pcercuei commented 2 years ago

I can reproduce the crashes. I mostly test in the standalone pcsx_rearmed emulator and the crashes don't happen there. So give me some time and I'll fix it. Your GDB traces are useless btw ;)

bslenul commented 2 years ago

Ah 😅 Sorry I don't know much about this stuff :p

pcercuei commented 2 years ago

@bslenul a workaround for the crash is to change this to use 0x10000000 instead: https://github.com/libretro/pcsx_rearmed/blob/master/libpcsxcore/psxmem.c#L150

bslenul commented 2 years ago

I pulled the latest changes from your repo, now SotN seems to work fine, no more jump glitch as Richter 👍 However Silent Hill now crashes a bit after the KCET logo on launch.

a workaround for the crash is to change this to use 0x10000000 instead: https://github.com/libretro/pcsx_rearmed/blob/master/libpcsxcore/psxmem.c#L150

So you mean changing that whole line with psxM = 0x10000000;? If so, SH still crashes after the KCET logo. No idea if it matters but I tested that change with both ENABLE_THREADED_COMPILER 1 and ENABLE_THREADED_COMPILER 0.

pcercuei commented 2 years ago

No, just replace the 0x80000000 with 0x10000000.

bslenul commented 2 years ago

OK, no change for me, SH still crashes after the KCET logo.

pcercuei commented 2 years ago

Yes, the crashes I was speaking about were the "all games crash on launch" ones, not the Silent Hill one.

bslenul commented 2 years ago

Ah I see, those don't happen anymore since I pulled the latest changes from your repo.

pcercuei commented 2 years ago

@bslenul Should be all good now.

Please also check the "dying in circles" issue, it may or may not have been fixed (I didn't check).

bslenul commented 2 years ago

It goes further, but when I select "New Game" RA crashes at the end the first loading screen.

edit: Same if I wait on the main menu, it crashes when the "gameplay demo" is supposed to start.

pcercuei commented 2 years ago

Yes, the problem is that by pulling the latest master to get the fix for Castlevania, you also get a lot of experimental stuff that hasn't been thoroughly tested yet ;)

I can reproduce the Silent Hill crash on the menu and I know why it happens. I'll fix it later.

pcercuei commented 2 years ago

@bslenul please try again now.

bslenul commented 2 years ago

It goes in-game now, the death is still glitched however, it's still not triggering the FMV and I can still turn around on the ground.

I made a state before the glitch but I can't load it, it shows this in the log console:

WARNING: Unimplemented opcode 0xfc5a0f94
WARNING: Unimplemented opcode 0x00000f94
WARNING: Unimplemented opcode 0xffff03d0
WARNING: Unimplemented opcode 0xffffff98
WARNING: Unimplemented opcode 0x0000debb
WARNING: Unimplemented opcode 0xffff038f
WARNING: Unimplemented opcode 0xfffffefe
WARNING: Unimplemented opcode 0xff66ffbf
WARNING: Unimplemented opcode 0x03ffff4b
WARNING: Unimplemented opcode 0xf0ebfa96
WARNING: Unimplemented opcode 0xff9800c0
WARNING: Unimplemented opcode 0x03fffefe
WARNING: Unimplemented opcode 0xffff8800
WARNING: Unknown opcode: 0xfc5a0f94 at PC 0x1f800008
WARNING: Unknown opcode: 0x00000f94 at PC 0x1f800010
WARNING: Unknown opcode: 0xffff03d0 at PC 0x1f80002c
WARNING: Unknown opcode: 0xffffff98 at PC 0x1f800030
WARNING: Unknown opcode: 0x0000debb at PC 0x1f800034
WARNING: Unknown opcode: 0xffff038f at PC 0x1f80003c
WARNING: Unknown opcode: 0xfffffefe at PC 0x1f800040
WARNING: Unknown opcode: 0xff66ffbf at PC 0x1f800050
WARNING: Unknown opcode: 0x03ffff4b at PC 0x1f800054
WARNING: Unknown opcode: 0xf0ebfa96 at PC 0x1f800058
WARNING: Unknown opcode: 0xff9800c0 at PC 0x1f80005c
WARNING: Unknown opcode: 0x03fffefe at PC 0x1f800060
WARNING: Unknown opcode: 0xffff8800 at PC 0x1f80006c

and RA crashes.

pcercuei commented 2 years ago

Ok, is that far in the game? I never played Silent Hill so I don't know what I'm supposed to do.

bslenul commented 2 years ago

No, it should take ~2mn to get there: when game loads, just run forward (hold Square to run) and just follow the girl then the corridors.

pcercuei commented 2 years ago

@bslenul it's fixed now.

bslenul commented 2 years ago

Awesome, thank you for the fixes 👍

pcercuei commented 2 years ago

@bslenul as for save states #650 should fix them. It'd be great if you could test it and report there.