mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 21:58:20 +02:00
radv: fix overflow when computing the SQTT buffer size
With RADV_THREAD_TRACE_BUFFER_SIZE=1073741824, the computed size
will overflow and be 4096 instead of 4294967296.
Cc: <mesa-stable@lists.freedesktop.org>
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8616>
(cherry picked from commit c40ea24ee0)
This commit is contained in:
parent
31ef7441cd
commit
acfd179fe3
2 changed files with 2 additions and 2 deletions
|
|
@ -139,7 +139,7 @@
|
|||
"description": "radv: fix overflow when computing the SQTT buffer size",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"master_sha": null,
|
||||
"because_sha": null
|
||||
},
|
||||
|
|
|
|||
|
|
@ -477,7 +477,7 @@ radv_thread_trace_init_bo(struct radv_device *device)
|
|||
/* Compute total size of the thread trace BO for 4 SEs. */
|
||||
size = align64(sizeof(struct ac_thread_trace_info) * 4,
|
||||
1 << SQTT_BUFFER_ALIGN_SHIFT);
|
||||
size += device->thread_trace.buffer_size * 4;
|
||||
size += device->thread_trace.buffer_size * 4ll;
|
||||
|
||||
device->thread_trace.bo = ws->buffer_create(ws, size, 4096,
|
||||
RADEON_DOMAIN_VRAM,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue