aboutsummaryrefslogtreecommitdiff
path: root/src/core/core_cpu.cpp
diff options
context:
space:
mode:
authorFernando Sahmkow <fsahmkow27@gmail.com>2019-09-09 21:37:29 -0400
committerFernandoS27 <fsahmkow27@gmail.com>2019-10-09 12:30:31 -0400
commit555866f8dcb98897688d5d7b0e6c6cca55ac069f (patch)
tree287ffee685bd8fbd6a8a16aa02a198a6cab3ede3 /src/core/core_cpu.cpp
parente664c24355bb4a53b114719a9aba960c82658403 (diff)
Core Timing: Rework Core Timing to run all cores evenly.
Diffstat (limited to 'src/core/core_cpu.cpp')
-rw-r--r--src/core/core_cpu.cpp14
1 files changed, 3 insertions, 11 deletions
diff --git a/src/core/core_cpu.cpp b/src/core/core_cpu.cpp
index 21c410e342..6bd9639c6e 100644
--- a/src/core/core_cpu.cpp
+++ b/src/core/core_cpu.cpp
@@ -85,24 +85,16 @@ void Cpu::RunLoop(bool tight_loop) {
// instead advance to the next event and try to yield to the next thread
if (Kernel::GetCurrentThread() == nullptr) {
LOG_TRACE(Core, "Core-{} idling", core_index);
-
- if (IsMainCore()) {
- // TODO(Subv): Only let CoreTiming idle if all 4 cores are idling.
- core_timing.Idle();
- core_timing.Advance();
- }
-
+ core_timing.Idle();
+ core_timing.Advance();
PrepareReschedule();
} else {
- if (IsMainCore()) {
- core_timing.Advance();
- }
-
if (tight_loop) {
arm_interface->Run();
} else {
arm_interface->Step();
}
+ core_timing.Advance();
}
Reschedule();