31796 Commits

Author SHA1 Message Date
JMC47
43a6ec5bbd
Merge pull request #13353 from iwubcode/custom_shader_overhaul_vertex_texcoord
VideoCommon: move texcoord calculations to accessible functions in VertexShaderGen
2025-02-22 02:32:47 -05:00
JosJuice
af064c57de
Merge pull request #13219 from Tilka/cp_cleanup
VideoCommon: drop CP MMIO registers that were probably added in the wrong place
2025-02-17 21:27:19 +01:00
Aneesh Maganti
fffb499da2
Core/HW: Add time tracking thread in CPU manager
Introduce method to track the time played for a game via time differences and TimePlayed methods. Threads are synchronized via Common::Event.
2025-02-16 23:15:12 +01:00
Aneesh Maganti
3c44fe592b
DolphinQt: Add "Time Played" column to game list view
Shows minutes/hours in the list view and handles column visibility.
2025-02-16 23:15:11 +01:00
Aneesh Maganti
276f043db8
DolphinQt: Create toggle for enabling/disabling time tracking
Introduce a new "Enable Time Tracking" checkbox in the InterfacePane UI. The checkbox is dynamically enabled or disabled based on the emulation state, preventing changes while emulation is active.
2025-02-16 23:15:11 +01:00
Aneesh Maganti
a9ebedbf7d
Core/Config: Add settings for time tracking 2025-02-16 23:15:11 +01:00
Aneesh Maganti
892d6e30df
Core/ConfigManager: Add locks for metadata methods
All metadata access methods now acquire a lock on `m_metadata_lock` to prevent race conditions.
2025-02-16 23:15:11 +01:00
Aneesh Maganti
803241c64b
Core: Add TimePlayed class to track game playtime
Creates TimePlayed class and implemented constructors, AddTime, GetTimePlayed, and Reload methods. Updates CMakeLists.txt and DolphinLib.props as appropriate.
2025-02-16 23:15:11 +01:00
Admiral H. Curtiss
aced90de97
Merge pull request #13329 from noahpistilli/guard-startup-patches
Core: Check if msr.DR and msr.IR are valid at ApplyStartupPatches
2025-02-16 16:14:35 +01:00
JMC47
343007fa9e
Merge pull request #13343 from jordan-woyak/dark-theme-indicator-gate-colors
DolphinQt/Mapping: Adjust dark theme indicator gate color calculation.
2025-02-15 16:34:30 -05:00
Jordan Woyak
66624abb12 DolphinQt/Mapping: Clear and skip "Modifier" iterative input mappings when using
analog inputs.
2025-02-15 14:15:51 -06:00
Jordan Woyak
3189de6c7a DolphinQt: Add setting to enable iterative input mappings. 2025-02-15 14:15:51 -06:00
JMC47
a8fae9b826
Merge pull request #13320 from jordan-woyak/detect-alternations
DolphinQt/Mapping: Add setting to enable waiting for alternate mappings.
2025-02-15 12:59:23 -05:00
JMC47
c360ea0d9d
Merge pull request #13344 from Tilka/dither
VideoCommon: simplify dither calculation
2025-02-15 00:32:14 -05:00
JMC47
0fc36bbfa9
Merge pull request #13341 from jordan-woyak/sd-convert-buttons-rename
DolphinQt: Rename the pack/unpack SD Card buttons.
2025-02-15 00:31:40 -05:00
JMC47
f9accfd4d6
Merge pull request #13324 from Sintendo/jitarm64-cmp-imm
JitArm64_Integer: cmp/cmpl optimizations
2025-02-15 00:30:34 -05:00
JMC47
ac2026dd6e
Merge pull request #13322 from Xphalnos/D3D_Update
VideoBackends: Use DXGI 1.6 and D3D11_4
2025-02-15 00:30:13 -05:00
iwubcode
1ce78dd9b4 VideoCommon: move texcoord calculations to accessible functions in VertexShaderGen 2025-02-14 22:44:49 -06:00
Jordan Woyak
adc5b81c31 DolphinQt: Rename the pack/unpack SD Card buttons. 2025-02-12 13:30:48 -06:00
Tillmann Karras
5db6bd6054 VideoCommon: simplify dither calculation
This saves three instructions on AMD GPUs. Dunno about Nvidia.
2025-02-11 19:23:37 +00:00
Jordan Woyak
165e35ed5d DolphinQt/Mapping: Adjust dark theme indicator gate color calculation. 2025-02-10 01:15:58 -06:00
Tillmann Karras
19d954eaea VideoCommon: remove CP readonly field, it's now always false 2025-02-08 11:46:49 +00:00
Tillmann Karras
84e72c185a VideoCommon: drop CP MMIO registers that were probably added in the wrong place
I think someone confused these with the actual token and bounding box
registers in PE, which were added later. In CP they never did anything
and it's suspicious that they have the same addresses as their PE
counterparts. On real hardware they always read as zero.
2025-02-08 11:46:49 +00:00
OatmealDome
c770e7c276
Merge pull request #13318 from sanjay900/dont-detach-macos
LibusbDevice: Don't detach kernel drivers on macOS
2025-02-08 01:01:58 -05:00
Admiral H. Curtiss
c6be362a8c
Merge pull request #13334 from jordan-woyak/mplus-lround
WiimoteEmu/MotionPlus: Gyro data calculation cleanup.
2025-02-06 22:20:24 +01:00
Admiral H. Curtiss
b1f1d7d6a7
Merge pull request #13327 from jordan-woyak/input-expressions-compound-assignment
InputCommon/ExpressionParser: Add compound assignment operators.
2025-02-06 22:15:51 +01:00
Admiral H. Curtiss
05f217bd0b
Merge pull request #13330 from Dentomologist/performancemetrics_allow_moving_overlays
PerformanceMetrics: Allow users to move overlays
2025-02-06 21:56:57 +01:00
Admiral H. Curtiss
dcfb1361d2
Merge pull request #13223 from mitaclaw/branch-watch-tool-fixes-5
Branch Watch Tool: Refresh Context Menus OnEmulationStateChanged
2025-02-06 21:52:50 +01:00
JosJuice
db285b7c87
Merge pull request #13319 from hoogmin/infinite-style-fix
Refactor: Infinite loop in AsyncShaderCompiler according to style guidelines
2025-02-06 18:31:28 +01:00
Javier Martinez
7dec083af5 Refactor: Make loop non-infinite instead in AsyncShaderCompiler. 2025-02-05 20:06:59 -05:00
Admiral H. Curtiss
6ee08fb9db
Merge pull request #13302 from TryTwo/Breakpoints_Fix_Lag
Breakpoints: Fix lag when loading multiple memory breakpoints
2025-02-05 18:27:22 +01:00
TryTwo
bbf72e79f9 Breakpoints: Fix lag when adding or removing multiple memory breakpoints by only calling DBATUpdated() once. 2025-02-04 00:21:13 -07:00
Jordan Woyak
c857a7dd82 WiimoteEmu: Use a named constant instead of a magic number for speaker
data writes.
2025-02-03 19:52:38 -06:00
Jordan Woyak
857c93c529 WiimoteEmu/MotionPlus: Gyro data calculation cleanup. 2025-02-03 02:05:47 -06:00
Dentomologist
4b8e36cba9 PerformanceMetrics: Allow users to move overlays
Allow users to move the FPS, VPS, Speed, and Performance Graph overlays.
2025-02-02 19:40:01 -08:00
Sketch
4499718368 Core: Check if msr.DR or msr.IR are valid at ApplyStartupPatches 2025-02-02 17:27:16 -05:00
Dentomologist
f94e6cb73e PerformanceMetrics: Call ImGui::End() unconditionally
Move ImGui::End() calls out of if(ImGui::Begin()) blocks.

Quoting from ImGui::Begin's function comment in imgui.cpp:
"You always need to call ImGui::End() even if false is returned."

In practice this didn't cause problems because the windows don't have
title bars and thus can't be collapsed, and so the block containing
::End would always run, but let's do it the right way.
2025-02-02 14:14:56 -08:00
Jordan Woyak
cdabd651aa InputCommon/ExpressionParser: Add compound assignment operators. 2025-02-02 14:37:11 -06:00
Admiral H. Curtiss
f1fe32c93b
Merge pull request #13254 from brad0/openbsd_aarch64
ArmCPUDetect: Add OpenBSD support for elf_aux_info
2025-02-02 18:12:03 +01:00
Admiral H. Curtiss
77056ba7b7
Merge pull request #13208 from Dentomologist/wiitasinputwindow_update_on_attachment_change
WiiTASInputWindow: Update controls when attachment changes
2025-02-02 18:02:58 +01:00
Admiral H. Curtiss
017e0b5658
Merge pull request #13306 from OatmealDome/cubeb-optional
CMakeLists: Add flag to disable Cubeb
2025-02-02 17:50:20 +01:00
Admiral H. Curtiss
6a3a74508d
Merge pull request #13317 from cristian64/spurious_config_file
DolphinQt: Use global settings object also for debugger settings.
2025-02-02 17:25:24 +01:00
Admiral H. Curtiss
9ff833e2f4
Merge pull request #13315 from jordan-woyak/func-exp-cleanup
InputCommon/ExpressionParser: Function argument parsing minor cleanup.
2025-02-02 17:23:13 +01:00
Admiral H. Curtiss
04775b6ef8
Merge pull request #13314 from jordan-woyak/input-expressions-assignment-op-fix
InputCommon: Fix input expression assignment operator behavior.
2025-02-02 17:22:25 +01:00
Sintendo
755c003265 JitArm64_RegCache: Const correctness
Forgot this when I added it in #13120.
2025-02-02 12:57:59 +01:00
Sintendo
7ce7da629e JitArm64_Integer: cmpl - Subtract shifted 12-bit constant
You can encode a shifted 12-bit immediate in a SUB instruction on ARM64.
We exploit this to avoid materializing the immediate.

This approach saves an instruction if it does not need to be
materialized in a register afterwards. Otherwise, we just materialize
it later and the total number of instructions stays the same.

Before:
0x52a00218   mov    w24, #0x100000            ; =1048576
0xcb180379   sub    x25, x27, x24

After:
0xd1440379   sub    x25, x27, #0x100, lsl #12 ; =0x100000
2025-02-02 12:57:59 +01:00
Sintendo
b7c3f91643 JitArm64_Integer: cmpl - Subtract 12-bit constant
You can encode a 12-bit immediate in a SUB instruction on ARM64. We can
exploit this to avoid materializing the immediate.

This approach saves an instruction if it does not need to be
materialized in a register afterwards. Otherwise, we just materialize
it later and the total number of instructions stays the same.

Before:
0x5280003a   mov    w26, #0x1                 ; =1
0xcb1a033b   sub    x27, x25, x26

After:
0xd100073b   sub    x27, x25, #0x1
2025-02-02 12:57:59 +01:00
Sintendo
c5870ed0c7 JitArm64_Integer: cmp - Skip sign extension if possible
While we cannot always avoid materializing immediates, we can still
inspect the most significant bit and potentially skip sign extension.
This can sometimes save an instruction.

Before:
0x5280003a   mov    w26, #0x1                 ; =1
0x93407f5b   sxtw   x27, w26
0xcb38c37b   sub    x27, x27, w24, sxtw

After:
0x5280003a   mov    w26, #0x1                 ; =1
0xcb38c35b   sub    x27, x26, w24, sxtw

Before:
0x52a20018   mov    w24, #0x10000000          ; =268435456
0x93407f79   sxtw   x25, w27
0xcb38c339   sub    x25, x25, w24, sxtw

After:
0x52a20018   mov    w24, #0x10000000          ; =268435456
0x93407f79   sxtw   x25, w27
0xcb180339   sub    x25, x25, x24
2025-02-02 12:57:49 +01:00
Sintendo
075c35602f JitArm64_Integer: cmp - Add shifted 12-bit constant
You can encode a shifted 12-bit immediate in an ADD instruction on
ARM64. If the negated constant fits in this range, we can exploit this
to avoid materializing the immediate.

This approach saves an instruction if it does not need to be
materialized in a register afterwards. Otherwise, we just materialize
it later and the total number of instructions stays the same.

Before:
0x52bff01a   mov    w26, #-0x800000           ; =-8388608
0x93407f1b   sxtw   x27, w24
0xcb3ac37b   sub    x27, x27, w26, sxtw

After:
0x93407f1b   sxtw   x27, w24
0x9160037b   add    x27, x27, #0x800, lsl #12 ; =0x800000
2025-02-02 12:01:08 +01:00
Sintendo
01eed0a758 JitArm64_Integer: cmp - Add 12-bit constant
You can encode a 12-bit immediate in an ADD instruction on ARM64. If the
negated constant fits in this range, we can exploit this to avoid
materializing the immediate.

This approach saves an instruction if it does not need to be
materialized in a register afterwards. Otherwise, we just materialize
it later and the total number of instructions stays the same.

Before:
0x12800019   mov    w25, #-0x1                ; =-1
0x93407f5b   sxtw   x27, w26
0xcb39c37b   sub    x27, x27, w25, sxtw

After:
0x93407f5b   sxtw   x27, w26
0x9100077b   add    x27, x27, #0x1
2025-02-02 12:01:05 +01:00