mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 05:18:08 +02:00
r300/compiler: Silence array-bounds warning
Suggested-by: @eric Signed-off-by: Valentine Burley <valentine.burley@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35853>
This commit is contained in:
parent
98736e55e0
commit
57334b9cf1
1 changed files with 5 additions and 2 deletions
|
|
@ -477,10 +477,13 @@ rc_init_regalloc_state(struct rc_regalloc_state *s, enum rc_program_type prog)
|
|||
for (i = 0; i < class_count; i++) {
|
||||
ra_q_values[i] = MALLOC(class_count * sizeof(unsigned));
|
||||
for (j = 0; j < class_count; j++) {
|
||||
if (prog == RC_FRAGMENT_PROGRAM)
|
||||
if (prog == RC_FRAGMENT_PROGRAM) {
|
||||
assume(j < RC_REG_CLASS_FP_COUNT);
|
||||
ra_q_values[i][j] = q_values_fp[i][j];
|
||||
else
|
||||
} else {
|
||||
assume(j < RC_REG_CLASS_VP_COUNT);
|
||||
ra_q_values[i][j] = q_values_vp[i][j];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue