diff options
author | bunnei <bunneidev@gmail.com> | 2020-12-05 09:48:08 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-05 09:48:08 +0100 |
commit | e6a896c4bdf9cc47c2002c115c9ff280e540fd1b (patch) | |
tree | e5cd397cb3a11f1529f38ed8fa0a0185d07becaa /src/video_core/macro/macro_interpreter.cpp | |
parent | Merge pull request #5127 from FearlessTobi/port-5617 (diff) | |
parent | video_core: Resolve more variable shadowing scenarios (diff) | |
download | yuzu-e6a896c4bdf9cc47c2002c115c9ff280e540fd1b.tar yuzu-e6a896c4bdf9cc47c2002c115c9ff280e540fd1b.tar.gz yuzu-e6a896c4bdf9cc47c2002c115c9ff280e540fd1b.tar.bz2 yuzu-e6a896c4bdf9cc47c2002c115c9ff280e540fd1b.tar.lz yuzu-e6a896c4bdf9cc47c2002c115c9ff280e540fd1b.tar.xz yuzu-e6a896c4bdf9cc47c2002c115c9ff280e540fd1b.tar.zst yuzu-e6a896c4bdf9cc47c2002c115c9ff280e540fd1b.zip |
Diffstat (limited to 'src/video_core/macro/macro_interpreter.cpp')
-rw-r--r-- | src/video_core/macro/macro_interpreter.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/video_core/macro/macro_interpreter.cpp b/src/video_core/macro/macro_interpreter.cpp index bd01fd1f2..44a71aa6c 100644 --- a/src/video_core/macro/macro_interpreter.cpp +++ b/src/video_core/macro/macro_interpreter.cpp @@ -11,29 +11,29 @@ MICROPROFILE_DEFINE(MacroInterp, "GPU", "Execute macro interpreter", MP_RGB(128, 128, 192)); namespace Tegra { -MacroInterpreter::MacroInterpreter(Engines::Maxwell3D& maxwell3d) - : MacroEngine::MacroEngine(maxwell3d), maxwell3d(maxwell3d) {} +MacroInterpreter::MacroInterpreter(Engines::Maxwell3D& maxwell3d_) + : MacroEngine{maxwell3d_}, maxwell3d{maxwell3d_} {} std::unique_ptr<CachedMacro> MacroInterpreter::Compile(const std::vector<u32>& code) { return std::make_unique<MacroInterpreterImpl>(maxwell3d, code); } -MacroInterpreterImpl::MacroInterpreterImpl(Engines::Maxwell3D& maxwell3d, - const std::vector<u32>& code) - : maxwell3d(maxwell3d), code(code) {} +MacroInterpreterImpl::MacroInterpreterImpl(Engines::Maxwell3D& maxwell3d_, + const std::vector<u32>& code_) + : maxwell3d{maxwell3d_}, code{code_} {} -void MacroInterpreterImpl::Execute(const std::vector<u32>& parameters, u32 method) { +void MacroInterpreterImpl::Execute(const std::vector<u32>& params, u32 method) { MICROPROFILE_SCOPE(MacroInterp); Reset(); - registers[1] = parameters[0]; - num_parameters = parameters.size(); + registers[1] = params[0]; + num_parameters = params.size(); if (num_parameters > parameters_capacity) { parameters_capacity = num_parameters; - this->parameters = std::make_unique<u32[]>(num_parameters); + parameters = std::make_unique<u32[]>(num_parameters); } - std::memcpy(this->parameters.get(), parameters.data(), num_parameters * sizeof(u32)); + std::memcpy(parameters.get(), params.data(), num_parameters * sizeof(u32)); // Execute the code until we hit an exit condition. bool keep_executing = true; |