summaryrefslogtreecommitdiffstats
path: root/src/common/x64 (follow)
Commit message (Collapse)AuthorAgeFilesLines
* (wall, native)_clock: Rework NativeClockMorph2023-06-082-181/+40
|
* x64: Deduplicate RDTSC usageMorph2023-06-084-19/+80
|
* x64: Simplify RDTSC on non-MSVC compilersMorph2023-03-272-16/+10
| | | | Co-Authored-By: liamwhite <liamwhite@users.noreply.github.com>
* x64: Add MicroSleepMorph2023-03-272-0/+82
| | | | | | | MicroSleep allows the processor to pause for a "short" amount of time (in the microsecond range). This is useful for spin-waiting that does not require nanosecond precision. This uses the new TPAUSE instruction introduced on Intel's newest processors as part of the waitpkg instructions. For CPUs that do not support waitpkg instructions, this is equivalent to yield(). Co-Authored-By: liamwhite <liamwhite@users.noreply.github.com>
* x64: cpu_detect: Add detection of waitpkg instructionsMorph2023-03-272-0/+2
| | | | waitpkg introduces 3 instructions, UMONITOR, UMWAIT and TPAUSE.
* native_clock: Wait for 10 seconds instead of 30Morph2023-03-081-3/+3
| | | | It was experimentally determined to be sufficient.
* native_clock: Use RealTimeClock instead of SteadyClockMorph2023-03-081-4/+4
| | | | We want to synchronize RDTSC to real time.
* native_clock: Re-adjust the RDTSC frequencyMorph2023-03-082-5/+34
| | | | | The RDTSC frequency reported by CPUID is not accurate to its true frequency. We will spawn a separate thread to calculate the true RDTSC frequency after a measurement period of 30 seconds has elapsed.
* native_clock: Round RDTSC frequency to the nearest 1000Morph2023-03-051-5/+12
|
* Add CPU core count to log filesMatías Locatti2022-11-122-3/+60
|
* Revert Coretiming PRs 8531 and 7454 (#8591)Maide2022-07-281-1/+1
|
* chore: make yuzu REUSE compliantAndrea Pappacoda2022-07-272-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [REUSE] is a specification that aims at making file copyright information consistent, so that it can be both human and machine readable. It basically requires that all files have a header containing copyright and licensing information. When this isn't possible, like when dealing with binary assets, generated files or embedded third-party dependencies, it is permitted to insert copyright information in the `.reuse/dep5` file. Oh, and it also requires that all the licenses used in the project are present in the `LICENSES` folder, that's why the diff is so huge. This can be done automatically with `reuse download --all`. The `reuse` tool also contains a handy subcommand that analyzes the project and tells whether or not the project is (still) compliant, `reuse lint`. Following REUSE has a few advantages over the current approach: - Copyright information is easy to access for users / downstream - Files like `dist/license.md` do not need to exist anymore, as `.reuse/dep5` is used instead - `reuse lint` makes it easy to ensure that copyright information of files like binary assets / images is always accurate and up to date To add copyright information of files that didn't have it I looked up who committed what and when, for each file. As yuzu contributors do not have to sign a CLA or similar I couldn't assume that copyright ownership was of the "yuzu Emulator Project", so I used the name and/or email of the commit author instead. [REUSE]: https://reuse.software Follow-up to 01cf05bc75b1e47beb08937439f3ed9339e7b254
* guard against div-by-zeroMarshall Mohror2022-07-061-2/+5
|
* common/x64: Use TSC clock rate from CPUID when availableMarshall Mohror2022-07-062-0/+18
| | | | The current method used to estimate the TSC is fairly accurate - within a few kHz - but the exact value can be extracted from CPUID if available.
* Adress Feedback.Fernando Sahmkow2022-06-301-1/+0
|
* Native clock: Use atomic ops as before.Fernando Sahmkow2022-06-282-24/+29
|
* Native Clock: remove inaccuracy mask.Fernando Sahmkow2022-06-282-6/+1
|
* Core: Fix tests.Fernando Sahmkow2022-06-281-0/+1
|
* Common: improve native clock.Fernando Sahmkow2022-06-282-29/+24
|
* general: Convert source file copyright comments over to SPDXMorph2022-04-234-10/+10
| | | | | 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.
* native_clock: Internal linkage for FencedRDTSCMerry2022-04-031-2/+4
| | | | __forceinline required on MSVC for function to be inlined
* native_clock: Use lfence with rdtscmerry2022-04-031-14/+33
|
* native_clock: Use writeback from CAS to avoid double-loadingmerry2022-04-021-4/+6
|
* native_clock: Use AtomicLoad128Merry2022-04-021-2/+2
|
* common: Reduce unused includesameerj2022-03-193-5/+0
|
* cpu_detect: Add additional x86 flags and telemetryWunkolo2022-03-112-11/+40
| | | | | | | | | | | 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](https://github.com/merryhime/dynarmic/blob/bcfe377aaa5138af740e90af5be7a7dff7b62a52/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.
* cpu_detect: Revert `__cpuid{ex}` array-type argumentWunkolo2022-03-101-6/+6
| | | | Restores compatibility with MSVC's `__cpuid` intrinsic.
* cpu_detect: Add missing `lzcnt` detectionWunkolo2022-03-091-0/+1
|
* cpu_detect: Refactor cpu/manufacturer identificationWunkolo2022-03-092-24/+38
| | | | | | | 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(!)
* cpu_detect: Update array-types to `span` and `array`Wunkolo2022-03-091-11/+13
| | | | Update some uses of `int` into some more explicitly sized types as well
* cpu_detect: Utilize `Bit<N>` utility functionWunkolo2022-03-091-32/+20
|
* cpu_detect: Compact capability fieldsWunkolo2022-03-091-20/+21
| | | | | As this structure gets more explicit, bools can be bitfields and small enums can use smaller types for their span of values.
* common: wall_clock: Utilize constants for ms, us, and ns ratiosMorph2022-01-301-3/+3
|
* common/xbyak_api: Make BuildRegSet() constexprLioncash2022-01-261-8/+8
| | | | | This allows us to eliminate any static constructors that would have been emitted due to the function not being constexpr.
* common/cpu_detect: Remove CPU family and modelMorph2021-12-141-12/+0
| | | | We currently do not make use of these fields, remove them for now.
* native_clock: Wait for less time in EstimateRDTSCFrequencyMorph2021-12-041-18/+18
| | | | | In my testing, waiting for 200ms provided the same level of precision as the previous implementation when estimating the RDTSC frequency. This significantly improves the yuzu executable launch times since we reduced the wait time from 3 seconds to 200 milliseconds.
* general: Replace high_resolution_clock with steady_clockMorph2021-12-021-3/+3
| | | | On some OSes, high_resolution_clock is an alias to system_clock and is not monotonic in nature. Replace this with steady_clock.
* xbyak: Update include pathMerry2021-08-152-2/+2
|
* common: Merge uint128 to a single header file with inlines.bunnei2021-02-151-58/+0
|
* X86/NativeClock: Reimplement RTDSC access to be lock free.Fernando Sahmkow2021-01-022-22/+41
|
* X86/NativeClock: Improve performance of clock calculations on hot path.Fernando Sahmkow2021-01-022-5/+71
|
* xbyak_abi: Shorten std::size_t to size_tLioncash2020-12-051-8/+8
| | | | Makes for less reading.
* xbyak_abi: Avoid implicit sign conversionsLioncash2020-12-051-2/+2
|
* audio_core: Make shadowing and unused parameters errorsLioncash2020-12-032-5/+6
| | | | Moves the audio code closer to enabling warnings as errors in general.
* common: Enable warnings as errorsLioncash2020-11-021-1/+1
| | | | Cleans up common so that we can enable warnings as errors.
* common/wall_clock: Add virtual destructorsReinUsesLisp2020-09-301-1/+1
| | | | | | | | From -fsanitize=address, this code wasn't calling the proper destructor. Adding virtual destructors for each inherited class and the base class fixes this bug. While we are at it, mark the functions as final.
* externals: Update Xbyak to 5.96Lioncash2020-08-301-16/+16
| | | | | | | | | I made a request on the Xbyak issue tracker to allow some constructors to be constexpr in order to avoid static constructors from needing to execute for some of our register constants. This request was implemented, so this updates Xbyak so that we can make use of it.
* Core/Common: Address Feedback.Fernando Sahmkow2020-06-281-2/+2
|
* Common/NativeClockx86: Reduce native clock accuracy further.Fernando Sahmkow2020-06-271-1/+1
|
* X64 Clock: Reduce accuracy to be less or equal to guest accuracy.Fernando Sahmkow2020-06-272-1/+7
|
* HostTiming: Pause the hardware clock on pause.Fernando Sahmkow2020-06-272-0/+9
|
* Merge pull request #3396 from FernandoS27/prometheus-1David2020-06-274-0/+181
|\ | | | | Implement SpinLocks, Fibers and a Host Timer
| * Common: Refactor & Document Wall clock.Fernando Sahmkow2020-06-181-40/+7
| |
| * Common: Implement WallClock Interface and implement a native clock for x64Fernando Sahmkow2020-06-184-0/+214
| |
* | common/cpu_detect: Add AVX512 detectionMorph2020-06-202-0/+6
|/
* xbyak_abi: Prefer returning a struct to using out parameters in ABI_CalculateFrameSizeMerryMage2020-06-151-17/+19
|
* xbyak_abi: Register indexes should be unsignedMerryMage2020-06-151-11/+12
|
* xbyak_abi: Remove *GPS variants of stack manipulation functionsMerryMage2020-06-151-36/+0
|
* xbyak_abi: Fix ABI_PushRegistersAndAdjustStackMerryMage2020-06-151-6/+2
| | | | Pushing GPRs twice.
* Add xbyak externalDavid Marcec2020-05-302-0/+313
|
* Remove unused CPU Vendor string and telemtry fieldJames Rowe2020-01-182-99/+0
| | | | The information is duplicated in the brand string and the telemetry field is unused
* common: Remove dependency on xbyakLioncash2018-11-212-269/+0
| | | | | | | Xbyak is currently entirely unused. Rather than carting it along, remove it and get rid of a dependency. If it's ever needed in the future, then it can be re-added (and likely be more up to date at that point in time).
* Port #4182 from Citra: "Prefix all size_t with std::"fearlessTobi2018-09-152-10/+13
|
* common/xbyak_abi: Mark defined functions in header as inlineLioncash2018-08-151-7/+7
| | | | | Avoids potential One Definition Rule violations when these are used in the future.
* common/xbyak: Use nested namespace specifiers where applicableLioncash2018-08-152-8/+4
|
* common: Convert type traits templates over to variable template versions where applicableLioncash2018-08-081-1/+1
| | | | Uses the C++17 inline variable variants
* cpu_detect.cpp: Change comment from citra to yuzuN00byKing2018-03-261-1/+1
|
* Format: Run the new clang format on everythingJames Rowe2018-01-211-13/+56
|
* Common: Fix some out-of-style includesYuri Kunde Schlesner2017-05-281-1/+1
|
* common/cpu_detect: Add missing include and fix namespace scopeYuri Kunde Schlesner2017-03-131-5/+7
|
* Common/x64: remove legacy emitter and abi (#2504)Weiyi Wang2017-01-314-4197/+0
| | | These are not used any more since we moved shader JIT to xbyak.
* VideoCore: Convert x64 shader JIT to use Xbyak for assemblyYuri Kunde Schlesner2016-12-152-0/+227
|
* common: use system CPUID routine on DragonFly as wellJan Beich2016-10-281-2/+2
|
* common: some FreeBSD headers are incomplete to avoid namespace pollutionJan Beich2016-10-281-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | In file included from src/common/x64/cpu_detect.cpp:16: /usr/include/machine/cpufunc.h:66:17: error: unknown type name 'u_int' static __inline u_int ^ /usr/include/machine/cpufunc.h:67:6: error: unknown type name 'u_int' bsfl(u_int mask) ^ /usr/include/machine/cpufunc.h:69:2: error: unknown type name 'u_int' u_int result; ^ /usr/include/machine/cpufunc.h:75:17: error: unknown type name 'u_long'; did you mean 'long'? static __inline u_long ^ /usr/include/machine/cpufunc.h:76:6: error: unknown type name 'u_long'; did you mean 'long'? bsfq(u_long mask) ^ /usr/include/machine/cpufunc.h:78:2: error: use of undeclared identifier 'u_long'; did you mean 'long'? u_long result; ^ [...]
* Use negative priorities to avoid special-casing the self-includeYuri Kunde Schlesner2016-09-212-3/+3
|
* Remove empty newlines in #include blocks.Emmanuel Gil Peyrot2016-09-213-9/+4
| | | | | | | This makes clang-format useful on those. Also add a bunch of forgotten transitive includes, which otherwise prevented compilation.
* Manually tweak source formatting and then re-run clang-formatYuri Kunde Schlesner2016-09-192-5/+3
|
* Sources: Run clang-format on everything.Emmanuel Gil Peyrot2016-09-185-1354/+2093
|
* VideoCore: Run include-what-you-use and fix most includes.Emmanuel Gil Peyrot2016-04-301-0/+2
|
* emitter: Add CALL that can be fixed up.bunnei2016-04-142-0/+13
|
* emitter: Support arbitrary FixupBranch targets.bunnei2016-04-142-0/+17
|
* emitter: templatize ImmPtrLioncash2016-03-091-2/+6
|
* emitter: constexpr-ify helper functionsLioncash2016-03-091-19/+17
|
* emitter: Get rid of CanDoOpWithLioncash2016-03-091-7/+0
| | | | | This was removed in Dolphin as there were no particular uses for it. I'm sure the same will apply to citra.
* emitter: constexpr-ify OpArgLioncash2016-03-091-30/+30
|
* emitter: friend class OpArg with XEmitterLioncash2016-03-091-3/+4
|
* emitter: Remove unimplemented prototypeLioncash2016-03-091-1/+0
|
* x64 Emitter: Fix L bit in VEX prefixMerryMage2016-02-271-2/+2
|
* x64: Proper stack alignment in shader JIT function callsaroulin2015-09-013-424/+90
| | | | | Import Dolphin stack handling and register saving routines Also removes the x86 parts from abi files
* x64-emitter: add RCPSS SSE instructionaroulin2015-08-232-0/+2
|
* emitter: Remove pointer castsLioncash2015-08-212-4/+27
| | | | This should also technically silence quite a few ubsan warnings.
* emitter: Remove unnecessary definesLioncash2015-08-201-5/+1
|
* emitter: Remove unnecessary else keywordsLioncash2015-08-201-7/+7
|
* emitter: Remove unused codeLioncash2015-08-202-44/+0
|
* emitter: Remove unimplemented JMP prototypeLioncash2015-08-201-1/+0
|
* emitter: Pass OpArg by reference where possibleLioncash2015-08-202-763/+763
|
* emitter: Remove unnecessary inline specifiersLioncash2015-08-201-33/+33
| | | | Functions implemented in a class definition are already implicitly inline.
* Rename ARCHITECTURE_X64 definition to ARCHITECTURE_x86_64.bunnei2015-08-164-7/+7
|
* Common: Cleanup CPU capability detection code.bunnei2015-08-164-198/+141
|
* Common: Move cpu_detect to x64 directory.bunnei2015-08-163-1/+311
|
* x64: Refactor to remove fake interfaces and general cleanups.bunnei2015-08-164-0/+3814