diff options
author | bunnei <bunneidev@gmail.com> | 2021-01-07 21:42:28 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-07 21:42:28 +0100 |
commit | aaf9e39f5624abee7457e8d81048516beaf43c4f (patch) | |
tree | 7039db82d3a5b08b2f7d437bb572f818645a8e7d /src/video_core/command_classes/host1x.cpp | |
parent | Merge pull request #5306 from MerryMage/ignore-library-Open (diff) | |
parent | remove inaccurate reference (diff) | |
download | yuzu-aaf9e39f5624abee7457e8d81048516beaf43c4f.tar yuzu-aaf9e39f5624abee7457e8d81048516beaf43c4f.tar.gz yuzu-aaf9e39f5624abee7457e8d81048516beaf43c4f.tar.bz2 yuzu-aaf9e39f5624abee7457e8d81048516beaf43c4f.tar.lz yuzu-aaf9e39f5624abee7457e8d81048516beaf43c4f.tar.xz yuzu-aaf9e39f5624abee7457e8d81048516beaf43c4f.tar.zst yuzu-aaf9e39f5624abee7457e8d81048516beaf43c4f.zip |
Diffstat (limited to 'src/video_core/command_classes/host1x.cpp')
-rw-r--r-- | src/video_core/command_classes/host1x.cpp | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/src/video_core/command_classes/host1x.cpp b/src/video_core/command_classes/host1x.cpp index c4dd4881a..b12494528 100644 --- a/src/video_core/command_classes/host1x.cpp +++ b/src/video_core/command_classes/host1x.cpp @@ -10,22 +10,14 @@ Tegra::Host1x::Host1x(GPU& gpu_) : gpu(gpu_) {} Tegra::Host1x::~Host1x() = default; -void Tegra::Host1x::StateWrite(u32 offset, u32 arguments) { - u8* const state_offset = reinterpret_cast<u8*>(&state) + offset * sizeof(u32); - std::memcpy(state_offset, &arguments, sizeof(u32)); -} - -void Tegra::Host1x::ProcessMethod(Method method, const std::vector<u32>& arguments) { - StateWrite(static_cast<u32>(method), arguments[0]); +void Tegra::Host1x::ProcessMethod(Method method, u32 argument) { switch (method) { - case Method::WaitSyncpt: - Execute(arguments[0]); - break; case Method::LoadSyncptPayload32: - syncpoint_value = arguments[0]; + syncpoint_value = argument; break; + case Method::WaitSyncpt: case Method::WaitSyncpt32: - Execute(arguments[0]); + Execute(argument); break; default: UNIMPLEMENTED_MSG("Host1x method 0x{:X}", static_cast<u32>(method)); @@ -34,6 +26,5 @@ void Tegra::Host1x::ProcessMethod(Method method, const std::vector<u32>& argumen } void Tegra::Host1x::Execute(u32 data) { - // This method waits on a valid syncpoint. - // TODO: Implement when proper Async is in place + gpu.WaitFence(data, syncpoint_value); } |