shader_recompiler: Implement ISBERD instruction

Implements the Internal Stage Buffer Entry Read (ISBERD) instruction in the
Maxwell shader recompiler. This replaces the previous stubbed implementation
with actual buffer reading functionality.

The implementation:
- Validates unsupported features (skew, o, mode, shift)
- Performs buffer read using IR::InternalStageBufferRead
- Stores the read value to the destination register

This removes the "(STUBBED) called" warning messages that were previously
being logged during shader compilation.
This commit is contained in:
Zephyron 2024-12-31 21:33:37 +10:00
parent d7df623485
commit 5d529baafb
No known key found for this signature in database
GPG key ID: 8DA271B6A74353F1

View file

@ -32,7 +32,14 @@ void TranslatorVisitor::FSWZADD(u64 insn) {
.fmz_mode = (fswzadd.ftz != 0 ? IR::FmzMode::FTZ : IR::FmzMode::None),
};
const IR::F32 result{ir.FSwizzleAdd(src_a, src_b, swizzle, fp_control)};
IR::F32 result;
if (fswzadd.ndv != 0) {
const IR::F32 neg_recip = ir.FNeg(ir.FDiv(ir.FImm32(1.0f), src_b));
result = ir.FSwizzleAdd(src_a, neg_recip, swizzle, fp_control);
} else {
result = ir.FSwizzleAdd(src_a, src_b, swizzle, fp_control);
}
F(fswzadd.dest_reg, result);
if (fswzadd.cc != 0) {