diff options
Diffstat (limited to 'src/core/core_timing.cpp')
| -rw-r--r-- | src/core/core_timing.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/core/core_timing.cpp b/src/core/core_timing.cpp index 780c6843a..0e9570685 100644 --- a/src/core/core_timing.cpp +++ b/src/core/core_timing.cpp | |||
| @@ -203,14 +203,13 @@ void CoreTiming::Advance() { | |||
| 203 | } | 203 | } |
| 204 | 204 | ||
| 205 | void CoreTiming::ResetRun() { | 205 | void CoreTiming::ResetRun() { |
| 206 | for (std::size_t core = 0; core < num_cpu_cores; core++) { | 206 | downcounts.fill(MAX_SLICE_LENGTH); |
| 207 | downcounts[core] = MAX_SLICE_LENGTH; | 207 | time_slice.fill(MAX_SLICE_LENGTH); |
| 208 | time_slice[core] = MAX_SLICE_LENGTH; | ||
| 209 | } | ||
| 210 | current_context = 0; | 208 | current_context = 0; |
| 211 | // Still events left (scheduled in the future) | 209 | // Still events left (scheduled in the future) |
| 212 | if (!event_queue.empty()) { | 210 | if (!event_queue.empty()) { |
| 213 | s64 needed_ticks = std::min<s64>(event_queue.front().time - global_timer, MAX_SLICE_LENGTH); | 211 | const s64 needed_ticks = |
| 212 | std::min<s64>(event_queue.front().time - global_timer, MAX_SLICE_LENGTH); | ||
| 214 | downcounts[current_context] = needed_ticks; | 213 | downcounts[current_context] = needed_ticks; |
| 215 | } | 214 | } |
| 216 | 215 | ||