V_NOP | PfpSyncMe | S_CMPK_EQ_U32 (#426)
* V_NOP V_NOP = Do nothing * PfpSyncMe PfpSyncMe ensures that all previous commands are completed before continuing. 'break' should be enough for now * S_CMPK_EQ_U32 S_CMPK_EQ_U32 SCC = (D.u == SIMM16) * S_CMPK_EQ_U32 * OperandField::Undefined: * Update translate.cpp remove OperandField::Undefined: * Update image_view.cpp [Render.Vulkan] <Error> image_view.cpp:ImageViewInfo:109: Storage image (num_comps = 4) requires swizzling [BGRA] format 43 dst_sel 3886 * Update liverpool_to_vk.cpp * S_CMPK_EQ_U32 * S_CMPK_EQ_U32
This commit is contained in:
parent
b687ae5e34
commit
2a737d0800
|
@ -96,6 +96,8 @@ void Translator::EmitScalarAlu(const GcnInst& inst) {
|
||||||
return S_MAX_U32(inst);
|
return S_MAX_U32(inst);
|
||||||
case Opcode::S_WQM_B64:
|
case Opcode::S_WQM_B64:
|
||||||
break;
|
break;
|
||||||
|
case Opcode::S_CMPK_EQ_U32:
|
||||||
|
return S_CMPK_EQ_U32(inst);
|
||||||
default:
|
default:
|
||||||
LogMissingOpcode(inst);
|
LogMissingOpcode(inst);
|
||||||
}
|
}
|
||||||
|
@ -468,4 +470,11 @@ void Translator::S_MIN_U32(const GcnInst& inst) {
|
||||||
ir.SetScc(ir.IEqual(result, src0));
|
ir.SetScc(ir.IEqual(result, src0));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Translator::S_CMPK_EQ_U32(const GcnInst& inst) {
|
||||||
|
const s32 simm16 = inst.control.sopk.simm;
|
||||||
|
const IR::U32 src0{GetSrc(inst.src[0])};
|
||||||
|
const IR::U32 src1{ir.Imm32(simm16)};
|
||||||
|
ir.SetScc(ir.IEqual(src0, src1));
|
||||||
|
}
|
||||||
|
|
||||||
} // namespace Shader::Gcn
|
} // namespace Shader::Gcn
|
||||||
|
|
|
@ -98,6 +98,7 @@ public:
|
||||||
void S_ADDK_I32(const GcnInst& inst);
|
void S_ADDK_I32(const GcnInst& inst);
|
||||||
void S_MAX_U32(const GcnInst& inst);
|
void S_MAX_U32(const GcnInst& inst);
|
||||||
void S_MIN_U32(const GcnInst& inst);
|
void S_MIN_U32(const GcnInst& inst);
|
||||||
|
void S_CMPK_EQ_U32(const GcnInst& inst);
|
||||||
|
|
||||||
// Scalar Memory
|
// Scalar Memory
|
||||||
void S_LOAD_DWORD(int num_dwords, const GcnInst& inst);
|
void S_LOAD_DWORD(int num_dwords, const GcnInst& inst);
|
||||||
|
|
|
@ -307,6 +307,8 @@ void Translator::EmitVectorAlu(const GcnInst& inst) {
|
||||||
return V_MBCNT_U32_B32(true, inst);
|
return V_MBCNT_U32_B32(true, inst);
|
||||||
case Opcode::V_MBCNT_HI_U32_B32:
|
case Opcode::V_MBCNT_HI_U32_B32:
|
||||||
return V_MBCNT_U32_B32(false, inst);
|
return V_MBCNT_U32_B32(false, inst);
|
||||||
|
case Opcode::V_NOP:
|
||||||
|
return;
|
||||||
default:
|
default:
|
||||||
LogMissingOpcode(inst);
|
LogMissingOpcode(inst);
|
||||||
}
|
}
|
||||||
|
|
|
@ -455,6 +455,9 @@ Liverpool::Task Liverpool::ProcessGraphics(std::span<const u32> dcb, std::span<c
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case PM4ItOpcode::PfpSyncMe: {
|
||||||
|
break;
|
||||||
|
}
|
||||||
default:
|
default:
|
||||||
UNREACHABLE_MSG("Unknown PM4 type 3 opcode {:#x} with count {}",
|
UNREACHABLE_MSG("Unknown PM4 type 3 opcode {:#x} with count {}",
|
||||||
static_cast<u32>(opcode), count);
|
static_cast<u32>(opcode), count);
|
||||||
|
|
|
@ -320,6 +320,7 @@ std::span<const vk::Format> GetAllFormats() {
|
||||||
vk::Format::eR8G8Uint,
|
vk::Format::eR8G8Uint,
|
||||||
vk::Format::eR8G8Unorm,
|
vk::Format::eR8G8Unorm,
|
||||||
vk::Format::eR8Sint,
|
vk::Format::eR8Sint,
|
||||||
|
vk::Format::eR8Snorm,
|
||||||
vk::Format::eR8Uint,
|
vk::Format::eR8Uint,
|
||||||
vk::Format::eR8Unorm,
|
vk::Format::eR8Unorm,
|
||||||
vk::Format::eR8Srgb,
|
vk::Format::eR8Srgb,
|
||||||
|
|
|
@ -59,6 +59,9 @@ vk::Format TrySwizzleFormat(vk::Format format, u32 dst_sel) {
|
||||||
if (format == vk::Format::eR8G8B8A8Unorm && dst_sel == 0b111100101110) {
|
if (format == vk::Format::eR8G8B8A8Unorm && dst_sel == 0b111100101110) {
|
||||||
return vk::Format::eB8G8R8A8Unorm;
|
return vk::Format::eB8G8R8A8Unorm;
|
||||||
}
|
}
|
||||||
|
if (format == vk::Format::eR8G8B8A8Srgb && dst_sel == 0b111100101110) {
|
||||||
|
return vk::Format::eB8G8R8A8Srgb;
|
||||||
|
}
|
||||||
return format;
|
return format;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue