when a game already has a compatibility report, the context menu only
lets you copy the vita3k build summary. this adds a second action to
also copy the test environment summary (os, cpu, gpu, ram) so users
can paste it into existing issue comments without having to manually
type it out.
closes#3586
* gui-qt: don't crash on install file delete failures
when you install a .zip, .vpk, .pkg, or firmware .pup and tick the matching "delete after install" option, vita3k tries to remove the installer file from disk. the archive and pkg dialogs use the throwing fs::remove overload, which raises a filesystem_error when the file is locked by another process. since the call runs inside a qt slot, the exception escapes into the qt event loop and the whole emulator goes down with it.
the firmware dialog uses QFile::remove instead, which returns a bool that the code was ignoring, so a locked firmware file silently stuck around with no feedback to the user.
leaving the installer open in something like 7-zip while installing is enough to trigger either case.
this swaps fs::remove for the non-throwing error_code overload in the archive and pkg dialogs, and checks the bool from QFile::remove in the firmware dialog. anything that could not be removed gets shown in a warning so the user knows what stuck around, and the install itself still finishes normally.
* gui-qt: route firmware drops through the install dialog
dropping a .pup onto the main window used to run install_pup inline with a bare QProgressDialog and its own success/failure handling, bypassing FirmwareInstallDialog entirely. that path duplicated the progress UI and never offered the "delete firmware file after install?" option that the menu-triggered flow exposes.
route the drop through FirmwareInstallDialog instead, matching the existing .pkg and .vpk drop routing right next to it. this adds a constructor that takes a pre-supplied firmware path so the dialog skips its file picker when invoked from a drop.
dropped firmware installs now share the threaded progress UI, the warning when the file is locked, and the optional cleanup checkbox with the menu trigger.
Replace ThreadToDo and the something_to_do condvar with four boolean
flags: exit_requested, delete_requested, suspend_requested,
single_stepping. run_loop() returns void.
call_level brackets each frame: incremented on entry, decremented just
before return.
All call-level exits (normal exit, guest return, delete) converge on a
single block at the top of the loop that fires the end callback and parks
dormant. This wakes wait_thread_end waiters on every exit path.
If deleted, return completely from all run_loop() nested levels.
Replace `exit_delete_all_threads_and_wait()` with two separate operations:
- `process_exit()` blocks until all guest threads have exited (host-only)
- `request_process_exit()` fires the registered callback and returns immediately, safe to call from guest threads.
Threads are now SDL_DetachThread'd at creation. `thread_deleted_cond` on `KernelState` is used for join semantics in `process_exit()`.
Remove `shutting_down` from sync primitives; `exit_delete()` wakes blocked threads via `update_status(run)`, which all `status_cond` predicates already check.
`process_exit_callback` carries an `optional<AppLaunchRequest>` so `LoadExec` relaunches flow through the same path as normal exits. `AppLaunchRequest`/`AppLaunchReason` extracted to `emuenv/app_launch_request.h` so kernel can include it without a circular dependency.
After this, further simplification to `ThreadStatus` will be done in https://github.com/Vita3K/Vita3K/pull/3922.
- Add V3KN account management dialog wtih create/login/logout/delete account, change avatar/panel/password/online id/server, quota refresh.
- Add show server error/success popup inside V3KN account management dialog.
- Add Cloud screen to LiveArea with cloud button for upload/download savedata on V3KN
- Add "Please wait" and "Connecting… Please wait." dialogs for network operations (upload/download, auth)
- Add overwrite confirmation dialog and "Copying" progress dialogs for cloud/local saves.
- Draw Cloud icons.
util/net_utils: Some refactor and protocol improvements.
- Add Upload file func with multipart/form-data support
- Add keep-alive support for (download/upload)file.
- Refactor get_web_response() to support POST bodies and return server-side errors
- Refactor download_file() for stability and clearer error handling
- Clean up duplicated logic and unify request handling.
Each thread was allocating its own identical 4-byte NOP+WFI block.
Since all threads point LR at the same sentinel, one allocation in KernelState is sufficient.
Note that this is a Dynarmic-specific "hack" to make it stop execution (`jit->Run()`) after the guest code returns (jumps back LR):
- Prior JIT execution, we prepare LR to point to this NOP+WFI block.
- When the guest function returns, it will jump into this NOP+WFI block and `Dynarmic::A32::Exception::WaitForInterrupt` will be called. Then we call `cpu->jit->HaltExecution()` which will make `jit->Run()` return
`CPUProtocol::get_watch_memory_addr` is never used, so we can drop it.
After that, `CPUProtocol` only has `call_svc`, whose implementation is
just 3 lines: read the NID, call `call_import`, and `clear_exclusive`.
We can inline those at the call site and get rid of `CPUProtocol`
completely.
The Debugger trampoline API (`Trampoline` struct, `TrampolineCallback`,
`add_trampoline` / `get_trampoline` / `remove_trampoline`, `TRAMPOLINE_JUMPER_SVC`
and `TRAMPOLINE_HANDLER_SVC`, plus the two SVC-dispatch branches in
`CPUProtocol::call_svc`) has never had a caller.
Only DABT (type 0) is dispatched from run_loop. PABT (1) and UNDEF (2)
are stored in exception_handlers[] but never triggered. Log a warning
so it's obvious when a plugin expects a type we don't dispatch yet.
ksceKernelAllocRemoteProcessHeap returned 0 (invalid UID on Vita) and
ksceKernelRegisterProcEventHandler returned the same hardcoded 0x40001
on every call. Use atomic counters to return distinct UIDs so callers
that pass them back to the corresponding Free/Unregister don't collide.
- Trim find_import_stub segment-address dump to a one-liner (fires per NID)
- Remove module_get_offset success log (fires on every offset query)
- Remove module_get_export_func cache-hit log (fires on every export lookup)
- Promote dynamic SVC stub creation to LOG_INFO (one-time per NID, useful)
Raw new/delete across three allocation sites and one release site was
error-prone. Switched map to unique_ptr, removed the unused `next`
chain pointer, and eliminated the manual delete.
The computed MemPerm was logged but ignored — the function always called
unprotect_inner regardless of the protection flags. Now it mirrors the
kuKernelMemProtect logic: restrictive perms use add_protect so the fault
handler can catch violations; ReadWrite unprotects as before.
set_current_cpu_state was set on entry but never cleared. A recycled host
thread would carry a stale CPUState pointer into the next vita thread's
signal handler. Use a scope guard to clear it on all exit paths.
Using a single `dummy` field meant any unhandled MCR/MRC would read back
whatever the last unhandled write stored, silently corrupting guest reads.
Return CallbackOrAccessOneWord{} (no-op) instead.
- SceCpuForDriver: ksceKernelCpuIcacheInvalidateRange and
ksceKernelCpuIcacheAndL2WritebackInvalidateRange now call
invalidate_jit_cache() to properly invalidate dynarmic's JIT cache
- taiHEN: All loaded_modules accesses now protected by kernel.mutex
using scoped locks to avoid deadlocks with state->mutex and
export_nids_mutex (lock order: kernel.mutex -> export_nids_mutex -> state->mutex)