Morph
e1bce50d8b
core_timing: Make use of MicroSleep for x64 CPUs
For CPUs that support tpause, this should result in significant CPU power savings over thread yield in this spin wait.
3 years ago
Morph
3053a62375
core: Promote CPU/GPU threads to time critical
And also demote Audren and CoreTiming to High thread priority.
3 years ago
Morph
bff1453282
core_timing: Use higher precision sleeps on Windows
The precision of sleep_for and wait_for is limited to 1-1.5ms on Windows.
Using SleepForOneTick() allows us to sleep for exactly one interval of the current timer resolution.
This allows us to take advantage of systems that have a timer resolution of 0.5ms to reduce CPU overhead in the event loop.
3 years ago
arades79
683019878f
remove static from pointer sized or smaller types for aesthetics, change constexpr static to static constexpr for consistency
Signed-off-by: arades79 <scravers@protonmail.com>
3 years ago
arades79
45e13b03f3
add static lifetime to constexpr values to force compile time evaluation where possible
Signed-off-by: arades79 <scravers@protonmail.com>
3 years ago
Liam
0953cdd271
timing: wait for completion on unregister
3 years ago
bunnei
638fa6170a
core: core_timing: Re-initialize if single/multicore state changes.
4 years ago
bunnei
a4d11f4427
core: Partially persist emulation state across game boots.
4 years ago
Liam
9632434243
core_timing: use high-precision sleeps on non-Windows targets
4 years ago
Liam
35d3e7db2a
common: remove "yuzu:" prefix from thread names
4 years ago
Kelebek1
e93e898df5
Remove pause callbacks from coretiming
4 years ago
Morph
606cdb17d3
core_timing: Sleep in discrete intervals, yield during spin
4 years ago
Kelebek1
658e1ee426
Add missing looping event schedule signal
4 years ago
Kelebek1
83a24ad638
Make coretiming waiting more accurate
4 years ago
Maide
2e46110379
Revert Coretiming PRs 8531 and 7454 ( #8591 )
4 years ago
Kelebek1
240650f6a6
Rework CoreTiming
4 years ago
Fernando Sahmkow
d3cb9201f1
Core timing: use only one thread.
4 years ago
Fernando Sahmkow
3196d957b0
Adress Feedback.
4 years ago
Fernando Sahmkow
86ccce3721
Address feedback.
4 years ago
Fernando Sahmkow
38e4a144a1
Core: Protect each event from race conditions within it.
4 years ago
Fernando Sahmkow
a2d29412cb
Core/Common: Corrections to core timing and add critical priority.
4 years ago
Fernando Sahmkow
846c994cc9
Core: Reimplement Core Timing.
4 years ago
Morph
99ceb03a1c
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.
4 years ago
Lioncash
ebb64d5bf4
core: Resolve misc cases of variable shadowing
Resolves shadowing warnings that aren't in a particularly large
subsection of core. Brings us closer to turning -Wshadow into an error.
All that remains now is for cases in the kernel (left untouched for now
since a big change by bunnei is pending), and a few left over in the
service code (will be tackled next).
5 years ago
bunnei
82f6037ec2
core: hle: Add missing calls to MicroProfileOnThreadExit.
5 years ago
bunnei
3d592972dc
Revert "core: Fix clang build"
6 years ago
Lioncash
be1954e04c
core: Fix clang build
Recent changes to the build system that made more warnings be flagged as
errors caused building via clang to break.
Fixes #4795
6 years ago
Lioncash
79504f1a39
core_timing: Remove unused header
6 years ago
Lioncash
25cd5d9dda
core_timing: Move clock initializer into constructor initializer list
Same behavior, minus unnecessary zeroing out of the pointer.
6 years ago
Lioncash
2624b1eae6
core_timing: Resolve sign conversion warning
This constant is only ever assigned to downcount, which is a s64, not a
u64.
6 years ago
Lioncash
a7af349dae
core_timing: Make use of uintptr_t to represent user_data
Makes the interface future-proofed for supporting other platforms in the event we ever support platforms with differing pointer sizes. This way, we have a type in place that is always guaranteed to be able to represent a pointer exactly.
6 years ago
Lioncash
bef1844a51
core_timing: Make TimedCallback take std::chrono::nanoseconds
Enforces our desired time units directly with a concrete type.
6 years ago
Lioncash
8b50c660df
core_timing: Make use of std::chrono with ScheduleEvent
6 years ago
ReinUsesLisp
8562b516c0
core_timing,scheduler: Use std::scoped_lock when possible
Simplifies the cognitive load of procedures using locks and makes locks
safe against exceptions.
6 years ago
Fernando Sahmkow
2f8947583f
Core/Common: Address Feedback.
6 years ago
Fernando Sahmkow
71f1c0f9f9
CoreTiming: Correct rebase bugs and other miscellaneous things.
6 years ago
Fernando Sahmkow
528b19a842
General: Tune the priority of main emulation threads so they have higher priority than less important helper threads.
6 years ago
Fernando Sahmkow
bfb5244cf8
CoreTiming/CycleTimer: Correct Idling.
6 years ago
Fernando Sahmkow
f5e32935ca
SingleCore: Use Cycle Timing instead of Host Timing.
6 years ago
Fernando Sahmkow
f2ade343e2
SingleCore: Move Host Timing from a sepparate thread to main cpu thread.
6 years ago
Fernando Sahmkow
e6f8bde74b
General: Fix Stop function
6 years ago
Fernando Sahmkow
07993ac8c8
Kernel: Corrections to Scheduling.
6 years ago
Fernando Sahmkow
18dcb09342
HostTiming: Pause the hardware clock on pause.
6 years ago
Fernando Sahmkow
dc58058203
General: Setup yuzu threads' microprofile, naming and registry.
6 years ago
Fernando Sahmkow
e31425df38
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.
6 years ago
Fernando Sahmkow
1e6f8aba04
Core: Set all hardware emulation constants in a single file.
6 years ago
bunnei
ec0ce96c56
core_timing: Use better reference tracking for EventType. ( #3159 )
* core_timing: Use better reference tracking for EventType.
- Moves ownership of the event to the caller, ensuring we don't fire events for destroyed objects.
- Removes need for unique names - we won't be using this for save states anyways.
6 years ago
Fernando Sahmkow
a4ae11d63e
Core_Timing: Address Remaining feedback.
7 years ago
Fernando Sahmkow
e0650a2034
Core_Timing: Address Feedback and suppress warnings.
7 years ago
Fernando Sahmkow
96f2b16356
Core Timing: Correct Idle and remove lefting pragma
7 years ago