Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Windows][System] PPSSPP is not release some system files when Invalid memory access error happend. #13796

Closed
nassau-tk opened this issue Dec 20, 2020 · 10 comments
Labels
User Interface PPSSPP's own user interface / UX
Milestone

Comments

@nassau-tk
Copy link
Contributor

nassau-tk commented Dec 20, 2020

What happens?

PPSSPP is not release some system files when Invalid memory access error happend.

  • It will happen on v1.10.3-1357-g89d20e4ab or later.
  • Not happen on before [v1.10.3-1331-g381313ec9].

How to find it?

  1. Play BLEACH SC1(Any games OK.If will happen IMA error.) and make happen invalid memory access error.
  2. Finish PPSSPP.(Close window.)
  3. Try un-rar some update file of PPSSPP.(Overwrite.)
  4. It will appear warning dialog that appear "The proccess can't access the file.Other proccess is using."warning.
    Is it working to right?

It will happen any backend.
If I repair to working normaly then I must reboot Windows.

What should happen?

It should be release all system files when PPSSPP finished.

What hardware, operating system, and PPSSPP version? On desktop, GPU matters for graphical issues.

PPSSPP Ver.:1.10.3-1357
OS:Windows10(64-bit)Japanese
CPU:Ryzen7 3800X(8-core)
GPU:RADEON RX5700XT
Resolution:2560×1440
RAM:32GB

[This dialog will appear when un-rar & overwrite.]
image

@nassau-tk
Copy link
Contributor Author

And,If restart PPSSPP with don't reboot Windows then it will not playing any sounds when like a double boot PPSSPP.

@anr2me
Copy link
Collaborator

anr2me commented Dec 20, 2020

Does PPSSPP exe still stuck in memory (on TaskManager->Details) after closing the window when it happened?

@hrydgard
Copy link
Owner

Yeah almost certainly you don't have to log out or restart, it'll be enough to just kill the process form Task Manager.

That said, this is of course something that needs to be fixed.

@hrydgard hrydgard added this to the v1.11.0 milestone Dec 20, 2020
@hrydgard hrydgard added the User Interface PPSSPP's own user interface / UX label Dec 20, 2020
@nassau-tk
Copy link
Contributor Author

Add more strange point.
If changing backends by these pattern then I couldn't change automatically.

  • OpenGL to D3D9
  • OpenGL to D3D11
  • OpenGL to Vulkan

[Log of OpenGL to Vulkan]
20:19:360 ui\nativeapp.cpp:1379 I[G3D]: NativeResized - setting flag
20:19:640 ui\discordintegration.cpp:59 I[SYSTEM]: Discord connection initialized
20:19:640 ui\nativeapp.cpp:620 I[SYSTEM]: Boot filename found in args: 'E:/!Emu!/!PSP ROM/ヱヴァンゲリヲン:序.iso'
20:19:653 core\config.cpp:1420 I[LOADER]: Config saved (got storage permission): 'C:\Users\dtkad\Desktop\PPSSPP\memstick/PSP/SYSTEM/ppsspp.ini'
20:19:654 core\config.cpp:1433 I[LOADER]: Controller config saved: C:\Users\dtkad\Desktop\PPSSPP\memstick/PSP/SYSTEM/controls.ini
20:19:784 opengl\glfeatures.cpp:194 I[G3D]: GPU Vendor : ATI Technologies Inc. ; renderer: AMD Radeon RX 5700 XT version str: 4.6.14757 Core Profile Context 20.12.1 27.20.14501.28009 ; GLSL version str: 4.60
20:19:784 opengl\glfeatures.cpp:108 D[G3D]: Checking for GL driver bugs... vendor=2 model='AMD Radeon RX 5700 XT'
20:19:784 opengl\thin3d_gl.cpp:214 D[G3D]: Shader module created (0000022DAB3A58F0)
20:19:784 opengl\thin3d_gl.cpp:214 D[G3D]: Shader module created (0000022DAB3A5870)
20:19:784 opengl\thin3d_gl.cpp:214 D[G3D]: Shader module created (0000022DAB3A66F0)
20:19:784 opengl\thin3d_gl.cpp:214 D[G3D]: Shader module created (0000022DAB3A67F0)
20:19:784 opengl\thin3d_gl.cpp:214 D[G3D]: Shader module created (0000022DAB3A5470)
20:19:784 windows\emuthread.cpp:233 I[BOOT]: Done.
20:19:785 ui\nativeapp.cpp:827 I[SYSTEM]: NativeInitGraphics
20:19:785 opengl\glrendermanager.cpp:133 I[G3D]: Updating inflight frames to 2
20:19:788 ui\nativeapp.cpp:896 I[SYSTEM]: NativeInitGraphics completed
20:19:826 opengl\glrendermanager.cpp:236 I[G3D]: Running first frame (0)
20:19:971 core\config.cpp:1420 I[LOADER]: Config saved (clearFailedGPUBackends): 'C:\Users\dtkad\Desktop\PPSSPP\memstick/PSP/SYSTEM/ppsspp.ini'
20:19:972 core\config.cpp:1433 I[LOADER]: Controller config saved: C:\Users\dtkad\Desktop\PPSSPP\memstick/PSP/SYSTEM/controls.ini
20:20:424 file\fileutil.cpp:663 I[COMMON]: CreateEmptyFile: C:\Users\dtkad\Desktop\PPSSPP\installedTEMP.txt
20:20:424 file\fileutil.cpp:261 I[COMMON]: Delete: file C:\Users\dtkad\Desktop\PPSSPP\installedTEMP.txt
20:20:448 file\fileutil.cpp:335 D[COMMON]: CreateFullPath: path exists C:\Users\dtkad\Desktop\PPSSPP\memstick/PSP/SYSTEM
20:31:537 core\config.cpp:1420 I[LOADER]: Config saved (GameSettingsScreen::RenderingBackendYes): 'C:\Users\dtkad\Desktop\PPSSPP\memstick/PSP/SYSTEM/ppsspp.ini'
** 20:31:538 core\config.cpp:1433 I[LOADER]: Controller config saved: C:\Users\dtkad\Desktop\PPSSPP\memstick/PSP/SYSTEM/controls.ini **

PPSSPP is not reboot automatically after last line.
And, I couldn't overwrite update file at this case too.

@nassau-tk
Copy link
Contributor Author

[Log of reboot by manually.]
26:15:756 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:756 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:756 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:756 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:756 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:756 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:756 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:756 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:756 util\blockallocator.cpp:253 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:757 util\portmanager.cpp:469 I[SCENET]: UPnPService: End of UPnPService Thread
26:15:759 hle\proadhocserver.cpp:1705 I[SCENET]: AdhocServer: Shutdown complete
26:15:759 hle\proadhocserver.cpp:1711 I[SCENET]: AdhocServer: End of AdhocServer Thread
26:15:759 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:759 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:759 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:759 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:759 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:762 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:762 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:762 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:762 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:762 util\blockallocator.cpp:253 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:762 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:762 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:762 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:762 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:762 util\blockallocator.cpp:253 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:762 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:762 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:762 util\blockallocator.cpp:253 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:762 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:15:762 util\blockallocator.cpp:253 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:15:767 core\memmap.cpp:363 D[MEMMAP]: Memory system shut down.

@hrydgard
Copy link
Owner

Is this the memory access bug you are using to test this? #13346

@nassau-tk
Copy link
Contributor Author

nassau-tk commented Dec 20, 2020

Is this the memory access bug you are using to test this? #13346

Yes,I tested by #13346 .
But,The log is not related #13346 .

@nassau-tk
Copy link
Contributor Author

[ Log of BLEACH SC1 ]

  1. BLEACH SC1 Invalid Memory Access
  2. Reteurn to menu.

26:35:823 fioThread D[SCEKERNEL]: hle\scekernelsemaphore.cpp:305 sceKernelSignalSema(306, 1) (count: 0 -> 1)

26:35:823 fioThread D[SCEKERNEL]: hle\scekernelsemaphore.cpp:413 0=sceKernelWaitSema(282, 1, 0)
26:35:823 fnThread D[SCEKERNEL]: hle\scekernelthread.cpp:3107 Context switch: fioThread -> fnThread (284->304, pc: 08805ec4->08805700, sema waited) +22us
26:35:823 fnThread D[SCEKERNEL]: hle\scekernelsemaphore.cpp:305 sceKernelSignalSema(307, 1) (count: 0 -> 1)
26:35:823 fnThread D[SCEKERNEL]: hle\scekernelsemaphore.cpp:413 0=sceKernelWaitSema(308, 1, 0)
26:35:823 user_main D[SCEKERNEL]: hle\scekernelthread.cpp:3107 Context switch: fnThread -> user_main (304->276, pc: 08806a5c->088156bc, sema waited) +22us
26:35:823 user_main W[MEMMAP]: core\core.cpp:445 Read Word: Invalid address 10811090 PC 08811398 LR 088113e4 08813db8_z_un_08813d84
mov esi, [rbx+rdi+0x10]

26:35:823 user_main E[MEMMAP]: core\memfault.cpp:192 Bad memory access detected! 10811090 (000001BAACD91090) Stopping emulation. Info:
08813db8_z_un_08813d84
mov esi, [rbx+rdi+0x10]

26:40:601 user_main I[SYSTEM]: common\exceptionhandlersetup.cpp:92 Removed exception handler
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 272: Thread "idle0": pc= 08000000 sp= 083fff00 READY (wt=0 wid=0 wv= 00000000 )
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 273: Thread "idle1": pc= 08000000 sp= 083fef00 READY (wt=0 wid=0 wv= 00000000 )
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 274: Module "mainTest": name=mainTest gp=00000000 entry=0882173c
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 276: Thread "user_main": pc= 088156bc sp= 09fff530 RUN (wt=0 wid=0 wv= 0000000f )
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 277: MemoryPart "UserSbrk": MemPart: 08a3e000 - 09e3e000 size: 01400000
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 278: CallBack "exit": thread=276, argument= 00000000
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 279: CallBack "power": thread=276, argument= 00000000
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 280: CallBack "SysUmd": thread=276, argument= 00000000
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 281: Thread "Sched": pc= 08817900 sp= 09fbfa70 WAIT (wt=12 wid=1 wv= 00000000 )
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 282: Semaphore "fio Sema": -
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 283: Semaphore "fio_ReEnt Sema": -
26:40:601 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 284: Thread "fioThread": pc= 08805ec4 sp= 09fbea90 WAIT (wt=3 wid=282 wv= 00000001 )
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 285: Semaphore "add client": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 286: Module "scePsmfP_library": faked name=scePsmfP_library gp=ffffffff entry=ffffffff
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 287: Module "scePsmf_library": faked name=scePsmf_library gp=ffffffff entry=ffffffff
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 288: Semaphore "add client": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 289: Thread "Global Pad": pc= 08807564 sp= 09fbcaa0 WAIT (wt=15 wid=1 wv= 08a200d0 )
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 290: Semaphore "add client": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 291: EventFlag "SceGuSignal": init=00000001 cur=00000001 numwait=0
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 292: Semaphore "disp Done Sema": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 293: Semaphore "msg Sema": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 294: Semaphore "wait Sema": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 295: Thread "dispThread": pc= 08817abc sp= 09fbaa80 WAIT (wt=3 wid=296 wv= 00000001 )
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 296: Semaphore "add client": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 297: Semaphore "msg Sema": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 298: Semaphore "wait Sema": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 299: Thread "drawThread": pc= 08807fd8 sp= 09fb9a70 WAIT (wt=3 wid=292 wv= 00000001 )
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 300: Semaphore "draw Done Sema": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 301: Semaphore "msg Sema": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 302: Semaphore "wait Sema": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 303: Semaphore "fn Sema": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 304: Thread "fnThread": pc= 08806a5c sp= 09fb8940 WAIT (wt=3 wid=308 wv= 00000001 )
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 305: Semaphore "fio Sema tmp": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 306: Semaphore "fio Sema tmp": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 307: Semaphore "fn Decord Sema": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 308: Semaphore "fn Decord Sema End": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 309: Thread "fnDecordThread": pc= 0880698c sp= 09fb7a90 READY (wt=3 wid=307 wv= 00000001 )
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 310: OpenFile "umd0:": Seekpos: 00016c08
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 311: Mutex "SceLibsndp": -
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:524 KO 312: Thread "muscbThread": pc= 089c4298 sp= 09fb6a90 WAIT (wt=10 wid=6 wv= 00000100 )
26:40:602 user_main I[SCEKERNEL]: hle\scekernel.cpp:172 Shutting down kernel - 40 kernel objects alive
26:40:602 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:602 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:602 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:602 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:602 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:602 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:602 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:602 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:602 util\blockallocator.cpp:253 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:604 hle\proadhocserver.cpp:1705 I[SCENET]: AdhocServer: Shutdown complete
26:40:604 hle\proadhocserver.cpp:1711 I[SCENET]: AdhocServer: End of AdhocServer Thread
26:40:605 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:605 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:605 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:605 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:605 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:605 util\portmanager.cpp:469 I[SCENET]: UPnPService: End of UPnPService Thread
26:40:605 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:605 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:605 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:605 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:605 util\blockallocator.cpp:253 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:605 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:606 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:606 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:606 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:606 util\blockallocator.cpp:253 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:606 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:606 util\blockallocator.cpp:233 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:606 util\blockallocator.cpp:253 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:606 util\blockallocator.cpp:228 D[SCEKERNEL]: Merging Blocks
26:40:606 util\blockallocator.cpp:253 D[SCEKERNEL]: Block Alloc found adjacent free blocks - merging
26:40:615 core\memmap.cpp:363 D[MEMMAP]: Memory system shut down.
26:40:618 common\framebuffermanagercommon.cpp:1888 I[FRAMEBUF]: Destroying FBO for 04000000 : 480 x 272 x 1
26:40:618 common\framebuffermanagercommon.cpp:1888 I[FRAMEBUF]: Destroying FBO for 04044000 : 480 x 272 x 1
26:40:618 common\texturecachecommon.cpp:1685 I[G3D]: Texture cached cleared from 350 textures

@nassau-tk
Copy link
Contributor Author

nassau-tk commented Dec 20, 2020

I found a 2 cause of the issue.

  1. Invalid Memory Access error.
  2. Changing Backend from OpenGL to Other.

@hrydgard
Copy link
Owner

I reverted the change that caused this, unfortunately this causes a D3D11 exit crash to resurface but I'll have to fix that in a better way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
User Interface PPSSPP's own user interface / UX
Projects
None yet
Development

No branches or pull requests

3 participants