Commit Graph

1549 Commits

Author SHA1 Message Date
Levi Behunin 9d5dc3c9b9 gpu_thread: Move to bounded queue 2022-06-02 19:37:46 -06:00
Liam 2ee161a0bf core/debugger: Implement new GDB stub debugger 2022-06-01 00:01:25 -04:00
bunnei e135944c4d Merge pull request #8374 from german77/asnycvibrations
input_common: Make vibration request async
2022-05-28 00:55:53 -07:00
lat9nq b73aaea0c1 path_util: Resolve `-Wpointer-bool-conversion` warning
Clang (rightfully) warns that we are checking for the existence of
pointer to something just allocated on the stack, which is always true.

Instead, check whether GetModuleFileNameW failed.

Co-authored-by: Mai M <mathew1800@gmail.com>
2022-05-26 19:01:26 -04:00
Narr the Reg 3cd7b067e0 input_common: Make vibration request async 2022-05-23 12:25:02 -05:00
lat9nq bef52745b1 string_util: Add U16StringFromBuffer
Qt's QString::toStdU16String doesn't work when compiling against the
latest libstdc++, at least when using Clang. This function effectively
does the same thing as the aforementioned one.
2022-05-15 18:06:33 -04:00
Fernando Sahmkow df5dd2fd82 VideoCore: Add option to dump the macros.
Co-Authored-By: liamwhite <liamwhite@users.noreply.github.com>
2022-05-08 21:37:34 -04:00
Mai M a533c4c26b Merge pull request #8280 from Tachi107/spdx-fixup
chore: add missing SPDX tags
2022-04-28 23:28:42 -04:00
Liam ee4d63cee5 GCC 12 fixes 2022-04-28 16:50:34 -04:00
Andrea Pappacoda b2eb103829 chore: add missing SPDX tags
Follow-up to 2b87305d31
2022-04-28 18:24:11 +02:00
Morph 2b87305d31 general: Convert source file copyright comments over to SPDX
This formats all copyright comments according to SPDX formatting guidelines.
Additionally, this resolves the remaining GPLv2 only licensed files by relicensing them to GPLv2.0-or-later.
2022-04-23 05:55:32 -04:00
german77 25c46f82c5 yuzu: Add custom ringcon configuration 2022-04-16 00:49:26 -05:00
bunnei e1b3368c18 hle: kernel: Use std::mutex instead of spin locks for most kernel locking. 2022-04-11 21:13:40 -07:00
Merry ae642bbff2 common: Replace lock_guard with scoped_lock 2022-04-07 19:30:55 +01:00
Fernando S 62d668fc79 Merge pull request #8143 from merryhime/rdtsc
native_clock: Use lfence with rdtsc
2022-04-07 16:17:45 +02:00
Liam d414904aef service: jit: stub JIT service 2022-04-06 20:07:01 -04:00
bunnei 18017f7adf Merge pull request #8089 from merryhime/paranoia
configuration: Add Paranoid CPU accuracy level
2022-04-04 11:07:38 -07:00
Merry 42d6a01039 native_clock: Internal linkage for FencedRDTSC
__forceinline required on MSVC for function to be inlined
2022-04-03 22:38:12 +01:00
merry b8d8677ed1 native_clock: Use lfence with rdtsc 2022-04-03 22:38:10 +01:00
merry 7470fdd77c native_clock: Use writeback from CAS to avoid double-loading 2022-04-02 22:22:48 +01:00
merry eeca2f2df9 atomic_ops: Implement AtomicCompareAndSwap with writeback 2022-04-02 22:22:48 +01:00
Merry 18ecb3053b native_clock: Use AtomicLoad128 2022-04-02 20:55:36 +01:00
Merry 14df27ff04 atomic_ops: Implement AtomicLoad128 2022-04-02 20:55:36 +01:00
merry e752529c4c configuration: Add Paranoid CPU accuracy level
Disables most optimizations for the paranoid.
2022-03-26 08:46:25 +00:00
bunnei 0b6b398bd4 hle: nvflinger: Merge Rect with Common::Rectangle. 2022-03-24 18:13:33 -07:00
bunnei e3ee327a30 common: logging: Add a logger for NVFlinger. 2022-03-24 18:13:32 -07:00
ameerj f9709bb9e9 general: Fix clang/gcc build errors 2022-03-20 02:25:09 -04:00
ameerj e70b4f3fc5 common: Reduce unused includes 2022-03-19 15:01:31 -04:00
ameerj 582332d13f common: Reduce unused includes 2022-03-19 02:23:33 -04:00
bunnei 492b983af4 common: tree: Various updates. 2022-03-14 18:14:53 -07:00
bunnei 3a7ac3cb72 common: intrusive_red_black_tree: Various updates. 2022-03-14 18:14:53 -07:00
Wunkolo c802f8fbd2 cpu_detect: Add additional x86 flags and telemetry
Adds detection of additional CPU flags to cpu_detect and additions to telemetry output.

This is not exhaustive but guided by features that [dynarmic utilizes](bcfe377aaa/src/dynarmic/backend/x64/host_feature.h (L12-L33)) as well as features that are currently utilized but not reported to telemetry(invariant_tsc). This is intended to guide future optimizations.

AVX512 in particular is broken up into its individual subsets and some other processor features such as [sha](https://en.wikipedia.org/wiki/Intel_SHA_extensions) and [gfni](https://en.wikipedia.org/wiki/AVX-512#GFNI) are added to have some forward-facing data-points.

What used to be a single `CPU_Extension_x64_AVX512` telemetry field
is also broken up into individual `CPU_Extension_x64_AVX512{F,VL,CD,...}` fields.
2022-03-11 10:27:00 -08:00
Wunkolo 21ccb35705 common/telemetry: Update `AddField` name type to `string_view`
Non-owning `string_view` is flexable and
avoids some of the many redundant copies made over `std::string`
2022-03-11 10:26:59 -08:00
Merry a993e93abd backend: Ensure backend_thread is destructed before message_queue
Ensures that stop_token signals that stop has been requested before destruction of conditional_variable
2022-03-10 10:49:15 +00:00
Wunkolo 7cb99ccf23 cpu_detect: Revert `__cpuid{ex}` array-type argument
Restores compatibility with MSVC's `__cpuid` intrinsic.
2022-03-09 19:50:01 -08:00
Wunkolo b603adb6ac cpu_detect: Add missing `lzcnt` detection 2022-03-09 13:57:47 -08:00
Wunkolo 4aa5b5779b cpu_detect: Refactor cpu/manufacturer identification
Set the zero-enum value to Unknown
Move the Manufacterer enum into the CPUCaps structure namespace
Add "ParseManufacturer" utility-function
Fix cpu/brand string buffer sizes(!)
2022-03-09 13:57:47 -08:00
Wunkolo 14618c0e98 cpu_detect: Update array-types to `span` and `array`
Update some uses of `int` into some more explicitly sized types as well
2022-03-09 13:57:47 -08:00
Wunkolo 609c64196b cpu_detect: Utilize `Bit<N>` utility function 2022-03-09 13:57:47 -08:00
Wunkolo 31f8d6f0cf cpu_detect: Compact capability fields
As this structure gets more explicit, bools can be bitfields and
small enums can use smaller types for their span of values.
2022-03-09 13:57:47 -08:00
Wunkolo fbf00e7fbc bit_util: Add `bit` utility function
Extracts a singular bit, as a bool, from the specified compile-time index.
2022-03-09 13:57:47 -08:00
Fernando S bc96f67ce1 Merge pull request #7973 from Morph1984/debug-crash
host_memory: Fix fastmem crashes in debug builds
2022-03-06 04:49:27 +01:00
bunnei 9d25f5409d Merge pull request #7935 from Wunkolo/logging-join-fix
logging: Convert `backend_thread` into an `std::jthread`
2022-03-02 19:09:26 -08:00
Morph 5ea520a149 host_memory: Fix fastmem crashes in debug builds
It is possible for virtual_offset to not be 0 when the iterator is at the beginning, and thus, std::prev(it) may be evaluated, leading to a crash in debug mode.

Co-Authored-By: Fernando S. <1731197+FernandoS27@users.noreply.github.com>
2022-03-02 18:36:59 -05:00
Wunkolo 8da42d8235 logging: Convert `backend_thread` into an `std::jthread`
Was getting an unhandled `invalid_argument` [exception](https://en.cppreference.com/w/cpp/thread/thread/join) during
shutdown on my linux machine. This removes the need for a `StopBackendThread` function entirely since `jthread`
[automatically handles both checking if the thread is joinable and stopping the token before attempting to join](https://en.cppreference.com/w/cpp/thread/jthread/~jthread) in the case that `StartBackendThread` was never called.
2022-02-27 16:23:52 -08:00
merry 3fe2c2d40d dynarmic: Inline exclusive memory accesses
Inlines implementation of exclusive instructions into JITted code,
improving performance of applications relying heavily on these
instructions.

We also fastmem these instructions for additional speed, with
support for appropriate recompilation on fastmem failure.

An unsafe optimization to disable the intercore global_monitor is also
provided, should one wish to rely solely on cmpxchg semantics for
safety.

See also: merryhime/dynarmic#664
2022-02-27 19:40:05 +00:00
bunnei 5dc4c92dc2 settings: Add a new "use_extended_memory_layout" setting.
- This will be used to enable emulation of a larger memory arrangement.
2022-02-21 13:07:19 -08:00
bunnei e1af26d5b3 fixup! core: hle: kernel: KPageTable: Improve Un/MapPhysicalMemory. 2022-02-19 00:14:27 -08:00
bunnei 6075031e99 core: hle: kernel: KPageTable: Improve Un/MapPhysicalMemory.
- Improves the implementations of MapPhysicalMemory and UnmapPhysicalMemory to more closely reflect latest HOS.
2022-02-18 23:42:27 -08:00
Wunkolo fe8b240a39 common: Add NullVisitor default constructor
Addresses https://github.com/yuzu-emu/yuzu/issues/7881 to fix linux
builds.

`YUZU_NON_COPYABLE` deletes the `T(const T&)` constructor which will
cause the implicitly defined default ctor/dtor to no-longer generate.
2022-02-17 06:28:19 -08:00