mirror of
https://github.com/RPCS3/rpcs3.git
synced 2024-11-16 23:17:29 +00:00
rsx: Fix transform contants load
This commit is contained in:
parent
c4e89f8bb4
commit
b5014d56ab
@ -425,11 +425,15 @@ namespace rsx
|
||||
const u32 load = rsx::method_registers.transform_constant_load();
|
||||
|
||||
u32 rcount = count;
|
||||
if (const u32 max = (load + reg) * 4 + count + subreg; max > 468 * 4)
|
||||
if (const u32 max = (load + reg) * 4 + count + subreg, limit = 468 * 4; max > limit)
|
||||
{
|
||||
// Ignore addresses outside the usable [0, 467] range
|
||||
rsx_log.warning("Invalid transform register index (load=%u, index=%u, count=%u)", load, index, count);
|
||||
rcount -= max - (468 * 4);
|
||||
|
||||
if ((max - count) < limit)
|
||||
rcount -= max - limit;
|
||||
else
|
||||
rcount = 0;
|
||||
}
|
||||
|
||||
const auto values = &rsx::method_registers.transform_constants[load + reg][subreg];
|
||||
|
Loading…
Reference in New Issue
Block a user