mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 09:38:07 +02:00
lima/ppir: initialize slots array for dummy/undef
Some functions in ppir iterate the ppir_op_info slots arrays looking
for the PPIR_INSTR_SLOT_END token. The dummy/undef internal ops may
appear in the scheduling code and their slots arrays did not contain
that token, which could result in invalid array reads.
Reported by gcc -fsanitize=address.
Signed-off-by: Erico Nunes <nunes.erico@gmail.com>
Reviewed-by: Vasily Khoruzhick <anarsoul@gmail.com>
Cc: 22.0 <mesa-stable>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14894>
(cherry picked from commit 7297f931f0)
This commit is contained in:
parent
1e7d39f9db
commit
295022cb75
2 changed files with 3 additions and 1 deletions
|
|
@ -715,7 +715,7 @@
|
|||
"description": "lima/ppir: initialize slots array for dummy/undef",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": null
|
||||
},
|
||||
|
|
|
|||
|
|
@ -330,12 +330,14 @@ const ppir_op_info ppir_op_infos[] = {
|
|||
.name = "undef",
|
||||
.type = ppir_node_type_alu,
|
||||
.slots = (int []) {
|
||||
PPIR_INSTR_SLOT_END
|
||||
},
|
||||
},
|
||||
[ppir_op_dummy] = {
|
||||
.name = "dummy",
|
||||
.type = ppir_node_type_alu,
|
||||
.slots = (int []) {
|
||||
PPIR_INSTR_SLOT_END
|
||||
},
|
||||
},
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue