mirror of
https://github.com/yuzu-emu/yuzu.git
synced 2025-06-21 16:17:59 -05:00
Kernel: Refactor synchronization to better match RE
This commit is contained in:
committed by
FernandoS27
parent
c5aefe42aa
commit
d23d504d77
34
src/core/hle/kernel/synchronization.h
Normal file
34
src/core/hle/kernel/synchronization.h
Normal file
@ -0,0 +1,34 @@
|
||||
// Copyright 2020 yuzu Emulator Project
|
||||
// Licensed under GPLv2 or any later version
|
||||
// Refer to the license.txt file included.
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <memory>
|
||||
#include <utility>
|
||||
|
||||
#include "core/hle/kernel/object.h"
|
||||
#include "core/hle/result.h"
|
||||
|
||||
namespace Core {
|
||||
class System;
|
||||
} // namespace Core
|
||||
|
||||
namespace Kernel {
|
||||
|
||||
class KernelCore;
|
||||
class SynchronizationObject;
|
||||
|
||||
class Synchronization {
|
||||
public:
|
||||
Synchronization(Core::System& system);
|
||||
|
||||
void SignalObject(SynchronizationObject& obj) const;
|
||||
|
||||
std::pair<ResultCode, Handle> WaitFor(
|
||||
std::vector<std::shared_ptr<SynchronizationObject>>& sync_objects, s64 nano_seconds);
|
||||
|
||||
private:
|
||||
Core::System& system;
|
||||
};
|
||||
} // namespace Kernel
|
Reference in New Issue
Block a user