CPU_Manager: Reconfigre guest threads for dynamrmic downsides
This commit is contained in:
parent
15a79eb0d7
commit
3d9fbb8226
@ -80,9 +80,10 @@ void CpuManager::RunGuestThread() {
|
||||
}
|
||||
while (true) {
|
||||
auto& physical_core = kernel.CurrentPhysicalCore();
|
||||
if (!physical_core.IsInterrupted()) {
|
||||
while (!physical_core.IsInterrupted()) {
|
||||
physical_core.Run();
|
||||
}
|
||||
physical_core.ClearExclusive();
|
||||
auto& scheduler = physical_core.Scheduler();
|
||||
scheduler.TryDoContextSwitch();
|
||||
}
|
||||
|
@ -45,6 +45,9 @@ PhysicalCore::~PhysicalCore() = default;
|
||||
|
||||
void PhysicalCore::Run() {
|
||||
arm_interface->Run();
|
||||
}
|
||||
|
||||
void PhysicalCore::ClearExclusive() {
|
||||
arm_interface->ClearExclusiveState();
|
||||
}
|
||||
|
||||
|
@ -38,6 +38,8 @@ public:
|
||||
|
||||
/// Execute current jit state
|
||||
void Run();
|
||||
/// Clear Exclusive state.
|
||||
void ClearExclusive();
|
||||
/// Set this core in IdleState.
|
||||
void Idle();
|
||||
/// Execute a single instruction in current jit.
|
||||
|
Loading…
Reference in New Issue
Block a user