This depends on batch state, so emit in gmem code. The remainder of the
static reg initialization can be re-used across batches.
Signed-off-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30544>
We have a few different command streams we create at startup. Simplify
the initialization by creating a single sub_cs to allocate all of the
cs's out of and inlining structures where appropriate.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30544>
While the register is constant for all bins in the render pass, it is
not saved and restored with level 1 preemption with skipsaverestore=1 so
it needs to be restored. Follow what the blob does and set it before
each bin.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30544>
Add USES_GMEM flag to indicate that GMEM is in use, so that preemption can
know it needs save and restore GMEM contents.
The missing BIN_RENDER_END markers are also added, their purpose is to
clear the USES_GMEM flag once GMEM is no longer in use.
Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30544>
Use real names for most of a6xx_marker enum, add USES_GMEM, remove
overlapping bitfields.
Note the actual "real names" start with PM4_RENDER_MODE_ instead of RM6_
This is a small change to adreno_pm4.xml, with the corresponding
find/replace and updated ci references
Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30544>
This gives logs of the form:
[bootanimation] Fence: bbq-adapter#0(BLAST Consumer:0, status: 1, timestamp (ms): 15391
sync_merge(..) allows userspace to name the fence
and that's what's observed for in-fences. The goal
is debug potentially long-running fences via the
use of timestamp data.
Perfetto may be used too.
Acked-by: Yonggang Luo <luoyonggang@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31548>
Clearing VK_FORMAT_R8G8_* with fast-clear value and certain
dimensions (e.g. 960x540), and having GMEM renderpass afterwards
may lead to a GPU fault on A7XX.
Prop driver directly clears UBWC layers for R8G8_UNORM, and
doesn't use UBWC for R8G8_UINT. It uses generic clear for R8G8 only
for renderpass, where doesn't cause issues in Turnip.
Fixes GPU fault in Limbo game running via Zink.
Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31258>
Starting with Linux v6.11+, performance counter information is no
longer duplicated in both the kernel and userspace. Instead, an IOCTL
retrieves this information, allowing userspace to maintain a local
array for reuse, thus avoiding redundant kernel queries.
However, support for older kernels without these new IOCTLs remains.
To distinguish between versions, we check `devinfo->max_perfcnt` -
which is non-zero on Linux v6.11+ and zero on older kernels.
Currently, applications using performance queries on platforms with
older kernels encounter a SEGFAULT, as we don't validate
`devinfo->max_perfcnt` before accessing the userspace array for
performance counter information.
This commit makes sure that, if `devinfo->max_perfcnt` is zero,
`screen->perfcnt_names` will be NULL. This way, we can check if
`screen->perfcnt_names` is different than NULL before attempting to use
the userspace array.
Fixes: 017dde0d1c ("v3d: Use DRM_IOCTL_V3D_GET_COUNTER to get perfcnt information")
Signed-off-by: Maíra Canal <mcanal@igalia.com>
Reviewed-by: Juan A. Suarez <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31552>
Check if the block size is bigger then 64. We want to block
e.g. one of the following formats:
- R32G32B32A32_FLOAT
- R32G32B32A32_SINT
- R32G32B32A32_ZINT
Unbreaks e.g. dEQP-GLES3.functional.fbo.completeness.renderable.texture.color0.rgb16i
Fixes: e481c1269c ("etnaviv: disable 64bpp render/sampler formats")
Signed-off-by: Christian Gmeiner <cgmeiner@igalia.com>
Reviewed-by: Lucas Stach <l.stach@pengutronix.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27111>
Preprocess now must use the same conditional rendering state as the
execute, so the DGC prepare shader must reset the number of sequences
to generate an empty cmdbuf for compute.
Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31563>
Shader load/stores are cached by the shader L1 cache. As UBOs on etnaviv
are implemented as regular loads from the constant buffer, this cache
needs to be flushed whenever the content of a constant buffer is modified.
Fixes most of the currently failing dEQP-GLES3.functional.ubo.* on GC3000.
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Christian Gmeiner <cgmeiner@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31527>
These should be included according to table in Bspec 43904.
Patch removes PIPE_CONTROL_STATE_CACHE_INVALIDATE based on HSDES.
Cc: mesa-stable
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29764>