yuzu/src/video_core/host1x/host1x.h

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

69 lines
1.5 KiB
C++
Raw Normal View History

// SPDX-FileCopyrightText: 2021 yuzu Emulator Project
// SPDX-License-Identifier: GPL-3.0-or-later
2022-01-30 10:31:13 +01:00
#pragma once
#include "common/common_types.h"
2023-12-29 09:50:04 +01:00
#include "common/address_space.h"
#include "video_core/host1x/gpu_device_memory_manager.h"
2022-01-30 10:31:13 +01:00
#include "video_core/host1x/syncpoint_manager.h"
2023-12-29 09:50:04 +01:00
#include "video_core/memory_manager.h"
2022-01-30 22:26:01 +01:00
namespace Core {
class System;
} // namespace Core
2022-01-30 10:31:13 +01:00
namespace Tegra {
namespace Host1x {
class Host1x {
public:
2022-09-01 05:45:22 +02:00
explicit Host1x(Core::System& system);
2023-12-30 04:37:25 +01:00
~Host1x();
2022-01-30 10:31:13 +01:00
SyncpointManager& GetSyncpointManager() {
return syncpoint_manager;
}
const SyncpointManager& GetSyncpointManager() const {
return syncpoint_manager;
}
Tegra::MaxwellDeviceMemoryManager& MemoryManager() {
2022-01-30 22:26:01 +01:00
return memory_manager;
}
const Tegra::MaxwellDeviceMemoryManager& MemoryManager() const {
2022-01-30 22:26:01 +01:00
return memory_manager;
}
2023-12-29 09:50:04 +01:00
Tegra::MemoryManager& GMMU() {
return gmmu_manager;
}
const Tegra::MemoryManager& GMMU() const {
return gmmu_manager;
}
Common::FlatAllocator<u32, 0, 32>& Allocator() {
return *allocator;
}
const Common::FlatAllocator<u32, 0, 32>& Allocator() const {
return *allocator;
}
2022-01-30 10:31:13 +01:00
private:
2022-01-30 22:26:01 +01:00
Core::System& system;
2022-01-30 10:31:13 +01:00
SyncpointManager syncpoint_manager;
Tegra::MaxwellDeviceMemoryManager memory_manager;
2023-12-29 09:50:04 +01:00
Tegra::MemoryManager gmmu_manager;
std::unique_ptr<Common::FlatAllocator<u32, 0, 32>> allocator;
2022-01-30 10:31:13 +01:00
};
} // namespace Host1x
} // namespace Tegra