aboutsummaryrefslogtreecommitdiff
path: root/src/video_core/engines/nv01_timer.h
blob: 37c66681445f70f7e7e3c0c11b130023c77dd841 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
// SPDX-FileCopyrightText: Copyright 2026 Eden Emulator Project
// SPDX-License-Identifier: GPL-3.0-or-later

// SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later

#pragma once

#include <array>
#include <cstddef>
#include "common/bit_field.h"
#include "common/common_funcs.h"
#include "common/common_types.h"
#include "common/logging.h"
#include "video_core/engines/engine_interface.h"
#include "video_core/engines/engine_upload.h"

namespace Core {
class System;
}

namespace Tegra {
class MemoryManager;
}

namespace Tegra::Engines {
class Nv01Timer final : public EngineInterface {
public:
    explicit Nv01Timer(MemoryManager& memory_manager) noexcept {}
    ~Nv01Timer() noexcept override {}

    /// Write the value to the register identified by method.
    void CallMethod(Core::System& system, u32 method, u32 method_argument, bool is_last_call) override {
        LOG_DEBUG(HW_GPU, "method={}, argument={}, is_last_call={}", method, method_argument, is_last_call);
    }

    /// Write multiple values to the register identified by method.
    void CallMultiMethod(Core::System& system, u32 method, const u32* base_start, u32 amount, u32 methods_pending) override {
        LOG_DEBUG(HW_GPU, "method={}, base_start={}, amount={}, pending={}", method, fmt::ptr(base_start), amount, methods_pending);
    }

    struct Regs {
        // No fucking idea
        INSERT_PADDING_BYTES_NOINIT(0x48);
    } regs{};
private:
    void ConsumeSinkImpl(Core::System& system) override {}
};
}