This backend provides very basic a4xx support. It's enough to run
kernels with explicit stg/etc ops, but not with stgb/ldgb type access.
There is no perfcounter support hooked up yet either.
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12784>
With LSC support, we can do 64-bit atomics with A32/64 messages.
Signed-off-by: Sagar Ghuge <sagar.ghuge@intel.com>
Suggested-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12566>
This will let some copy prop happen automatically, avoiding MOVs to temps.
Most importantly, though, it means that virgl won't see (unused channel)
swizzles from channels beyond the bounds of sysvals, which trigger shader
compile failures on the host.
softpipe shader-db:
total instructions in shared programs: 2946336 -> 2934777 (-0.39%)
instructions in affected programs: 374676 -> 363117 (-3.09%)
total temps in shared programs: 565552 -> 564139 (-0.25%)
temps in affected programs: 18138 -> 16725 (-7.79%)
Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12781>
While softpipe and i915 didn't really care, virgl very much does.
tgsi_scan also insisted that the texture ops and the decls matched, which
led to deduplicating the switch statemnts.
Reviewed-by: Rob Clark <robdclark@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12781>
It is not an error when a physical device is filtered out. But it is an
error when a physical device fails to initialize.
Fixed
dEQP-VK.api.device_init.create_instance_device_intentional_alloc_fail.
v2: separate success and fail paths
Fixes: 7dfac808 ("venus: no supported device is not an error")
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org> (v1)
Reviewed-by: Ryan Neph <ryanneph@google.com> (v1)
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12723>
Move device enumeration to a new function.
v2: separate success and fail paths, rename functions
(suggested by Ryan)
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org> (v1)
Reviewed-by: Ryan Neph <ryanneph@google.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12723>
this avoids having the driver bypass the samplerview wrapper and destroying
the samplerview prematurely, e.g., spec@sgis_generate_mipmap@gen-texsubimage
Acked-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12546>
This is required for d3d10+, which has depth_clamp always enabled
regardless of depth_clip (in contrast to OpenGL, where enabling
depth_clamp disables depth_clip). There doesn't seem to be a GL
extension for it, but it will be used for lavapipe to implement
VK_EXT_depth_clip_enable.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12260>
According to ARB_tbo spec, default format is LUMINANCE8, but according
to core spec, it is R8.
This fixes piglit's spec@arb_texture_buffer_object@get test with drivers
supporting ARB_tbo spec but OpenGL/ES < 3.1.
v2:
- Compare against compat profile (Ilia)
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Juan A. Suarez Romero <jasuarez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12774>
Simplify the whole thing:
- keep a single function (grow_vertex_storage) that extends the array
- call it when the array is full (in ATTR_UNION) or at the beginning of
a primitive when the vertex count is known to avoid multiple reallocations.
- allocate save->vertex_store in vbo_save_NewList if needed
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12646>
Simplify the logic by simply growing the primitive array when needed and
remove remove the call to compile_vertex_list in _save_End if the
array is full (it'll be resized later if needed instead).
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12646>
The same property can be deduced directly from the vertex_store,
so remove this one to avoid sync problems between the two and
simplify the code.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12646>
We don't need to store/init a GLvertexformat (3kb) only to handle the
out of memory situation.
Instead, we can call _mesa_noop_vtxfmt_init when needed.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12646>
Same logic that for the primitives: since we're using an intermediate
RAM storage, we don't need to artificially split lists when the buffer
is full.
Instead, we can simply realloc-ate it.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12646>
buffer_map pointed to the first vertex in the store for the current list.
With the previous commit, the first vertex is always at index 0, so we
can drop buffer_map.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12646>
This means that each list will start writing its vertices at index 0.
The previous mode (append) was useful in the past when the vertices
were written directly to a mapped-buffer object.
Now that there's an intermediate storage in RAM, the added complexity
of the append-mode has no value so drop it.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12646>
Now that we don't have links to the prim_store->prims pointers, we
can replace the free/malloc by a realloc version to grow the prim
storage as needed by a list.
This will be used in the next commit to avoid splitting lists in
multiple vbo_save_vertex_list instances because the prim_store was full.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12646>
prim_store won't be shared anymore between multiple list, so use it
directly instead of proxies.
This simplifies the code and avoid to keep them in sync.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12646>
The next commit will refactor buffer upload so we need to decouple
the size from the CPU buffer holding the vertices from the size of
the GPU buffer where we're uploading them.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12646>