Marek Olšák
5f090891e9
radeonsi: simplify si_emit_spi_map for back-face colors
...
Just precompute what we need in si_shader_info.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
57f9452b46
radeonsi: precompute num_interp for si_emit_spi_map
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
46802f7b60
radeonsi: interleave si_shader_info::input_* in memory for faster emit_spi_map
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
11d1309d82
radeonsi: restructure si_get_ps_input_cntl for future refactoring
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
b59bb9c07a
radeonsi: force flat for PrimID early in si_nir_scan_shader
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
5cdbbcc2ab
radeonsi: eliminate a not-found conditional for PrimID in si_get_ps_input_cntl
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
3ea3621b8d
radeonsi: determine num_vbos_in_user_sgprs from template arguments in draw_vbo
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
a65f99b2d1
radeonsi: deduplicate si_compiler_ctx_state initialization
...
to remove it from si_update_shaders
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
7a20110ad3
radeonsi: precompute si_vgt_stages_key for NGG in si_shader
...
to remove this overhead from si_update_shaders
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
5a131566b1
radeonsi: move flat shading VRS enablement out of si_update_shaders
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
eed149aa7c
radeonsi: move DB_SHADER_CONTROL update for PS out of si_update_shaders
...
It only depends on the pixel shader CSO and alpha test.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
70220a1896
radeonsi: check flatshade and sprite_coord_enable for spi_map in bind_rs_state
...
it doesn't need to be in si_update_shaders
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
2dfe01db01
radeonsi: optimize scratch buffer size updates using C++ template arguments
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
98d07e1928
radeonsi: make si_update_shaders a C++ template in si_state_draw.cpp
...
This reduces driver overhead.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
dff6dc0316
radeonsi: unset SI_PREFETCH_* only when we unbind pm4 shader states
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
76fe6a0242
radeonsi: move PS inputs_read computation out of si_get_vs_key_outputs
...
to reduce overhead of si_update_shaders
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
35a42377cd
radeonsi: move si_shader_io_get_unique_index calls out of si_get_vs_key_outputs
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
6d1ab77a8f
radeonsi: rewrite inlinable uniform states for shader keys in si_context
...
directly update the shader keys in si_context
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
aed93eb991
radeonsi: update the VS shader key in set & bind functions and remove memsets
...
This decreases overhead of si_update_shaders and overall driver overhead.
The VS shader key portion related to VS inputs is updated in set & bind
functions. Other fields related to outputs are still updated
in si_shader_selector_key.
Now that all modified fields are set to 0 when not needed, and remove
the memsets.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
74a0c9bd51
radeonsi: clean up and clear VS shader key fields related to outputs
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
dbdde903bb
radeonsi: update most of the PS shader key in set & bind functions
...
This decreases overhead of si_update_shaders and overall driver overhead.
There is only one function that depends on the rasterized primitive type,
and thus it can't be moved to set & bind functions.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
7e3c03bc6a
radeonsi: ignore blitter when computing the PS shader key
...
it doesn't have any effect
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
00d1d947ea
radeonsi: divide si_update_ps_shader_key into many separate functions
...
they will be used in bind functions etc.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
59072ee484
radeonsi: don't memset part in si_update_ps_shader_key
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
60580c04c0
radeonsi: don't memset mono and opt in si_update_ps_shader_key
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
46bda71a54
radeonsi: move PS shader key code into a separate function
...
There is reordering and new comments.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
a912c80439
radeonsi: sink memsets and disable uniform inlining in si_shader_selector_key
...
to facilitate refactoring. Uniform inlining will be re-enabled later.
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
0b1fd84950
radeonsi: handle NO_OPT_VARIANT in si_shader_select_with_key
...
so as not to change the keys in si_context
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Marek Olšák
03b5a94258
radeonsi: add const to the key parameter in si_shader_select_with_key
...
The keys will match the current state, so we shouldn't change them.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12343 >
2021-09-14 15:24:11 +00:00
Mike Blumenkrantz
361a7d2451
compiler/spirv: add a fail if tex instr coord components aren't dimensional enough
...
this is really hard to pin down later on, so catch it here instead
gotta have those dimensions.
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12825 >
2021-09-14 13:54:24 +00:00
Charlie Turner
c38318aee2
radv/ci: Fix the GPU_VERSION for polaris10
...
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11426 >
2021-09-14 11:31:26 +00:00
Charlie Turner
b75dc87762
radv/ci: Remove duplication in dEQP skip lists.
...
Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Martin Peres <martin.peres@mupuf.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11426 >
2021-09-14 11:31:26 +00:00
Charlie Turner
852904e9fd
ci: Support per-driver skip lists.
...
In addition to a global skip list introduced in
https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11333
(enabled by
https://gitlab.freedesktop.org/anholt/deqp-runner/-/merge_requests/4 )
it is also useful to have a per-driver skip list in addition to a
per-gpu list. Now, there are multiple levels at which skips can be
specified, from least to most specific,
- (deqp|piglit)-all-skips.txt :: affecting all tests
- (deqp|piglit)-$(DRIVER_NAME|VK_DRIVER|GALLIUM_DRIVER)-skips.txt ::
affecting the specified driver
- (deqp|piglit)-$GPU_VERSION-skips.txt :: affecting a specific GPU
This idea could be useful for -fails.txt as well.
Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Martin Peres <martin.peres@mupuf.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11426 >
2021-09-14 11:31:26 +00:00
Connor Abbott
e43797ab13
freedreno, turnip: Disable 8bpp UBWC on a650
...
While it doesn't immediately hang like on a660, it seems to be buggy and
the blob disables it.
This fixes a bunch of r8_* dEQP-VK tests, which seem to pass
individually but don't work when run after other tests. For example this
fixes failures running dEQP-VK.pipeline.sampler.*.r8_uint*.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12830 >
2021-09-14 11:11:39 +00:00
Tomeu Vizoso
f86517be7f
panfrost/ci: Enable test runs on G72
...
Looks pretty stable now!
Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
Acked-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12850 >
2021-09-14 12:39:41 +02:00
Danylo Piliaiev
b1eb088792
turnip/kgsl: fix compilation after perfetto introduction
...
Perfetto isn't supported with kgsl at the moment. Make stubs for
missing functions.
Fixes: 3dd1bb6355 "turnip: implement basic perfetto support"
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/5352
Signed-off-by: Danylo Piliaiev <dpiliaiev@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12837 >
2021-09-14 09:34:45 +00:00
Kenneth Graunke
1cd868f105
iris: Add some accessor wrappers for a few fields.
...
In the future, we're going to have "real" BOs representing GEM objects,
and "slab allocated" BOs suballocated out of a larger BO. Many fields
are properties of the real underlying BO, but we may still want to ask
about an arbitrary BO, and have the accessor chase answers down as
necessary.
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12848 >
2021-09-14 07:36:44 +00:00
Kenneth Graunke
e4c3d3efc7
iris: Defer construction of the validation (exec_object2) list
...
When I wrote this code originally, I decided to try and construct the
validation list up front, rather than at submission time. That worked
okay, but it's not really necessary. It's a fair amount of data to
store (struct drm_i915_gem_exec_object2 is 56 bytes per object), when
we can easily construct it on the fly.
More importantly, with suballocation, batch->exec_bos[i] may have
multiple entries corresponding to a single validation list entry.
Rather than tracking two lists with an awkward mapping between them,
we choose to just store the BO list and generate the other on the fly.
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12848 >
2021-09-14 07:36:44 +00:00
Kenneth Graunke
2f0eccf647
iris: Track written BOs via a bitfield rather than exec_object2 entries
...
When we start suballocating BOs, multiple logical BOs may map to the
same GEM object, and thus share a validation list entry. However, we
want to track whether logical BOs are written, to avoid unnecessary
cross-batch data dependencies.
Just track that in a bitfield instead, where bit i corresponds to
batch->exec_bos[i].
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12848 >
2021-09-14 07:36:44 +00:00
Kenneth Graunke
795b14aaa3
iris: Rewrite bo->index comment to refer to exec_bos[]
...
batch->validation_list[] will be going away shortly, but exec_bos[]
will live on. bo->index is the index into both lists, so we can just
refer to the one we're not about to delete.
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12848 >
2021-09-14 07:36:44 +00:00
Dave Airlie
4149a60209
crocus/gen7: add missing IVB/GT2 geom shader workaround.
...
Noticed this in passing.
Fixes: f3630548f1 ("crocus: initial gallium driver for Intel gfx 4-7")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12847 >
2021-09-14 07:03:36 +00:00
Mike Blumenkrantz
be35fdae5f
zink: add some debug asserts to validate imageless framebuffer correctness
...
not sure if these matter enough to assert on but they're annoying to track down
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12843 >
2021-09-14 05:47:47 +00:00
Mike Blumenkrantz
0734484058
zink: update surface info when rebinding to storage
...
fixes some validation for imageless framebuffer usage
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12843 >
2021-09-14 05:47:47 +00:00
Mike Blumenkrantz
ad57bb1b7d
zink: force imageless fb rebind if rebinding an attachment
...
ensure that the STORAGE usage gets picked up here
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12843 >
2021-09-14 05:47:47 +00:00
Mike Blumenkrantz
372f7d4726
zink: be smarter about fb surface rebinds
...
the aspect info lets us avoid unnecessary comparisons
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12843 >
2021-09-14 05:47:47 +00:00
Mike Blumenkrantz
46a262dc1e
zink: wrap framebuffer surfaces to preserve gallium expectations
...
gallium needs pipe_surface::context to reflect the context used to create
the surface, but zink caches surfaces, so instead return a wrapper object
that can be destroyed without blowing up the stack
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12843 >
2021-09-14 05:47:47 +00:00
Mike Blumenkrantz
01f00eb90d
zink: move surface and bufferview caches onto resources
...
this makes the locking smaller in scope and also make the lookups faster
due to having smaller populations in the hash tables
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12843 >
2021-09-14 05:47:47 +00:00
Mike Blumenkrantz
e28df76c3a
zink: add a resource reference for bufferviews
...
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12843 >
2021-09-14 05:47:47 +00:00
Mike Blumenkrantz
32cf036cb7
zink: assert surface geometry
...
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12843 >
2021-09-14 05:47:47 +00:00
Jordan Justen
333b2185d8
intel/isl: Enable MOCS 61 for external surfaces on TGL
...
Reworks:
* Lionel/Francisco: Add comment
Cc: mesa-stable
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12292 >
2021-09-14 05:33:53 +00:00