broadcom: add no_merge_jobs debug option

To avoid having a custom getenv on v3dv.

Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17609>
This commit is contained in:
Alejandro Piñeiro 2022-07-05 13:04:59 +02:00 committed by Marge Bot
parent bdf23805ab
commit e4d7c3b179
3 changed files with 4 additions and 1 deletions

View File

@ -94,6 +94,8 @@ static const struct debug_named_value debug_control[] = {
{ "cache", V3D_DEBUG_CACHE,
"Print on-disk cache events (only with cache enabled)" },
#endif
{ "no_merge_jobs", V3D_DEBUG_NO_MERGE_JOBS,
"Don't try to merge subpasses in the same job even if they share framebuffer configuration (v3dv only)" },
{ NULL }
};

View File

@ -65,6 +65,7 @@ extern uint32_t V3D_DEBUG;
#define V3D_DEBUG_CL_NO_BIN (1 << 21)
#define V3D_DEBUG_DOUBLE_BUFFER (1 << 22)
#define V3D_DEBUG_CACHE (1 << 23)
#define V3D_DEBUG_NO_MERGE_JOBS (1 << 24)
#define V3D_DEBUG_SHADERS (V3D_DEBUG_TGSI | V3D_DEBUG_NIR | \
V3D_DEBUG_VIR | V3D_DEBUG_QPU | \

View File

@ -853,7 +853,7 @@ physical_device_init(struct v3dv_physical_device *device,
/* Initialize sparse array for refcounting imported BOs */
util_sparse_array_init(&device->bo_map, sizeof(struct v3dv_bo), 512);
device->options.merge_jobs = getenv("V3DV_NO_MERGE_JOBS") == NULL;
device->options.merge_jobs = !(V3D_DEBUG & V3D_DEBUG_NO_MERGE_JOBS);
device->drm_syncobj_type = vk_drm_syncobj_get_type(device->render_fd);