summaryrefslogtreecommitdiffstats
path: root/src/video_core/shader/shader_jit_x64.cpp
diff options
context:
space:
mode:
authorYuri Kunde Schlesner <yuriks@yuriks.net>2016-12-16 07:35:34 +0100
committerYuri Kunde Schlesner <yuriks@yuriks.net>2016-12-16 08:08:05 +0100
commite4e962bc7c593c7dd0957af12e56b30e6bee5c06 (patch)
treed830aa090e1d1881b4cf26026ab9fbb02dfcfd5f /src/video_core/shader/shader_jit_x64.cpp
parentVideoCore/Shader: Move DebugData to a separate file (diff)
downloadyuzu-e4e962bc7c593c7dd0957af12e56b30e6bee5c06.tar
yuzu-e4e962bc7c593c7dd0957af12e56b30e6bee5c06.tar.gz
yuzu-e4e962bc7c593c7dd0957af12e56b30e6bee5c06.tar.bz2
yuzu-e4e962bc7c593c7dd0957af12e56b30e6bee5c06.tar.lz
yuzu-e4e962bc7c593c7dd0957af12e56b30e6bee5c06.tar.xz
yuzu-e4e962bc7c593c7dd0957af12e56b30e6bee5c06.tar.zst
yuzu-e4e962bc7c593c7dd0957af12e56b30e6bee5c06.zip
Diffstat (limited to 'src/video_core/shader/shader_jit_x64.cpp')
-rw-r--r--src/video_core/shader/shader_jit_x64.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/video_core/shader/shader_jit_x64.cpp b/src/video_core/shader/shader_jit_x64.cpp
index 3ba31d474..a85a6776f 100644
--- a/src/video_core/shader/shader_jit_x64.cpp
+++ b/src/video_core/shader/shader_jit_x64.cpp
@@ -185,7 +185,7 @@ void JitShader::Compile_SwizzleSrc(Instruction instr, unsigned src_num, SourceRe
if (src_reg.GetRegisterType() == RegisterType::FloatUniform) {
src_ptr = SETUP;
- src_offset = ShaderSetup::UniformOffset(RegisterType::FloatUniform, src_reg.GetIndex());
+ src_offset = ShaderSetup::GetFloatUniformOffset(src_reg.GetIndex());
} else {
src_ptr = STATE;
src_offset = UnitState<false>::InputOffset(src_reg);
@@ -348,8 +348,7 @@ void JitShader::Compile_EvaluateCondition(Instruction instr) {
}
void JitShader::Compile_UniformCondition(Instruction instr) {
- size_t offset =
- ShaderSetup::UniformOffset(RegisterType::BoolUniform, instr.flow_control.bool_uniform_id);
+ size_t offset = ShaderSetup::GetBoolUniformOffset(instr.flow_control.bool_uniform_id);
cmp(byte[SETUP + offset], 0);
}
@@ -732,8 +731,7 @@ void JitShader::Compile_LOOP(Instruction instr) {
// This decodes the fields from the integer uniform at index instr.flow_control.int_uniform_id.
// The Y (LOOPCOUNT_REG) and Z (LOOPINC) component are kept multiplied by 16 (Left shifted by
// 4 bits) to be used as an offset into the 16-byte vector registers later
- size_t offset =
- ShaderSetup::UniformOffset(RegisterType::IntUniform, instr.flow_control.int_uniform_id);
+ size_t offset = ShaderSetup::GetIntUniformOffset(instr.flow_control.int_uniform_id);
mov(LOOPCOUNT, dword[SETUP + offset]);
mov(LOOPCOUNT_REG, LOOPCOUNT);
shr(LOOPCOUNT_REG, 4);