mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 00:58:05 +02:00
ac: fix buffer overflow bug in 64bit SSBO loads
Fixes: 441ee1e65b "radv/ac: Implement Float64 SSBO loads"
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
parent
409e15f26f
commit
e2b9296146
1 changed files with 4 additions and 1 deletions
|
|
@ -2588,8 +2588,11 @@ static LLVMValueRef visit_load_buffer(struct ac_nir_context *ctx,
|
|||
ctx->ac.i1false,
|
||||
};
|
||||
|
||||
results[i] = ac_build_intrinsic(&ctx->ac, load_name, data_type, params, 5, 0);
|
||||
int idx = i;
|
||||
if (instr->dest.ssa.bit_size == 64)
|
||||
idx = i > 1 ? 1 : 0;
|
||||
|
||||
results[idx] = ac_build_intrinsic(&ctx->ac, load_name, data_type, params, 5, 0);
|
||||
}
|
||||
|
||||
assume(results[0]);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue