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

Make stopping emulation not pause or crash UI #14038

Merged
merged 2 commits into from
Jun 26, 2023
Merged

Conversation

elad335
Copy link
Contributor

@elad335 elad335 commented Jun 16, 2023

  • Like Loader: Make executable analyzation not halt UI when launching games #13630 which made loading games not freeze UI, before this pull request stopping emulation made the UI freeze and if took too long Windows may even make the window white and try to kill the application. But with this pr the UI is fully responsive when stopping emulation, this is also true for savestates which had an even longer pause. (albeit currently still suffering from regressions)

  • If you have been unlucky, you could have randomly encounter "Stopping emulation took too long" message after a few seconds when quitting the game and then the emulator simply crashed. Now you can choose to wait more for it to close safely or force terminate RPCS3. In case it closes safely while the dialog is open the dialog would close automatically. There is an indication of how many seconds have passed waiting in the dialog as well.

image

@elad335 elad335 force-pushed the stop-emu branch 2 times, most recently from 9080f3b to 8d92560 Compare June 16, 2023 18:36
rpcs3/rpcs3qt/gui_application.cpp Outdated Show resolved Hide resolved
rpcs3/rpcs3qt/gui_application.cpp Outdated Show resolved Hide resolved
rpcs3/rpcs3qt/gui_application.cpp Outdated Show resolved Hide resolved
rpcs3/rpcs3qt/gui_application.cpp Outdated Show resolved Hide resolved
rpcs3/headless_application.cpp Outdated Show resolved Hide resolved
rpcs3/rpcs3qt/gs_frame.cpp Show resolved Hide resolved
rpcs3/Emu/System.cpp Outdated Show resolved Hide resolved
@elad335 elad335 force-pushed the stop-emu branch 2 times, most recently from 5a8cb96 to 732b9f0 Compare June 16, 2023 18:56
rpcs3/Emu/System.cpp Outdated Show resolved Hide resolved
@elad335 elad335 force-pushed the stop-emu branch 2 times, most recently from def30bb to 0812dfc Compare June 16, 2023 19:48
@elad335 elad335 changed the title Emulation: Make stopping emulation not pause or crash UI Make stopping emulation not pause or crash UI Jun 18, 2023
@elad335 elad335 requested a review from Megamouse June 19, 2023 07:15
@elad335 elad335 requested a review from Megamouse June 25, 2023 18:40
@elad335 elad335 force-pushed the stop-emu branch 4 times, most recently from 4b283c5 to 257fd41 Compare June 26, 2023 16:03
@elad335
Copy link
Contributor Author

elad335 commented Jun 26, 2023

Updated text message to be more clear.

* Make the UI and main thread available when stopping emulation.
* Make BlockingCallFromMainThread always execute, preventing bugs when it unexpectedly did not.
* Add error code for when starting emulation when Emu.Kill() is in progress.
@elad335 elad335 requested a review from Megamouse June 26, 2023 18:24
@Megamouse Megamouse merged commit d34b319 into RPCS3:master Jun 26, 2023
4 of 5 checks passed
@elad335 elad335 deleted the stop-emu branch May 6, 2024 17:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants