Commit Graph

39104 Commits

Author SHA1 Message Date
Pokechu22 c94aacc968 AudioPane: Fix inconsistent initial state of audio stretching labels
This resulted in the labels being solid black even when audio stretching is disabled the first time the settings are opened, but then properly being greyed out after changing a setting (even the audio backend or DSP emulation engine, not just whether audio stretching is enabled).
2023-02-17 18:51:41 -08:00
Admiral H. Curtiss 74abf48234
Merge pull request #11576 from yannhodiesne/convert-prevent-file-deletion
Check the input and destination paths before converting a game file onto itself
2023-02-17 18:49:15 +01:00
Markus Wick b381df700c
Merge pull request #11577 from JosJuice/android-armeabi-v7a
Android: Fix armeabi-v7a build
2023-02-17 17:57:38 +01:00
JosJuice 90b676d368 Android: Fix armeabi-v7a build
This very much isn't a build configuration that we're going to ship,
but I want to be able to tell people that they can build it on their
own if they really want to see how terribly it performs :)

Just like before, you'll need to edit two lines in app/build.gradle to
define ENABLE_GENERIC=ON and actually enable armeabi-v7a if you want an
armeabi-v7a build. This commit just fixes some compilations errors that
crop up if you do so.
2023-02-17 16:58:24 +01:00
Yann Hodiesne 49e897422f
Use a success count instead of files count 2023-02-17 15:49:31 +01:00
Yann Hodiesne cb42a03299
Check the input and destination paths before converting a game file onto itself
Before these changes you could tell Dolphin to convert a game file into the same format it is already in, leading to the FileDialog using the input path as the default destination path
An unsuspecting user could then click Save and Dolphin would try to convert the input file by writing the destination file on top of it... leading to an I/O error and the input file being entirely removed
2023-02-17 14:26:50 +01:00
Scott Mansell 28331c5905
Merge pull request #11574 from K0bin/val-fix
VideoBackends:Vulkan: Fix printing validation errors
2023-02-17 14:52:45 +13:00
Markus Wick 1903116d8e
Merge pull request #11575 from AdmiralCurtiss/mtmsr-5byte-jmp
Jit64: Use 5 byte jump in mtmsr for the CP interrupt check.
2023-02-16 19:38:13 +01:00
Admiral H. Curtiss 0c48324c75
Jit64: Use 5 byte jump in mtmsr for the CP interrupt check.
WriteExternalExceptionExit() can write more than the maximum offset of the small jump.
2023-02-16 19:26:19 +01:00
Robin Kertels 2695666e6d
VideoBackends:Vulkan: Fix printing validation errors 2023-02-16 17:53:15 +01:00
Mai f004080382
Merge pull request #11573 from Pokechu22/freesurround-bad-delete
Externals/FreeSurround: Fix pointer created through new[] being freed via delete
2023-02-16 03:44:33 -05:00
Scott Mansell 6038a6e2db
Merge pull request #11569 from Hibyehello/patch-1
VideoBackend: Make Metal Default on MacOS
2023-02-16 21:08:35 +13:00
Pokechu22 a7026ca6d3 Externals/FreeSurround: Fix pointer created through new[] being freed via delete
Doing so is not allowed (presumably because compilers are allowed to use a different algorithm for allocating between the two/store extra data such as the length of the array before the pointer).

This bug existed in the original implementation at https://web.archive.org/web/20140708092159/http://www.hydrogenaud.io/forums/index.php?showtopic=52235 and causes Valgrind to emit a warning. Note that this ended up happening even if DSPLLE and the DPL decoder are not enabled in Dolphin.
2023-02-15 21:56:49 -08:00
Mai 19bf13d3bb
Merge pull request #11572 from Pokechu22/uninitialized-variables-feb-2023
Fix uninitialized variable warnings (C26495)
2023-02-16 00:56:01 -05:00
Pokechu22 74a14c7d1f ControllerInterface: Fix uninitialized variables in DualShockUDPClient
Strangely, this case did not trigger a C26495 warning in Visual Studio's analyzer; instead, I spotted this when using Valgrind.
2023-02-15 19:23:47 -08:00
Pokechu22 67381cdb8b VideoCommon: Remove unused ShutdownImGui function declaration
This was moved to the ~OnScreenUI() destructor in 0d4537d60f.
2023-02-15 19:20:59 -08:00
Pokechu22 8802f96b7e Fix uninitialized variable warnings (C26495) 2023-02-15 19:18:39 -08:00
Josh cd38ed76e2
Keep Vulkan precedence over OpenGL 2023-02-15 12:22:56 -06:00
Josh 546a016dc8
VideoBackend: Make Metal Default on MacOS 2023-02-15 12:05:54 -06:00
Admiral H. Curtiss 089eab96d7
Merge pull request #11567 from AdmiralCurtiss/create-full-path-behavior-change
Common/FileUtil: Revert behavior of CreateFullPath().
2023-02-15 03:12:24 +01:00
Admiral H. Curtiss c36994a90d
Add unit test for File::CreateFullPath(). 2023-02-15 02:56:10 +01:00
Admiral H. Curtiss 0758e00cfe
Common/FileUtil: Revert behavior of CreateFullPath().
This was accidentally changed in 7e6436db34.
2023-02-15 02:21:50 +01:00
Admiral H. Curtiss 661b74f4a3
Merge pull request #11564 from JosJuice/jitarm64-cmp-order
JitArm64: Fix special cases of cmp
2023-02-14 20:19:07 +01:00
Admiral H. Curtiss e1d3237dbd
Merge pull request #11342 from TellowKrinkle/GLLayerMac
VideoCommon: Fix stereoscopic 3D on OpenGL < 4.3 (macOS)
2023-02-14 20:17:22 +01:00
JosJuice 0049a76775 JitArm64: Fix special cases of cmp
This fixes a regression from 592ba31. When `a` was a constant 0 and `b`
was a non-constant 0x80000000, the 32-bit negation operation would
overflow, causing an incorrect result. The sign extension needs to happen
before the negation to avoid overflow.

Note that I can't merge the SXTW and NEG into one instruction.
NEG is an alias for SUB with the first operand being set to ZR,
but "SUB (extended register)" treats register 31 as SP instead of ZR.

I've also changed the order for the case where `a` is a constant
0xFFFFFFFF. I don't think the order actually affects correctness here,
but let's use the same order for all the cases since it makes the code
easier to reason about.
2023-02-14 19:16:00 +01:00
Admiral H. Curtiss 22ed084209
Merge pull request #11563 from JosJuice/host-lock-cpu-fixups
Follow-up fixes for "Properly lock CPU before accessing emulated memory"
2023-02-14 19:04:21 +01:00
JosJuice 5b6784432c Follow-up fixes for "Properly lock CPU before accessing emulated memory" 2023-02-14 18:44:16 +01:00
TellowKrinkle f25a0b43b6 VideoCommon: Fix stereoscopic 3D on OpenGL < 4.3 (macOS) 2023-02-14 18:25:33 +01:00
Scott Mansell ba3c38a63f
Merge pull request #11406 from Pokechu22/intel-less-dual-source
VideoCommon: Clear blend configuration if color/alpha update disabled
2023-02-14 18:27:40 +13:00
Pokechu22 4f6ce51d69 VideoCommon: Clear blend configuration if color/alpha update disabled
This works around an Intel driver bug where, on D3D12 only, dual-source blending behaves incorrectly if the second source is unused on. This bug is visible in skyboxes in Super Mario Sunshine, which first draw clouds and sun flare in greyscale and then draw the sky afterwards with a source factor of 1 and a dest factor of 1-src_color (this results in the clouds being tinted blue). This process is done on an RGB888 framebuffer, so alpha update is disabled. (Color update is enabled; note that if you look at this in Dolphin's fifo analyzer, it won't be enabled because they use the BP mask functionality to only change the blending functions and not alpha/color update, for whatever reason.)
2023-02-13 18:22:41 -08:00
Admiral H. Curtiss 5f929d00eb
Merge pull request #11560 from phire/EventHook_construct_on_first_use
HookableEvent: Switch to construct on first use
2023-02-14 01:01:03 +01:00
Admiral H. Curtiss 34a459bed7
Merge pull request #11445 from JosJuice/jit64-wraparound-backpatch
Jit64: Properly handle backpatching overflowed address calculations
2023-02-14 01:00:13 +01:00
Admiral H. Curtiss 3458c58c7d
Merge pull request #11503 from JosJuice/ppcanalyst-read-cr
PPCAnalyst: Actually check if instructions want CR
2023-02-14 00:55:24 +01:00
Admiral H. Curtiss e2d7b6d079
Merge pull request #11559 from Pokechu22/cache-fix-plru-updates
PPCCache: Update PLRU on any cache access
2023-02-14 00:50:54 +01:00
Admiral H. Curtiss 8f91cb62e6
Merge pull request #11426 from shuffle2/stdfs
fileutil: use std::filesystem
2023-02-14 00:50:34 +01:00
JosJuice 9d139ea84e
Merge pull request #11561 from AdmiralCurtiss/hle-execute-fix
JIT: Fix calls to HLE::Execute.
2023-02-13 12:09:36 +01:00
Admiral H. Curtiss e1dbea3658
JIT: Fix calls to HLE::Execute.
This got broken in 7cecb28bdf.
2023-02-13 11:47:47 +01:00
Scott Mansell 05181f6b88 HookableEvent: Switch to construct on first use
A registration might happen during static initialization, which opens
us up to issues with ordering of static initialization.
2023-02-13 18:48:43 +13:00
Scott Mansell 1fc5d37fd2
Merge pull request #11558 from Pokechu22/vertex-loader-size-assertion-details
VertexLoader: Add more info to m_vertex_size == m_src_ofs assertion
2023-02-13 17:34:04 +13:00
Pokechu22 cc411c4e41 VertexLoader: Add more info to m_vertex_size == m_src_ofs assertion 2023-02-12 20:10:38 -08:00
Pokechu22 14c4f4e7f6 PPCCache: Update PLRU on any cache access
The previous code only updated the PLRU on cache misses, which made it so that the least recently inserted cache block was evicted, instead of the least recently used/hit one.

This regressed in 9d39647f9e (part of #11183, but it was fine in e97d380437), although beforehand it was only implemented for the instruction cache, and the instruction cache hit extremely infrequently when the JIT or cached interpreter is in use, which generally keeps it from behaving correctly (the pure interpreter behaves correctly with it).

I'm not aware of any games that are affected by this, though I did not do extensive testing.
2023-02-12 19:59:19 -08:00
Scott Mansell a4729a026f
Merge pull request #11554 from JosJuice/host-lock-cpu
DolphinQt: Properly lock CPU before accessing emulated memory
2023-02-13 16:08:36 +13:00
Scott Mansell f37113204f
Merge pull request #11550 from iwubcode/set_common_samplers_count
VideoCommon: add constant value for maximum number of pixel samplers
2023-02-13 16:05:51 +13:00
Scott Mansell 2c24d07837
Merge pull request #11538 from t895/disc-speed-stuff
Rename "Speed up Disc Transfer Rate" to "Emulate Disc Speed"
2023-02-13 15:46:56 +13:00
Charles Lombardo 0ed64b080f Rename Fast Disc Speed to Emulate Disc Speed and invert option 2023-02-12 16:20:38 -05:00
Charles Lombardo d0941342d2 Android: Expose Emulate Disc Speed 2023-02-12 16:20:38 -05:00
Admiral H. Curtiss 5ef014e55a
Merge pull request #11556 from AdmiralCurtiss/plain-file-s64
DiscIO/FileBlob: Make m_size unsigned.
2023-02-12 21:22:56 +01:00
Admiral H. Curtiss 300d63b492
DiscIO/FileBlob: Make m_size unsigned. 2023-02-12 20:51:08 +01:00
JosJuice 611e721a4d Jit64: Properly handle backpatching overflowed address calculations
Previously we would only backpatch overflowed address calculations
if the overflow was 0x1000 or less. Now we can handle the full 2 GiB
of overflow in both directions.

I'm also making equivalent changes to JitArm64's code. This isn't because
it needs it – JitArm64 address calculations should never overflow – but
because I wanted to get rid of the 0x100001000 inherited from Jit64 that
makes even less sense for JitArm64 than for Jit64.
2023-02-12 20:48:27 +01:00
Admiral H. Curtiss 9737345a9e
Merge pull request #11493 from icup321/master
GameINI: Heavy Iron updates
2023-02-12 19:34:12 +01:00