1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-02-20 19:54:19 +01:00

[dxbc] OpSDiv by 4 -> OpShiftRightLogical by 2

This commit is contained in:
Philip Rebohle 2019-02-07 19:32:07 +01:00
parent 8b80db7839
commit 915091b76b
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99

View File

@ -5102,7 +5102,7 @@ namespace dxvk {
result.id = m_module.opIAdd(typeId,
m_module.opIMul(typeId, structId.id, m_module.consti32(structStride / 4)),
m_module.opSDiv(typeId, structOffset.id, m_module.consti32(4)));
m_module.opShiftRightLogical(typeId, structOffset.id, m_module.consti32(2)));
return result;
}
@ -5112,10 +5112,10 @@ namespace dxvk {
DxbcRegisterValue result;
result.type.ctype = DxbcScalarType::Sint32;
result.type.ccount = 1;
result.id = m_module.opSDiv(
result.id = m_module.opShiftRightLogical(
getVectorTypeId(result.type),
byteOffset.id,
m_module.consti32(4));
m_module.consti32(2));
return result;
}