Commit Graph

13623 Commits

Author SHA1 Message Date
Ameer 12e679c39c Add LR triggers as axes, half press to initiate a press, add GC axis id in config, clarify some code blocks for better readability 2020-07-02 15:54:44 -04:00
Rodrigo Locatti d6569215b3 Merge pull request #4082 from Morph1984/mirror-once-clamp
maxwell_to_gl: Implement MirrorOnceClampOGL wrap mode using GL_MIRROR_CLAMP_EXT
2020-07-02 04:57:40 -03:00
VolcaEM 1b4a3851ca Rename two functions in NS
- Rename "GetShellEvent" to "GetShellEventHandle"
- Rename "LaunchApplicationFromHost" to "LaunchApplication"
2020-07-02 09:02:55 +02:00
VolcaEM 940c5932c7 Rename GetApplicationArea2 to GetApplicationAreaSize 2020-07-02 08:58:51 +02:00
Jan Beich c1bbc77b7c cmake: stop linking against QGL after 01a3b4f0de 2020-07-01 22:11:39 +00:00
ReinUsesLisp 308feff898 shader_cache: Fix use-after-free and orphan invalidation cache entries
This fixes some cases where entries could have been removed multiple
times reading freed memory. To address this issue this commit removes
duplicates from entries marked for removal and sorts out the removal
process to fix another use-after-free situation.

Another issue fixed in this commit is orphan invalidation cache entries.
Previously only the entries that were invalidated in the current
operations had its entries removed. This led to more use-after-free
situations when these entries were actually invalidated but referenced
an object that didn't exist.
2020-07-01 18:16:53 -03:00
Ameer 34e6084c8d Reset adapter state on init, fixes errors relating driver hang from unexpected unplug 2020-07-01 12:52:50 -04:00
David Marcec 73ca896cd6 Don't handle cycles late if stretcher is active
Timestretcher seems to be broken
2020-07-01 16:59:42 +10:00
David Marcec f0685697da audio: Improving audio timing for multicore/single core
Fixes the issue with needing the timestretcher for multicore.
2020-07-01 16:52:02 +10:00
David db7181fb16 Merge pull request #4217 from lioncash/prototype
key_manager: Make use of canonical deleted operator=
2020-07-01 16:13:14 +10:00
David Marcec 2961282fae externals: Track opus as submodule instead of using conan
Supersedes #4068 see for details.
2020-07-01 15:09:33 +10:00
LC ebc54570f3 Merge pull request #4208 from jbeich/freebsd
common: unbreak build on BSDs
2020-07-01 00:34:20 -04:00
Lioncash 1e362da176 key_manager: Correct casing of instance()
Our codebase uppercases member function names.
2020-07-01 00:28:50 -04:00
Lioncash 93f1d9435d key_manager: Delete move operations
Prevents the singleton from being moved from.
2020-07-01 00:24:38 -04:00
Lioncash e67ab9a1b7 key_manager: Make use of canonical deleted operator=
operator= typically returns a reference, it's not void.

While we're at it, we can correct the parameter formatting to adhere to the
codebase.
2020-07-01 00:21:31 -04:00
David 9d2a0f5f1a Merge pull request #3967 from FearlessTobi/keys-singleton
crypto: Make KeyManager a singleton class
2020-07-01 14:16:26 +10:00
bunnei 7a7942741f Merge pull request #4153 from ogniK5377/prepo-multibuf
prepo: : Don't read extra buffer from report unless passed
2020-06-30 22:37:13 -04:00
bunnei a23a2102e8 Merge pull request #4063 from FreddyFunk/game-version-in-title
Add game version to window title
2020-06-30 21:42:33 -04:00
bunnei 660954c6de Merge pull request #4166 from VolcaEM/quickstart-faq
Add "Open Quickstart Guide" and "FAQ" buttons to the Help menu
2020-06-30 19:03:47 -04:00
Jan Beich f3c5dda382 common: switch to nullptr for sysctl's empty new value 2020-06-30 23:00:18 +00:00
Ameer 0c6128cc3a Address feedback regarding increments, const vars, and general cleanup 2020-06-30 17:28:02 -04:00
Fernando Sahmkow ba11aa4c74 Merge pull request #4176 from ReinUsesLisp/compatible-formats
texture_cache: Check format compatibility before copying
2020-06-30 15:36:13 -04:00
Fernando Sahmkow 1e93bc33c0 Merge pull request #4157 from ReinUsesLisp/unified-turing
gl_device: Enable NV_vertex_buffer_unified_memory on Turing devices
2020-06-30 14:36:51 -04:00
Ameer ed72085227 fix implicit conversion of size_t type to int 2020-06-30 11:44:55 -04:00
Morph 9e0fd0beb0 maxwell_to_gl: Implement MirrorOnceClampOGL using GL_MIRROR_CLAMP_EXT
Like MirrorOnceBorder, this requires the GL_EXT_texture_mirror_clamp extension. This extension is unfortunately not available on Intel's drivers (both Windows proprietary and Linux Mesa). Use GL_MIRROR_CLAMP_TO_EDGE as a fallback if the extension is unavailable.
2020-06-30 02:40:14 -04:00
Rodrigo Locatti c78f246ebf Merge pull request #4191 from Morph1984/vertex-formats
maxwell_to_gl/vk: Reorder vertex formats
2020-06-30 03:30:00 -03:00
David ac1a57c28a macro: Add support for "middle methods" on the code cache (#4112)
Macro code is just uploaded sequentially from a starting address, however that does not mean the entry point for the macro is at that address. This PR adds preliminary support for executing macros in the middle of our cached code.
2020-06-30 02:32:24 -03:00
bunnei a21d49c9fe Merge pull request #4182 from Kewlan/fullscreen-hotkey-fix
hotkeys: Fix issues caused when changing the fullscreen hotkey
2020-06-29 23:11:57 -04:00
Jan Beich 3c13a49cbf common: add sysconf() fallback
src/common/memory_detect.cpp:15:10: fatal error: 'sys/sysinfo.h' file not found
 #include <sys/sysinfo.h>
          ^~~~~~~~~~~~~~~
2020-06-29 22:41:22 +00:00
Morph e2fb93cb46 maxwell_to_gl: Rename VertexType() to VertexFormat() 2020-06-29 11:48:38 -04:00
John Galt 1eacbe69be cmake: fix fmt linking
On gcc/ld, and clang/lld, fmt::v6 symbols are excluded, so linking
fails. This fixes the issue.

Note: This was included in the FindBoost changes I shared with
BlinkHawk, however only they were merged. I'm not sure if it was missed,
or if there was an issue with this part of the change.
2020-06-29 07:10:07 -04:00
Rodrigo Locatti 1711fe29f2 Merge pull request #4140 from ReinUsesLisp/validation-layers
renderer_vulkan: Update validation layer name and test before enabling
2020-06-29 02:12:38 -03:00
VolcaEM 33f6610f52 Remove duplicate functions 2020-06-29 04:22:38 +02:00
VolcaEM cd893f7ac4 Use decimal instead of hexadecimal
Co-authored-by: David <25727384+ogniK5377@users.noreply.github.com>
2020-06-29 04:21:10 +02:00
VolcaEM 6d7c850936 Fix typo 2020-06-29 04:12:36 +02:00
VolcaEM a82dc6c91d Clang-format 2020-06-29 04:09:38 +02:00
VolcaEM 9338a6a1cf service: Update function tables 2020-06-29 04:01:34 +02:00
ReinUsesLisp a0226819e1 core_timing,scheduler: Use std::scoped_lock when possible
Simplifies the cognitive load of procedures using locks and makes locks
safe against exceptions.
2020-06-28 21:42:57 -03:00
bunnei 58f337e105 Merge pull request #3955 from FernandoS27/prometheus-2b
Remake Kernel Scheduling, CPU Management & Boot Management (Prometheus)
2020-06-28 12:37:50 -04:00
David Marcec 3804c6d1c0 ldr: Cleanup NRO & NRR structs 2020-06-28 20:54:37 +10:00
David 1989977382 Merge pull request #4026 from VolcaEM/ldr
ldr: Update NRR/NRO structs
2020-06-28 20:46:42 +10:00
David 33e9b11261 Merge pull request #4184 from VolcaEM/patch-9
grc: Update function table
2020-06-28 18:49:15 +10:00
David 475c9a1e3c Merge pull request #4185 from VolcaEM/patch-10
lbl: Update function table
2020-06-28 18:48:54 +10:00
David a6374c177a Merge pull request #4186 from VolcaEM/patch-11
ldn: Update function table
2020-06-28 18:48:28 +10:00
David 7b1dba2f84 Merge pull request #4187 from VolcaEM/patch-12
mig: Update function table
2020-06-28 18:48:15 +10:00
David 3d5f77c3cf Merge pull request #4188 from VolcaEM/patch-13
mm: Update function table
2020-06-28 18:47:55 +10:00
David 4abb01de75 Merge pull request #4189 from VolcaEM/patch-14
ncm: Update function table
2020-06-28 18:47:27 +10:00
David 9b9504bb8d Merge pull request #4190 from VolcaEM/patch-15
nfc: Update function table
2020-06-28 18:47:07 +10:00
David 48090dcdba Merge pull request #4183 from VolcaEM/patch-8
friend: Update function table
2020-06-28 18:46:40 +10:00
Morph 3a3949183e maxwell_to_vk: Reorder vertex formats and add A2B10G10R10 for all types except float 2020-06-28 02:57:10 -04:00
David Marcec 2864b1fb41 am: Stub GetIndirectLayerConsumerHandle
Needed by Monster Hunter Generations Ultimate
2020-06-28 16:51:28 +10:00
Morph 4c3146aeb4 maxwell_to_gl: Add 32 bit component sizes to (un)signed scaled formats
Add 32 bit component sizes to (un)signed scaled formats and group (un)signed normalized, scaled, and integer formats together.
2020-06-28 02:51:13 -04:00
David Marcec bbf7b72fbf acc: ListOpenContextStoredUsers partial stub
Needed by Baldur's Gate 1/2
2020-06-28 16:44:36 +10:00
Fernando Sahmkow 94a51e6b21 Core/Common: Address Feedback. 2020-06-27 18:20:06 -04:00
Fernando Sahmkow 7818e2ee11 NvFlinger: Clang Format. 2020-06-27 11:36:30 -04:00
Fernando Sahmkow 8ef375e772 Build System: Fix GCC & MINGW Build. 2020-06-27 11:36:28 -04:00
Fernando Sahmkow 8cd81eb66f SVC: Implement 32-bits wrappers and update Dynarmic. 2020-06-27 11:36:27 -04:00
Fernando Sahmkow 146bbc6189 SVC: Add GetCurrentProcessorNumber32, CreateTransferMemory32, SetMemoryAttribute32 2020-06-27 11:36:27 -04:00
Fernando Sahmkow fd631d72a6 ARM: Update Dynarmic and Setup A32 according to latest interface. 2020-06-27 11:36:26 -04:00
Fernando Sahmkow 75db328166 SVC: Add GetThreadPriority32 & SetThreadPriority32 2020-06-27 11:36:25 -04:00
Fernando Sahmkow a7be2fac83 ArmDynarmic32: Setup CNTPCT correctly 2020-06-27 11:36:24 -04:00
Fernando Sahmkow 78a23536d4 Audio: Correct buffer release for host timing. 2020-06-27 11:36:23 -04:00
Fernando Sahmkow 24e0d393e2 Common/Kernel: Corrections and small bug fixing. 2020-06-27 11:36:21 -04:00
Fernando Sahmkow fda5651072 Services/NvFlinger: Do vSync in a sepparate thread on Multicore. 2020-06-27 11:36:20 -04:00
Fernando Sahmkow 74c9ad1976 Common/NativeClockx86: Reduce native clock accuracy further. 2020-06-27 11:36:18 -04:00
Fernando Sahmkow 4df46e0525 Tests/CoreTiming: Correct host timing tests. 2020-06-27 11:36:17 -04:00
Fernando Sahmkow af0999c735 ARMDynarmicInterface: Correct GCC Build Errors. 2020-06-27 11:36:17 -04:00
Fernando Sahmkow e8d2bf1e17 Common/AtomicOps: Correct GCC Intrinsic argument ordering. 2020-06-27 11:36:16 -04:00
Fernando Sahmkow 555c4c238c Kernel: Correct Host Context on Threads and Scheduler. 2020-06-27 11:36:15 -04:00
Fernando Sahmkow 8d603539a4 YuzuQT: Hide Speed UI on Multicore. 2020-06-27 11:36:14 -04:00
Fernando Sahmkow adc86e3030 Clang Format. 2020-06-27 11:36:14 -04:00
Fernando Sahmkow 6cbdb64f3d ARMInterface/Externals: Update dynarmic and fit to latest version. 2020-06-27 11:36:13 -04:00
Fernando Sahmkow cce90e2672 ARMInterface: Correct rebase errors. 2020-06-27 11:36:12 -04:00
Fernando Sahmkow a4e7d0b106 CoreTiming: Correct rebase bugs and other miscellaneous things. 2020-06-27 11:36:11 -04:00
Fernando Sahmkow d98995c001 Core: Split Microprofile Dynarmic timing per Core 2020-06-27 11:36:10 -04:00
Fernando Sahmkow fb07639438 General: Tune the priority of main emulation threads so they have higher priority than less important helper threads. 2020-06-27 11:36:09 -04:00
Fernando Sahmkow b5f7040175 Dynarmic Interface: don't clear cache if JIT has not been created. 2020-06-27 11:36:08 -04:00
Fernando Sahmkow 543b6b315f General: Correct rebase, sync gpu and context management. 2020-06-27 11:36:08 -04:00
Fernando Sahmkow afb6d31c02 CoreTiming/CycleTimer: Correct Idling. 2020-06-27 11:36:07 -04:00
Fernando Sahmkow 9f7adff3d3 SingleCore: Correct ticks reset to be on preemption. 2020-06-27 11:36:06 -04:00
Fernando Sahmkow 6f0c873d48 General: Cleanup legacy code. 2020-06-27 11:36:05 -04:00
Fernando Sahmkow e95444c05a Kernel/svcBreak: Implement CacheInvalidation for Singlecore and correct svcBreak. 2020-06-27 11:36:04 -04:00
Fernando Sahmkow 1146679de6 Bootmanager/CPU_Manager: Correct shader caches and sync GPU on OpenGL. 2020-06-27 11:36:03 -04:00
Fernando Sahmkow b2109333c6 HLE_IPC: Correct HLE Event behavior on timeout. 2020-06-27 11:36:03 -04:00
Fernando Sahmkow 4132ba96da SingleCore: Improve Cycle timing Behavior and replace mutex in global scheduler for spinlock. 2020-06-27 11:36:02 -04:00
Fernando Sahmkow 3197d72996 FrameLimiting: Enable frame limiting for single core. 2020-06-27 11:36:01 -04:00
Fernando Sahmkow f0f2fc4243 SingleCore: Use Cycle Timing instead of Host Timing. 2020-06-27 11:36:01 -04:00
Fernando Sahmkow 21235cdab1 Scheduler: Correct Reload/Unload 2020-06-27 11:35:59 -04:00
Fernando Sahmkow 720858ba13 Thread: Release the ARM Interface on exitting. 2020-06-27 11:35:58 -04:00
Fernando Sahmkow db60ca2704 General: Move ARM_Interface into Threads. 2020-06-27 11:35:58 -04:00
Fernando Sahmkow 7b3b33a2e6 Core: Refactor ARM Interface. 2020-06-27 11:35:56 -04:00
Fernando Sahmkow 1cc7c426df X64 Clock: Reduce accuracy to be less or equal to guest accuracy. 2020-06-27 11:35:55 -04:00
Fernando Sahmkow c22d3e1e18 ARM/WaitTree: Better track the CallStack for each thread. 2020-06-27 11:35:54 -04:00
Fernando Sahmkow 96c996b6a0 SVC/ARM: Correct svcSendSyncRequest and cache ticks on arm interface. 2020-06-27 11:35:53 -04:00
Fernando Sahmkow 287ea2d3b4 SingleCore: Move Host Timing from a sepparate thread to main cpu thread. 2020-06-27 11:35:52 -04:00
Fernando Sahmkow 1bcceea736 GUI: Make multicore only work with Async and add GUI for multicore. 2020-06-27 11:35:52 -04:00
Fernando Sahmkow fc47857c3b ARM: Addapt to new Exclusive Monitor Interface. 2020-06-27 11:35:50 -04:00
Fernando Sahmkow 5f8acb6397 CPU_Manager: Correct stopping on SingleCore. 2020-06-27 11:35:49 -04:00
Fernando Sahmkow d03d00c9c2 Scheduler: Correct yielding interaction with SetThreadActivity. 2020-06-27 11:35:49 -04:00
Fernando Sahmkow b121009e03 General: Fix microprofile on dynarmic/svc, fix wait tree showing which threads were running. 2020-06-27 11:35:48 -04:00
Fernando Sahmkow cb974be3ce General: Fix Stop function 2020-06-27 11:35:47 -04:00
Fernando Sahmkow 3869e55c27 Kernel: Rewind on SVC change. 2020-06-27 11:35:46 -04:00
Fernando Sahmkow 0963ff1ae9 Kernel: Preempt Single core on redudant yields. 2020-06-27 11:35:45 -04:00
Fernando Sahmkow ebb640e968 CPU_Manager: Unload/Reload threads on preemption on SingleCore 2020-06-27 11:35:43 -04:00
Fernando Sahmkow d2aa227e0d Synchronization: Correct wide Assertion. 2020-06-27 11:35:43 -04:00
Fernando Sahmkow cc2f7dcd08 General: Initial Setup for Single Core. 2020-06-27 11:35:42 -04:00
Fernando Sahmkow 65225cf61b Scheduler: Set last running time on thread. 2020-06-27 11:35:41 -04:00
Fernando Sahmkow 76daf8f672 Kernel: Corrections to TimeManager, Scheduler and Mutex. 2020-06-27 11:35:40 -04:00
Fernando Sahmkow 24bc1f020a Kernel: Fixes, corrections and asserts to scheduler and different svcs. 2020-06-27 11:35:40 -04:00
Fernando Sahmkow 5183094c24 Scheduler: Correct yields. 2020-06-27 11:35:39 -04:00
Fernando Sahmkow d9a0ea22bf Mutex: Revert workaround due to poor exclusive memory. 2020-06-27 11:35:38 -04:00
Fernando Sahmkow 5eac520ae3 ARM/Memory: Correct Exclusive Monitor and Implement Exclusive Memory Writes. 2020-06-27 11:35:37 -04:00
Fernando Sahmkow d2a2c5f57b SVC: WaitSynchronization add Termination Pending Result. 2020-06-27 11:35:36 -04:00
Fernando Sahmkow a9ed059a07 Scheduler: Remove arm_interface lock and a few corrections. 2020-06-27 11:35:35 -04:00
Fernando Sahmkow 119d9844db Yuzu/Debuggers: Correct Wait Tree for Paused threads. 2020-06-27 11:35:34 -04:00
Fernando Sahmkow 87117805c9 SVC: Correct SetThreadActivity. 2020-06-27 11:35:33 -04:00
Fernando Sahmkow c1f6b99653 SCC: Small corrections to CancelSynchronization 2020-06-27 11:35:33 -04:00
Fernando Sahmkow e5454c3665 Scheduler: Correct locking for hle threads. 2020-06-27 11:35:32 -04:00
Fernando Sahmkow 723a909ee9 Scheduler: Fix HLE Threads on guard 2020-06-27 11:35:31 -04:00
Fernando Sahmkow b80f252d11 Scheduler: Protect on closed threads. 2020-06-27 11:35:31 -04:00
Fernando Sahmkow e501cbe5b8 Scheduler: Correct assert. 2020-06-27 11:35:30 -04:00
Fernando Sahmkow c8e62451c6 Core: Correct rebase. 2020-06-27 11:35:29 -04:00
Fernando Sahmkow 8c30c20863 Scheduler: Release old thread fiber before trying to switch to the next thread fiber. 2020-06-27 11:35:28 -04:00
Fernando Sahmkow 7ad6af4bdb NVDRV: Remove frame limiting as Host Timing already takes care. 2020-06-27 11:35:28 -04:00
Fernando Sahmkow 4621b4b37a Mutex: Correct Result writting to clear exclusivity. 2020-06-27 11:35:26 -04:00
Fernando Sahmkow 7270076127 SVC: Correct svcWaitForAddress and svcSignalToAddress. 2020-06-27 11:35:25 -04:00
Fernando Sahmkow a3f7acb149 Scheduler: Correct Select Threads Step 2. 2020-06-27 11:35:24 -04:00
Fernando Sahmkow 47c01e68da Kernel: Corrections to Scheduling. 2020-06-27 11:35:23 -04:00
Fernando Sahmkow 5e26654c5a Kernel: Correct Signal on Thread Death and Setup Sync Objects on Thread for Debugging 2020-06-27 11:35:23 -04:00
Fernando Sahmkow da260b9d2e Core: Correct HLE Event Callbacks and other issues. 2020-06-27 11:35:22 -04:00
Fernando Sahmkow 04cb816f7a Process: Protect TLS region and Modules. 2020-06-27 11:35:21 -04:00
Fernando Sahmkow cd3d1798d8 General: Add Asserts 2020-06-27 11:35:21 -04:00
Fernando Sahmkow 78eeea9f17 General: Add better safety for JIT use. 2020-06-27 11:35:20 -04:00
Fernando Sahmkow 7932cf9617 SVC: Correct races on physical core switching. 2020-06-27 11:35:19 -04:00
Fernando Sahmkow 2c0431e5ed NVFlinger: Lock race condition between CPU, Host Timing, VSync. 2020-06-27 11:35:18 -04:00
Fernando Sahmkow 9140f5d1f3 SVC: Add locks to the memory management. 2020-06-27 11:35:18 -04:00
Fernando Sahmkow 6605f8acfa SVC: Correct WaitSynchronization, WaitProcessWideKey, SignalProcessWideKey. 2020-06-27 11:35:17 -04:00
Fernando Sahmkow 940422fd96 SVC: Cleanup old methods. 2020-06-27 11:35:16 -04:00
Fernando Sahmkow 64fe82af2e CPU_Manager: Reconfigre guest threads for dynamrmic downsides 2020-06-27 11:35:15 -04:00
Fernando Sahmkow 85ca7b2bdb SVC: Correct SendSyncRequest. 2020-06-27 11:35:14 -04:00
Fernando Sahmkow 5c70bfcef7 SVC: Correct ArbitrateUnlock 2020-06-27 11:35:14 -04:00
Fernando Sahmkow 8c9d258e66 SVC: Correct SignalEvent, ClearEvent, ResetSignal, WaitSynchronization, CancelSynchronization, ArbitrateLock 2020-06-27 11:35:13 -04:00
Fernando Sahmkow 71e008a336 SVC: Remove global HLE Lock. 2020-06-27 11:35:13 -04:00
Fernando Sahmkow b2fea85499 SVC: Correct GetThreadPriority, SetThreadPriority, GetThreadCoreMask, SetThreadCoreMask, GetCurrentProcessorNumber 2020-06-27 11:35:12 -04:00
Fernando Sahmkow 451344e9ae SVC: Correct CreateThread, StartThread, ExitThread, SleepThread. 2020-06-27 11:35:11 -04:00
Fernando Sahmkow fb1d75a788 HostTiming: Pause the hardware clock on pause. 2020-06-27 11:35:10 -04:00
Fernando Sahmkow 0fd333a248 AudioCore: Use nanoseconds instead of cycles for buffer time. 2020-06-27 11:35:10 -04:00
Fernando Sahmkow 9846f5822d General: Setup yuzu threads' microprofile, naming and registry. 2020-06-27 11:35:09 -04:00
Fernando Sahmkow 63bd59669f CPU_Manager: remove debugging code. 2020-06-27 11:35:08 -04:00
Fernando Sahmkow 71cb697314 YuzuCMD/Tester: Correct execution 2020-06-27 11:35:07 -04:00
Fernando Sahmkow 7ee76003ad General: Recover Prometheus project from harddrive failure
This commit: Implements CPU Interrupts, Replaces Cycle Timing for Host 
Timing, Reworks the Kernel's Scheduler, Introduce Idle State and 
Suspended State, Recreates the bootmanager, Initializes Multicore 
system.
2020-06-27 11:35:06 -04:00
David a83f0b607e Merge pull request #3396 from FernandoS27/prometheus-1
Implement SpinLocks, Fibers and a Host Timer
2020-06-28 01:34:07 +10:00
VolcaEM a1e5cfa4b6 nfc: Update function table
This was based on Switchbrew page: https://switchbrew.org/wiki/NFC_services
2020-06-27 13:09:36 +02:00
VolcaEM c696867643 ncm: Update function table
This was based on Switchbrew page: https://switchbrew.org/wiki/NCM_services

ILocationResolver's 16, 17, 18 and 19 have unofficial names
2020-06-27 13:05:22 +02:00
VolcaEM d75e36dca8 mm: Update function table
This was based on Switchbrew page: https://switchbrew.org/wiki/Display_services
2020-06-27 12:59:01 +02:00
VolcaEM 1df981bf33 mig: Update function table
This was based on Switchbrew page: https://switchbrew.org/wiki/Migration_services
2020-06-27 12:53:59 +02:00
VolcaEM 66442ce8fd ldn: Update function table
This was based on Switchbrew page: https://switchbrew.org/wiki/LDN_services
2020-06-27 12:50:56 +02:00
VolcaEM 87f8989359 Oops (fix typo) 2020-06-27 12:45:42 +02:00
VolcaEM 9a04fa1cf8 lbl: Update function table
This was based on Switchbrew page: https://switchbrew.org/wiki/Backlight_services
2020-06-27 12:43:33 +02:00
VolcaEM 26855d7906 grc: Update function table
This was based on Switchbrew page: https://switchbrew.org/wiki/GRC_services
2020-06-27 12:41:21 +02:00
VolcaEM ee12f6f61e friend: Update function table 2020-06-27 12:39:10 +02:00
Kewlan eac502f442 Fix issues caused when changing the fullscreen hotkey 2020-06-27 11:30:32 +02:00
bunnei d3c8f5d4c8 Merge pull request #4097 from kevinxucs/kevinxucs/device-pixel-scaling-float
Fix framebuffer size on fractional scaling display
2020-06-27 02:49:07 -04:00
bunnei 286418bf01 Merge pull request #4164 from Kewlan/mute-audio-hotkey
hotkeys: Add a "Mute Audio" hotkey
2020-06-27 02:47:13 -04:00
bunnei c5f5483ee1 Merge pull request #4158 from Morph1984/caps
caps: Use enum classes and check struct sizes on compile time
2020-06-27 00:09:32 -04:00
Ameer J 21ae845d69 left const auto&, comment punctuation.
Co-authored-by: Morph <39850852+Morph1984@users.noreply.github.com>
2020-06-26 23:46:49 -04:00
bunnei c9acff2600 Merge pull request #4152 from ogniK5377/ipc-err
Mark invalid IPC buffers as ASSERT_OR_EXECUTE_MSG
2020-06-26 23:37:19 -04:00
bunnei 615e5630bf Merge pull request #4154 from ogniK5377/swkbd-nullptr
Prevent nullptr dereference on swkbd error case
2020-06-26 23:25:04 -04:00
bunnei 7048f18d87 Merge pull request #4147 from ReinUsesLisp/hset2-imm
shader/half_set: Implement HSET2_IMM
2020-06-26 23:14:56 -04:00
David f546eac9f3 Merge pull request #4178 from VolcaEM/patch-6
es: Update function table
2020-06-27 13:05:12 +10:00
VolcaEM 92f8bc1bf8 Use better names for "Unknown"s 2020-06-27 02:48:29 +02:00
VolcaEM 70e34fdba0 Update function names 2020-06-27 02:43:22 +02:00
David Marcec b412e8b952 btm: Give better names for unknown functions 2020-06-27 10:42:46 +10:00
VolcaEM 4cf402a109 btdrv: Update function table (#4174)
* btdrv: Update function table
2020-06-26 20:34:29 -04:00
VolcaEM 29e3f101d9 bpc: Update function tables (#4173)
* bpc: Update function tables

This was based on Switchbrew page: https://switchbrew.org/wiki/PCV_services
2020-06-26 20:33:55 -04:00
VolcaEM 866f06f078 bcat: Update function tables and add missing classes (#4172)
* bcat: Update function tables and add missing classes
2020-06-26 20:33:25 -04:00
VolcaEM 690e4b86ae am: Update function tables and add missing classes (#4169)
* am: Update function tables and add missing classes

* Remove comments (1/5)

* Remove comments (2/5)

* Remove comments (3/5)

* Remove comments (4/5)

* Remove comments (5/5)

* Remove unused classes (1/2)

* Remove unused classes (2/2)
2020-06-26 20:32:26 -04:00
VolcaEM 9052b62380 aoc: Update function table (#4170)
* aoc: Update function table

* Remove comments
2020-06-26 20:31:44 -04:00
LC 1b10d314f4 Merge pull request #4177 from VolcaEM/patch-5
btm: Update function tables
2020-06-26 20:30:59 -04:00
VolcaEM 4aa69a35d9 eupld: Update function table
This was based on Switchbrew page: https://switchbrew.org/wiki/Error_Upload_services
2020-06-27 02:25:04 +02:00
VolcaEM 1824af3f63 es: Update function table
This was based on Switchbrew page: https://switchbrew.org/wiki/ETicket_services
2020-06-27 02:17:51 +02:00
VolcaEM c6e7f72cb1 Update FAQ function name (2/2) 2020-06-27 02:14:29 +02:00
VolcaEM 873e6fc739 Update FAQ function name (1/2) 2020-06-27 02:13:34 +02:00
VolcaEM aa2672fb2c btm: Update function tables
This was based on Switchbrew page: https://switchbrew.org/wiki/BTM_services

"No comment" edition
2020-06-27 01:57:48 +02:00
ReinUsesLisp eab8a5a9db vk_rasterizer: Use nullptr for <pSizes> in CmdBindVertexBuffers2EXT
Disable this temporarily.
2020-06-26 20:57:22 -03:00
ReinUsesLisp b9ac739607 vk_pipeline_cache: Avoid hashing and comparing dynamic state when possible
With extended dynamic states, some bytes don't have to be collected from
the pipeline key, hence we can avoid hashing and comparing them on
lookups.
2020-06-26 20:57:22 -03:00
ReinUsesLisp 031f7b3b26 vulkan/fixed_pipeline_state: Move state out of individual structures 2020-06-26 20:57:22 -03:00
ReinUsesLisp 049837aae0 vk_rasterizer: Use VK_EXT_extended_dynamic_state 2020-06-26 20:57:22 -03:00
ReinUsesLisp 0a32575e27 renderer_vulkan/wrapper: Add VK_EXT_extended_dynamic_state functions 2020-06-26 20:55:15 -03:00
ReinUsesLisp 8e8bfc9365 fixed_pipeline_state: Add requirements for VK_EXT_extended_dynamic_state
This moves dynamic state present in VK_EXT_extended_dynamic_state to a
separate structure in FixedPipelineState. This is structure is at the
bottom allowing us to hash and memcmp only when the extension is not
supported.
2020-06-26 20:55:15 -03:00
ReinUsesLisp bcf4665fb0 vk_device: Enable VK_EXT_extended_dynamic_state when available 2020-06-26 20:55:15 -03:00
ReinUsesLisp 26144f794f texture_cache: Test format compatibility before copying
Avoid illegal copies. This intercepts the last step of a copy to avoid
generating validation errors or corrupting the driver on some instances.

We can create views and emit copies accordingly in future commits and
remove this last-step validation.
2020-06-26 20:52:22 -03:00
bunnei 7fa55a24f2 Merge pull request #4144 from FernandoS27/tt-fix
TextureCache: Fix case where layer goes off bound.
2020-06-26 19:02:39 -04:00
bunnei 2a1df7b66e Merge pull request #4111 from ReinUsesLisp/preserve-contents-vk
vk_rasterizer: Don't preserve contents on full screen clears
2020-06-26 18:48:12 -04:00
ReinUsesLisp 23e0009a41 video_core/compatible_formats: Table to test if two formats are legal to view or copy
Add a flat table to test if it's legal to create a texture view between
two formats or copy betweem them.

This table is based on ARB_copy_image and ARB_texture_view. Copies are
more permissive than views.
2020-06-26 19:28:11 -03:00
ReinUsesLisp 95c7c7db0a gl_buffer_cache: Copy to buffers created as STREAM_READ before downloading
After marking buffers as resident, Nvidia's driver seems to take a
slow path. To workaround this issue, copy to a STREAM_READ buffer and
then call GetNamedBufferSubData on it.

This is a temporary solution until we have asynchronous flushing.
2020-06-26 16:58:40 -03:00
VolcaEM cfd829e6ac Update function name again 2020-06-26 18:51:12 +02:00
VolcaEM c50c165d3c Update function name (2/2) 2020-06-26 18:50:28 +02:00
VolcaEM 032cf4330e Update function name (1/2) 2020-06-26 18:49:57 +02:00
Fernando Sahmkow fda14542cb Common: Fix non-conan build 2020-06-26 12:25:19 -04:00
Morph d8df8d84ae caps_u: Fix GetAlbumContentsFileListForApplication stub 2020-06-26 08:35:21 -04:00
Morph 851a3a8638 caps: Use enum classes and check struct sizes on compile time 2020-06-26 08:35:21 -04:00
Morph 9b4a5f297b caps: Update copyright headers
Updated to "yuzu Emulator Project"
2020-06-26 08:35:21 -04:00
Kewlan 3fcf2f201c Add a "Mute Audio" hotkey 2020-06-26 06:03:29 +02:00
bunnei 257cf13b70 Merge pull request #4159 from ogniK5377/mem-manager-dumb-assert
memory_manager: Remove useless assertion
2020-06-25 22:53:13 -04:00
Rodrigo Locatti f7c871b8ca Merge pull request #4151 from ReinUsesLisp/gl-invalidations
gl_shader_cache: Avoid use after move for program size
2020-06-25 21:05:27 -03:00
Ameer J eb06e3e8bf const& to button in button array
Co-authored-by: VolcaEM <63682805+VolcaEM@users.noreply.github.com>
2020-06-25 19:46:50 -04:00
Ameer 677a07c253 Stop reading loop if error is encountered 2020-06-25 19:31:51 -04:00
VolcaEM 9d72389b35 Clang-format again 2020-06-25 23:44:41 +02:00
VolcaEM b16bfe629d Clang-format 2020-06-25 23:40:53 +02:00
VolcaEM f9233dc922 Remove unnecessary newline 2020-06-25 23:38:38 +02:00
VolcaEM 967cbf1f36 Merge branch 'master' into quickstart-faq 2020-06-25 23:34:37 +02:00
VolcaEM d0647a7ae9 Fix typo 2: electric boogaloo 2020-06-25 23:32:43 +02:00
VolcaEM c8d6e50b05 Use QUrl (2/2) 2020-06-25 23:31:01 +02:00
VolcaEM d82f550d12 Use QUrl (1/2) 2020-06-25 23:28:38 +02:00
VolcaEM 002d762b78 Fix formatting 2020-06-25 23:18:54 +02:00
VolcaEM 5590f4775e Fix typo 2020-06-25 23:07:58 +02:00
VolcaEM a6150263c9 Add "Open Quickstart Guide" and "FAQ" buttons to the Help menu
While we're at it, also refactor the function used by OnOpenModsPage to be compatible with other URLs
2020-06-25 23:02:33 +02:00
bunnei c5dfaa7e9a Merge pull request #4136 from VolcaEM/mods
Add a "Open Mods Page" button to the GUI
2020-06-25 15:10:18 -04:00
Rodrigo Locatti 9587c299f3 Merge pull request #4160 from ogniK5377/IsASTCSupported-fix
gl_device: Fix IsASTCSupported to scan all targets instead of just GL_TEXTURE_2D
2020-06-25 15:58:09 -03:00
David fbc30df353 Merge pull request #4141 from Morph1984/SevenSixAxisSensor
hid: Stub a series of "SevenSixAxisSensor" service commands
2020-06-25 19:37:39 +10:00
David Marcec 589135df53 gl_device: Fix IsASTCSupported
Other targets were never actually checked
2020-06-25 19:12:56 +10:00
David Marcec 442900456e memory_manager: Remove useless assertion
num_pages is an std::size_t. It will always be >= 0
2020-06-25 16:35:58 +10:00
ReinUsesLisp 9f411bbb41 gl_device: Enable NV_vertex_buffer_unified_memory on Turing devices
Once we make sure not to corrupt Nvidia's driver, we can safely use
resident buffers on Turing devices.

See GitHub pull request #4156
2020-06-25 01:28:47 -03:00
Morph 3e0ff59a63 hid: Stub a series of "SevenSixAxisSensor" service commands
- Used by Captain Toad: Treasure Tracker Update 1.3.0

While we're at it, fix the input parameters for SetIsPalmaAllConnectable and SetPalmaBoostMode
2020-06-24 11:57:39 -04:00
bunnei 889171282d Merge pull request #4105 from ReinUsesLisp/resident-buffers
gl_rasterizer: Use NV_vertex_buffer_unified_memory for vertex buffer robustness
2020-06-24 11:40:30 -04:00
Ameer 7c10c568da padbutton enum class and struct initiailization 2020-06-24 11:39:30 -04:00
bunnei 12a5f5af5d Merge pull request #4083 from Morph1984/B10G11R11F
decode/image: Implement B10G11R11F
2020-06-24 11:02:38 -04:00
David Marcec 4b9812e7bb Prevent nullptr dereference on swkbd error case 2020-06-25 00:25:15 +10:00
David Marcec bf4e6b3cba prepo: : Don't read extra buffer from report unless passed
Prepo doesn't always pass a secondary buffer, we assume it always does which leads to a bad read.
2020-06-24 23:01:00 +10:00
Fernando Sahmkow 0aa8c2d9e6 Merge pull request #4046 from ogniK5377/macro-hle-prod
Add support for HLEing Macros
2020-06-24 09:01:00 -04:00
David Marcec df001e73c2 Mark invalid IPC buffers as ASSERT_OR_EXECUTE_MSG
Previously if applications would send faulty buffers(example homebrew) it would lead to us returning uninitalized data. Switching from ASSERT_MSG to ASSERT_OR_EXECUTE_MSG allows us to have a fail safe to prevent crashes but also continue execution without introducing undefined behavior
2020-06-24 22:50:27 +10:00
ReinUsesLisp 3b1a5ead5c buffer_cache: Use buffer methods instead of cache virtual methods 2020-06-24 02:36:14 -03:00
ReinUsesLisp d636cb75f3 gl_stream_buffer: Use InvalidateBufferData instead unmap and map
Making the stream buffer resident increases GPU usage significantly on
some games. This seems to be addressed invalidating the stream buffer
with InvalidateBufferData instead of using a Unmap + Map (with
invalidation flags).
2020-06-24 02:36:14 -03:00
ReinUsesLisp aee540a7c9 gl_rasterizer: Use NV_vertex_buffer_unified_memory for vertex buffer robustness
Switch games are allowed to bind less data than what they use in a
vertex buffer, the expected behavior here is that these values are read
as zero. At the moment of writing this only D3D12, OpenGL and NVN through
NV_vertex_buffer_unified_memory support vertex buffer with a size limit.

In theory this could be emulated on Vulkan creating a new VkBuffer for
each (handle, offset, length) tuple and binding the expected data to it.
This is likely going to be slow and memory expensive when used on the
vertex buffer and we have to do it on all draws because we can't know
without analyzing indices when a game is going to read vertex data out
of bounds.

This is not a problem on OpenGL's BufferAddressRangeNV because it takes
a length parameter, unlike Vulkan's CmdBindVertexBuffers that only takes
buffers and offsets (the length is implicit in VkBuffer). It isn't a
problem on D3D12 either, because D3D12_VERTEX_BUFFER_VIEW on
IASetVertexBuffers takes SizeInBytes as a parameter (although I am not
familiar with robustness on D3D12).

Currently this only implements buffer ranges for vertex buffers,
although indices can also be affected. A KHR_robustness profile is not
created, but Nvidia's driver reads out of bound vertex data as zero
anyway, this might have to be changed in the future.

- Fixes SMO random triangles when capturing an enemy, getting hit, or
looking at the environment on certain maps.
2020-06-24 02:36:14 -03:00
ReinUsesLisp 0669209db6 gl_buffer_cache: Mark buffers as resident
Make stream buffer and cached buffers as resident and query their
address. This allows us to use GPU addresses for several proprietary
Nvidia extensions.
2020-06-24 02:36:14 -03:00
ReinUsesLisp 6a2fd26768 gl_device: Expose NV_vertex_buffer_unified_memory except on Turing
Expose NV_vertex_buffer_unified_memory when the driver supports it.

This commit adds a function the determine if a GL_RENDERER is a Turing
GPU. This is required because on Turing GPUs Nvidia's driver crashes
when the buffer is marked as resident or on DeleteBuffers. Without a
synchronous debug output (single threaded driver), it's likely that
the driver will crash in the first blocking call.
2020-06-24 02:36:14 -03:00
ReinUsesLisp 87a760f000 gl_stream_buffer: Always use a non-coherent buffer 2020-06-24 02:35:33 -03:00
ReinUsesLisp 5ddd3e5df0 gl_stream_buffer: Always use persistent memory maps
yuzu no longer supports platforms without persistent maps.
2020-06-24 02:35:33 -03:00
Rodrigo Locatti ba83472879 Merge pull request #4129 from Morph1984/texture-shadow-lod-workaround
gl_shader_decompiler: Workaround textureLod when GL_EXT_texture_shadow_lod is not available
2020-06-24 01:51:15 -03:00
David Marcec 1dee0b9436 Move GetKeyCodeMapImpl to an anonymous namespace 2020-06-24 13:05:08 +10:00
David Marcec 2ca26e7d61 addressed issues 2020-06-24 12:18:33 +10:00
David Marcec 55161a702b clear mme draw mode
We already draw, so we can clear it
2020-06-24 12:09:04 +10:00
David Marcec da2cbc76fc Addressed issues 2020-06-24 12:09:03 +10:00
David Marcec e5adcda905 Fix constbuffer for 0217920100488FF7 2020-06-24 12:09:02 +10:00
David Marcec 74e48d2a98 Macro HLE support 2020-06-24 12:09:01 +10:00
David Marcec 8ce11701a9 Fixed logging output 2020-06-24 12:07:41 +10:00
David Marcec 55b6b3cada Implement GetKeyCodeMap & GetKeyCodeMap2
Closes #3919
2020-06-24 12:05:52 +10:00
bunnei b465ef400e Merge pull request #4138 from Morph1984/GyroscopeZeroDriftMode
hid: Implement Get/ResetGyroscopeZeroDriftMode
2020-06-23 21:56:16 -04:00
ReinUsesLisp 0c086bfa66 gl_shader_cache: Avoid use after move for program size
All programs had a size of zero due to this bug, skipping invalidations.

While we are at it, remove some unused forward declarations.
2020-06-23 22:54:42 -03:00