mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 09:38:07 +02:00
llvmpipe/cs: add in shader shared size.
(can remove lavapipe setting this later). Reviewed-by: Roland Scheidegger <sroland@vmware.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6954>
This commit is contained in:
parent
35b162eb2c
commit
e8f1cc41db
1 changed files with 2 additions and 1 deletions
|
|
@ -438,6 +438,7 @@ llvmpipe_create_compute_state(struct pipe_context *pipe,
|
|||
shader->no = cs_no++;
|
||||
|
||||
shader->base.type = templ->ir_type;
|
||||
shader->req_local_mem = templ->req_local_mem;
|
||||
if (templ->ir_type == PIPE_SHADER_IR_NIR_SERIALIZED) {
|
||||
struct blob_reader reader;
|
||||
const struct pipe_binary_program_header *hdr = templ->prog;
|
||||
|
|
@ -447,6 +448,7 @@ llvmpipe_create_compute_state(struct pipe_context *pipe,
|
|||
shader->base.type = PIPE_SHADER_IR_NIR;
|
||||
|
||||
pipe->screen->finalize_nir(pipe->screen, shader->base.ir.nir, false);
|
||||
shader->req_local_mem += ((struct nir_shader *)shader->base.ir.nir)->info.cs.shared_size;
|
||||
} else if (templ->ir_type == PIPE_SHADER_IR_NIR)
|
||||
shader->base.ir.nir = (struct nir_shader *)templ->prog;
|
||||
|
||||
|
|
@ -460,7 +462,6 @@ llvmpipe_create_compute_state(struct pipe_context *pipe,
|
|||
nir_tgsi_scan_shader(shader->base.ir.nir, &shader->info.base, false);
|
||||
}
|
||||
|
||||
shader->req_local_mem = templ->req_local_mem;
|
||||
make_empty_list(&shader->variants);
|
||||
|
||||
nr_samplers = shader->info.base.file_max[TGSI_FILE_SAMPLER] + 1;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue