mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 20:28:04 +02:00
zink: fix load/store scratch offsets
The offset is originally in bytes, so we have to handle it just like
shared load/stores.
Fixes: ddc5c30489 ("zink: handle global and scratch vars")
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24839>
This commit is contained in:
parent
e36c49b69a
commit
764851a24c
1 changed files with 2 additions and 0 deletions
|
|
@ -2044,6 +2044,7 @@ rewrite_bo_access_instr(nir_builder *b, nir_instr *instr, void *data)
|
|||
}
|
||||
return true;
|
||||
}
|
||||
case nir_intrinsic_load_scratch:
|
||||
case nir_intrinsic_load_shared:
|
||||
b->cursor = nir_before_instr(instr);
|
||||
bool force_2x32 = intr->def.bit_size == 64 && !has_int64;
|
||||
|
|
@ -2080,6 +2081,7 @@ rewrite_bo_access_instr(nir_builder *b, nir_instr *instr, void *data)
|
|||
}
|
||||
return true;
|
||||
}
|
||||
case nir_intrinsic_store_scratch:
|
||||
case nir_intrinsic_store_shared: {
|
||||
b->cursor = nir_before_instr(instr);
|
||||
bool force_2x32 = nir_src_bit_size(intr->src[0]) == 64 && !has_int64;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue