mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 05:18:08 +02:00
r600g/sb: fix handling of preloaded inputs for compute shaders
For compute shaders we need to let the backend know that GPRs 0 and 1 are preloaded with some compute-specific input values, otherwise any use of these regs without previous definition is considered as undefined value and usually is simply replaced with 0. Signed-off-by: Vadim Girlin <vadimgirlin@gmail.com>
This commit is contained in:
parent
fd9fe4470b
commit
44a117ab9a
1 changed files with 4 additions and 0 deletions
|
|
@ -111,6 +111,10 @@ int bc_parser::parse_decls() {
|
|||
if (!pshader) {
|
||||
if (gpr_reladdr)
|
||||
sh->add_gpr_array(0, bc->ngpr, 0x0F);
|
||||
|
||||
// compute shaders have some values preloaded in R0, R1
|
||||
sh->add_input(0 /* GPR */, true /* preloaded */, 0x0F /* mask */);
|
||||
sh->add_input(1 /* GPR */, true /* preloaded */, 0x0F /* mask */);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue