Commit graph

25677 commits

Author SHA1 Message Date
JosJuice
f96ee475e4 Implement ArmFPURoundMode.cpp
Fixes https://bugs.dolphin-emu.org/issues/12388. Might also fix
other games that have problems with float/paired instructions
in JitArm64, but I haven't tested any.
2021-04-25 15:56:19 +02:00
Léo Lam
aa3a96f048
Merge pull request #9644 from JosJuice/jit-fallback-discard
Jits: Fix interpreter fallback handling of discarded registers
2021-04-25 13:20:41 +02:00
JosJuice
b3b5016f54 Jits: Fix interpreter fallback handling of discarded registers
When the interpreter writes to a discarded register, its type
must be changed so that it is no longer considered discarded.

Fixes a 62ce1c7 regression.
2021-04-25 13:01:40 +02:00
Léo Lam
1c6232e95f
Merge pull request #9646 from PatrickFerry/sw-textureencoder-alignedwidth
SW: Fix alignedWidth in TextureEncoder
2021-04-24 20:13:10 +02:00
Léo Lam
18174d3ed6
Merge pull request #9649 from leoetlino/cmake-auto-update-track
Make it possible to enable auto-updates by default with CMake builds
2021-04-24 19:44:51 +02:00
JMC47
18e84361d9
Merge pull request #9660 from ezio1900/master
VideoCommon: Fix scissorOffset, handle negative value correctly
2021-04-23 21:21:53 -04:00
ezio1900
97ea3a603e VideoCommon: Fix scissorOffset, handle negative value correctly
VideoCommon: Change the type of BPMemory.scissorOffset to 10bit signed: S32X10Y10
VideoBackends: Fix Software Clipper.PerspectiveDivide function, use BPMemory.scissorOffset instead of hard code 342
2021-04-24 08:46:21 +08:00
JosJuice
be5775614c
Merge pull request #9619 from leoetlino/scoped-fd
IOS/FS: Add a scoped FD class to make it harder to leak FDs
2021-04-23 21:53:25 +02:00
JosJuice
f0bd6b105f
Merge pull request #9663 from leoetlino/mios-hle-patch
Fix IPL crash when launching MIOS-patched games
2021-04-23 21:00:29 +02:00
JMC47
cfc4af76a9
Merge pull request #9321 from Pokechu22/sw-copyregion
Software: Fix out of bounds accesses in CopyRegion
2021-04-23 14:07:46 -04:00
JMC47
4ab92d4757
Merge pull request #9350 from Pokechu22/sw-viewport
Software: Invert backface test when viewport is positive
2021-04-23 14:06:02 -04:00
Léo Lam
1686b637df
MIOS: Fix SConfig::OnNewTitleLoad not being called
Oversight from #9545, which moved the "new game has been loaded" logic
to a separate OnNewTitleLoad function that has to be called explicitly
*after* a title has loaded.

Coupled with the commit that makes Dolphin not clobber 0x1800-0x3000
when using MIOS, this fixes Wind Waker and other MIOS-patched games
when they are launched from the System Menu.
2021-04-22 21:55:07 +02:00
Léo Lam
568428ca67
HLE: Do not clobber 0x1800-0x3000 when using MIOS to fix IPL crash
MIOS puts patch data in low MEM1 (0x1800-0x3000) for its own use.
Overwriting data in this range can cause the IPL to crash when
launching games that get patched by MIOS.
See https://bugs.dolphin-emu.org/issues/11952 for more info.

Not applying the Gecko HLE patches means that Gecko codes will not work
under MIOS, but this is better than the alternative of having specific
games crash.
2021-04-22 21:50:05 +02:00
Lioncash
adebc499f9 Jit64: Indicate explicit [[fallthrough]] within load helper 2021-04-19 17:37:44 -04:00
Lioncash
e1dfcda8a6 BlockingLoop: Add explicit [[fallthrough]] annotations 2021-04-19 17:34:46 -04:00
Patrick A. Ferry
f6a4368192 SW: Fix alignedWidth in TextureEncoder
This was causing issues in Software Renderer. Look at bug 11487
2021-04-19 02:06:52 +01:00
JMC47
821e51cda4
Merge pull request #7214 from stenzek/cp-access-sync
Fifo: Run/sync with the GPU on command processor register access
2021-04-18 11:17:25 -04:00
JosJuice
dbd39ab2a0
Merge pull request #9642 from CrunchBite/xlink-bba-fix
Fix crash when stopping a game that does not use the BBA when XLink Kai BBA is selected in configuration
2021-04-18 10:43:32 +02:00
JosJuice
92308f5e34
Merge pull request #9645 from leoetlino/fifoplayer-optimization
FifoPlayer: Copy data with memcpy instead of one byte at a time
2021-04-18 10:43:26 +02:00
Léo Lam
5f355690e0
Make it possible to enable auto-updates by default with CMake builds
This adds a CMake option (DOLPHIN_DEFAULT_UPDATE_TRACK) to allow
configuring SCM_UPDATE_TRACK_STR. This is needed to enable auto-updates
in Windows CMake builds by default.
2021-04-17 19:45:43 +02:00
Stenzek
e3ac5dca32 Fifo: Run/sync with the GPU on command processor register access 2021-04-18 03:24:01 +10:00
Léo Lam
cc32fa91af
FifoPlayer: Copy data with memcpy instead of one byte at a time
Copying with memcpy/std::copy is a lot faster than writing one byte
at a time. And the behavior should be fully equivalent.
2021-04-17 16:02:43 +02:00
Connor McLaughlin
edeb6bcdb7
Merge pull request #9635 from stenzek/amd-exclusive-fullscreen
Vulkan: Work around AMD exclusive fullscreen bug (21.3+)
2021-04-17 16:09:09 +10:00
CrunchBite
d6b2fe2c0a Fix crash when stopping a game that does not use the BBA 2021-04-15 09:01:52 -04:00
JMC47
14959a1087
Merge pull request #9636 from sspacelynx/mali-broken-and
DriverDetails: Fix broken vector bitwise AND on Mali drivers
2021-04-14 07:04:16 -04:00
Léo Lam
336518049d
WiiUtils: Add helper functions to get emulated/real Bluetooth device
This adds a function to get the emulated or real Bluetooth device for
an active emulation instance. This lets us deduplicate all the
`ios->GetDeviceByName("/dev/usb/oh1/57e/305")` calls that are currently
scattered in the codebase and ensures Bluetooth passthrough is being
handled correctly.

This also fixes the broken check in WiimoteCommon::UpdateSource.
There was a confusion between "emulated Bluetooth" (as opposed to
"real Bluetooth" aka Bluetooth passthrough) and "emulated Wiimote".
2021-04-12 18:16:56 +02:00
Léo Lam
136f59b434
DolphinQt: Fix latent build error on Windows 2021-04-12 18:16:56 +02:00
Connor McLaughlin
b24e3f2f1a Vulkan: Work around AMD exclusive fullscreen bug (21.3+) 2021-04-12 12:41:17 +10:00
sspacelynx
aba9cae5ab
DriverDetails: Fix broken vector bitwise AND on Mali drivers 2021-04-11 15:15:02 +02:00
JMC47
5322256065
Merge pull request #9625 from leoetlino/mmu-sdr-update
MMU: Fix SDR updates being silently dropped in some cases
2021-04-06 20:23:13 -04:00
Léo Lam
3b6fdb74f6
Merge pull request #9628 from Dentomologist/wiiutils_fix_reference_to_temporary_subobject
WiiUtils: Remove reference qualifier
2021-04-07 01:46:45 +02:00
Léo Lam
f18743ab89
Merge pull request #9576 from Pokechu22/invalid-gfx-reg-quirk
Add game quirks for unknown BP/CP/XF commands
2021-04-07 01:46:21 +02:00
Léo Lam
c1617460a1
Merge pull request #9480 from leoetlino/saturating-cast
MathUtil: Add SaturatingCast to cast floats more safely
2021-04-07 01:43:39 +02:00
Léo Lam
1a9e72c9bb
DiscIO: Use MathUtil::SaturatingCast 2021-04-06 23:27:23 +02:00
Léo Lam
48712168b8
MathUtil: Add SaturatingCast to cast floats more safely 2021-04-06 23:27:23 +02:00
Pokechu22
dad309d365 Disable ICache emulation for some games
Specifically, 'Scooby-Doo! Mystery Mayhem', 'Scooby-Doo! Unmasked', 'Ed, Edd n Eddy: The Mis-Edventures', and the Wii version of 'Happy Feet'.

The JIT cache causes problems with emulated icache invalidation in these games, resulting in areas failing to load.
2021-04-06 12:44:10 -07:00
Pokechu22
f32b771f7a Skip loading unknown XF registers in the FIFO player
This avoids some warnings, which were originally fixed by ignoring loads with a value of zero (see 636bedb207 / #3242).

Note that FifoCI will report some changes, but only on the first frame; these seem to be timing related as they don't happen if a different write is used to replace skipped ones.
2021-04-06 11:54:49 -07:00
Pokechu22
cde6cf2ab5 Track and log CP commands 0x00/0x10/0x20 differently from other unknown commands
They appear to relate to perf queries, and combining them with truely unknown commands would probably hide useful information.  Furthermore, 0x20 is issued by every title, so without this every title would be recorded as using an unknown command, which is very unhelpful.
2021-04-06 11:54:49 -07:00
Pokechu22
193f6a67a7 Log a warning for inexact uses of MATINDEX or VCD commands 2021-04-06 11:54:48 -07:00
Pokechu22
7fe1292c62 Add game quirks for unknown BP/CP/XF commands 2021-04-06 11:44:31 -07:00
Léo Lam
49edd5f482
MMU: Remove a bunch of useless swaps
The swaps are confusing and don't accomplish much.

It was originally written like this:

u32 pte = bswap(*(u32*)&base_mem[pteg_addr]);

then bswap was changed to Common::swap32, and then the array access
was replaced with Memory::Read_U32, leading to the useless swaps.
2021-04-06 18:25:29 +02:00
Léo Lam
960d957f4f
MMU: Fix SDR updates being silently dropped in some cases
While 6xx_pem.pdf §7.6.1.1 mentions that the number of trailing
zeros in HTABORG must be equal to the number of trailing ones
in the mask (i.e. HTABORG must be properly aligned), this is actually
not a hard requirement. Real hardware will just OR the base address
anyway. Ignoring SDR changes would lead to incorrect emulation.

Logging a warning instead of dropping the SDR update silently is a
saner behaviour.
2021-04-06 18:25:09 +02:00
Dentomologist
c892c27259 WiiUtils: Remove reference qualifier
Remove & to avoid reference to a temporary subobject.  Fixes error C2131
on upcoming version of msbuild.
2021-04-06 08:35:03 -07:00
Léo Lam
ac250f7c20
Merge pull request #9623 from Techjar/pauseandlock-fix
Core: Fix PauseAndLock segfaulting under certain circumstances
2021-04-06 12:45:35 +02:00
Léo Lam
e89ae71cec
Merge pull request #9388 from JosJuice/default-locale
Set console's default language/country/region based on computer settings
2021-04-06 12:34:58 +02:00
Léo Lam
a1ee6ace71
Merge pull request #9620 from Dentomologist/convert_gamelist_col_to_enum_class
Convert GameList col enum to enum class
2021-04-06 12:08:15 +02:00
JMC47
5222a4b7e5
Merge pull request #9585 from JosJuice/jitarm64-skip-carry
JitArm64: Skip calculating carry flag when not needed
2021-04-06 04:41:16 -04:00
JMC47
99d43362e6
Merge pull request #9351 from JosJuice/discard-registers
Jits: Discard registers which we know will be overwritten
2021-04-06 04:40:26 -04:00
Techjar
9235a9035b Core: Fix PauseAndLock segfaulting under certain circumstances
This can happen if it's called before the core has fully initialized.
2021-04-03 17:52:03 -04:00
Léo Lam
6d1eb6ae5a
Merge pull request #9621 from Pokechu22/cassert
Replace uses of cassert with Common/Assert.h
2021-04-03 12:46:21 +02:00