mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 09:38:07 +02:00
v3d: Fix segfault when failing to compile a program.
We'll still fail at draw time, but this avoids a regression in shader-db
execution once I enable TLB writes in precompiles.
Fixes: b38e4d313f ("v3d: Create a state uploader for packing our shaders together.")
This commit is contained in:
parent
3ae57957be
commit
3a81c753a3
1 changed files with 4 additions and 2 deletions
|
|
@ -373,8 +373,10 @@ v3d_get_compiled_shader(struct v3d_context *v3d, struct v3d_key *key)
|
|||
|
||||
v3d_set_shader_uniform_dirty_flags(shader);
|
||||
|
||||
u_upload_data(v3d->state_uploader, 0, shader_size, 8,
|
||||
qpu_insts, &shader->offset, &shader->resource);
|
||||
if (shader_size) {
|
||||
u_upload_data(v3d->state_uploader, 0, shader_size, 8,
|
||||
qpu_insts, &shader->offset, &shader->resource);
|
||||
}
|
||||
|
||||
free(qpu_insts);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue