Rhys Perry
d7938de8fe
vulkan/wsi: don't support present with queues where blit is unsupported
...
Since we might have to perform a copy, video and sparse queues cannot be
used to present.
Attempting to create a command buffer on RADV for the sparse binding queue
causes a crash.
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Fixes: 748b7f80ef ("radv: Move sparse binding into a dedicated queue.")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26523 >
2023-12-09 07:37:44 +00:00
Qiang Yu
43d83cfcf9
radeonsi: fix legacy merged LS/ES workgroup size for aco compilation
...
This is for ACO handling of nir_load_local_invocation_index, which will not
add (wave_id * wave_size) if workgroup size <= wave size. So merged shader
LS/ES need to set workgroup size too.
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Signed-off-by: Qiang Yu <yuq825@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26560 >
2023-12-09 06:19:49 +00:00
Marek Olšák
e6b723ccce
mesa: fix _mesa_matrix_is_identity
...
Fixes: d321b1500b - mesa: optimize _mesa_matrix_is_identity
Reviewed-by: Adam Jackson <ajax@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26599 >
2023-12-09 02:08:18 +00:00
Timur Kristóf
8e77da1f21
radv: Implement vkCmdUpdateBuffer on transfer queues.
...
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com >
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26580 >
2023-12-09 01:49:13 +00:00
Timur Kristóf
635c81f723
radv: Implement buffer copies on transfer queues.
...
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com >
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26580 >
2023-12-09 01:49:13 +00:00
Timur Kristóf
a632024700
radv: Implement vkCmdWriteBufferMarker2AMD on transfer queues.
...
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com >
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26580 >
2023-12-09 01:49:13 +00:00
Timur Kristóf
7a4f535145
radv: Implement vkCmdWriteTimestamp2 on transfer queues.
...
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com >
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26580 >
2023-12-09 01:49:13 +00:00
Timur Kristóf
32dd77ea2d
radv: Implement vkCmdFillBuffer on transfer queues.
...
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com >
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26580 >
2023-12-09 01:49:13 +00:00
Timur Kristóf
23590a4e98
radv: Implement barriers for transfer queues.
...
The current flush flags in RADV don't really match the SDMA HW,
so just always emit a NOP packet, for now.
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com >
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26580 >
2023-12-09 01:49:13 +00:00
Juston Li
4f2b4b81d1
venus: fix query feedback copy sanitize off by 1
...
Copy sanitization incorrectly included +1 range of the reset.
Eg Reset Query=0 QueryCount=5 is [0,5) exclusive, not [0,5] inclusive.
Fixes: 5b24ab91e4 ("venus: switch to unconditionally deferred query feedback")
Signed-off-by: Juston Li <justonli@google.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26603 >
2023-12-09 01:32:05 +00:00
Marek Olšák
57e658d041
radeonsi: rework how guardband registers are updated to decrease overhead
...
See the code comments.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:28 +00:00
Pierre-Eric Pelloux-Prayer
2e50b6677b
radeonsi: update guardband if vs_disables_clipping_viewport changes
...
Because the guardband state depends on this value.
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:28 +00:00
Marek Olšák
2f281b39ab
ac/gpu_info: fix printing radeon_info after adding VPE
...
Fixes: 3ec397819e - amd: add new hardware ip for vpe
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:28 +00:00
Marek Olšák
11fcd58957
radeonsi: convert rasterizer state to tracked registers
...
Most of these registers don't change, so we should not set them when they
don't. This reworks the rasterizer state to use a custom emit function and
eliminate redundant register changes. This required merging the poly_offset
state into the rasterizer state and change how the poly offset state is
updated.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
cabf927765
radeonsi: convert depth-stencil-alpha state to tracked registers
...
Some of these registers don't change, so we should not set them when they
don't. This reworks the DSA state to use a custom emit function and
eliminate redundant register changes.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
17e01a9a9b
radeonsi: merge context_reg_saved_mask and other_reg_saved_mask into a BITSET
...
There will be more than 64 context registers that we'll need to track,
so use BITSET for all of them.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
fb994f44d9
util: make BITSET_TEST_RANGE_INSIDE_WORD take a value to compare with
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
6d2a7f53ac
radeonsi: decrease NUM_INTERP if export formats/colormask eliminated PS inputs
...
This adds a pass that removes output stores. It's called before NIR
optimizations that are before PS lowering, which will cause it to remove
PS inputs from register settings.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
bd700bace5
radeonsi: update comments about uniform inlining
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
dbea0f51a3
radeonsi: decrease NUM_INTERP if uniform inlining eliminated PS inputs
...
This should improve performance when that happens.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
1d4402b02a
radeonsi: don't include the PARAM_GEN input in si_shader_info
...
It's only produced by lowering point smoothing.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
197af03698
radeonsi: add PS input info into si_shader_binary_info
...
It will be modified to reflect PS inputs after uniform inlining.
For now, it's just a copy of selector->info.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
3faa9ba06b
radeonsi: gather lowered color inputs for monolithic PS
...
This also adds missing io_semantics to the input loads that the gathering
expects.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
94e0a1267e
radeonsi: change the signature of si_nir_lower_ps_color_input
...
This will be needed later.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
7d2faa88ab
nir,radeonsi: add FLAGS into load_vector_arg_amd to record color input usage
...
This will be needed for gathering color usage from lowered PS.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
00dd4d400e
ac,radeonsi: rename pos_inputs -> fragcoord_components
...
Reviewed-by: Qiang Yu <yuq825@gmail.com >
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
4f2b794e98
radeonsi: track NIR progress properly for optimizations in si_get_nir_shader
...
Just a small code size decrease in 12 shaders.
TOTALS FROM AFFECTED SHADERS (12/58918)
SGPRS: 600.00 -> 600.00 (0.00 %)
VGPRS: 528.00 -> 520.00 (-1.52 %)
Spilled SGPRs: 0.00 -> 0.00 (0.00 %)
Spilled VGPRs: 0.00 -> 0.00 (0.00 %)
Private memory VGPRs: 0.00 -> 0.00 (0.00 %)
Scratch size: 0.00 -> 0.00 (0.00 %) dwords per thread
Code Size: 39772.00 -> 39688.00 (-0.21 %) bytes
Max Waves: 180.00 -> 180.00 (0.00 %)
Outputs: 0.00 -> 0.00 (0.00 %)
Patch Outputs: 0.00 -> 0.00 (0.00 %)
Reviewed-by: Qiang Yu <yuq825@gmail.com >
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
e1e35112c8
winsys/amdgpu: bypass GL2 for command buffers
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
c77bcf00a3
radeonsi/gfx11: prefer Wave64 for VS/TCS/TES/GS because it's slightly faster
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
257f07f499
radeonsi: clean up how debug flags and shader profiles determine the wave size
...
- remove DBG_W32_PS_DISCARD
- just return the wave size instead of setting local variables dbg_wave_size
and profile_wave_size
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
716b521515
radeonsi/gfx11: disable the shader profile for Medical that disables binning
...
GFX11 performs better with the default behavior.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
f85488824e
radeonsi/gfx11: disable the shader profile for Medical that forces Wave64
...
GFX10 should keep using it, but not GFX11.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
65b3b0b355
radeonsi/gfx11: prefer Wave64 for PS without inputs for better VALU perf
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
48ce5fbaa1
radeonsi: group most vertex element fields
...
fix_fetch and vertex_buffer_index can't be grouped because we do
memcmp on those arrays
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
7fa0ee15df
radeonsi: set OOB_SELECT for VBOs in si_create_vertex_elements
...
we can do this since the stride is in the CSO now
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
55d81214c9
radeonsi: replace gl_FrontFacing with a constant if one side is always culled
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
1afe6f3321
radeonsi: don't print the preamble state separately for GALLIUM_DDEBUG
...
because it's always printed as part of command buffers.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
9e76459616
radeonsi: execute streamout_begin after cache flushes
...
so that si_emit_streamout_begin can assume that cache flushes have
finished.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
2022854360
radeonsi/gfx11: skip si_set_streamout_enable because it has no effect
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
bf7debee82
radeonsi: in bind_{blend,rs}_state, only call 1 update function per if
...
Also don't use "key.ps.part.prolog.color_two_side" during updates
because it would depend on the order the update functions are called,
which is not a problem now, but it's a trap for the future.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
53aa36772a
radeonsi: rewrite si_get_total_colormask as si_any_colorbuffer_written
...
The result is only used as bool.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
e2b817b948
radeonsi: rewrite how shader key bits dependent on current_rast_prim are updated
...
Don't set do_update_shaders every time current_rast_prim changes, which can
be EVERY DRAW. Instead, just update the shader key bits and set
do_update_shaders only if any bits are different.
When we bind a new rasterizer state, do the same.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
4ab5374ec3
radeonsi: clean up setting poly/line/stipple shader key bits
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
f9c4ac3477
radeonsi: update shaders for rasterizer state only if the shader key changed
...
Check if any key bit changed before setting do_update_shaders.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
613ea16aab
radeonsi: update shaders for blend state only if the shader key changed
...
Check if any key bit or state changed before setting do_update_shaders.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
c8411ddf17
radeonsi: change the low-priority compiler queue to normal priority
...
I'm guessing that low priority could cause us to get optimized shaders later
than we need.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
98e7a7123b
radeonsi: don't set non-existent VGT_GS_MAX_PRIMS_PER_SUBGROUP on gfx10
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Marek Olšák
f51b960af1
radeonsi/gfx11: fix unaligned SET_CONTEXT_PAIRS_PACKED
...
It set an invalid register. Luckily it didn't cause any issues.
Fixes: 2ac6816b70 - radeonsi/gfx11: use SET_CONTEXT_REG_PAIRS_PACKED for other states
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26307 >
2023-12-09 00:05:27 +00:00
Paulo Zanoni
af65af8267
intel/tools: fix compilation of intel_hang_viewer on 32 bits
...
Because gcc was complaining:
../../src/intel/tools/intel_hang_viewer.cpp: In function ‘void display_hang_stats()’:
../../src/intel/tools/intel_hang_viewer.cpp:365:31: error: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘std::vector<hang_bo>::size_type’ {aka ‘unsigned int’} [-Werror=format=]
365 | ImGui::Text("BOs: %lu", context.bos.size());
| ~~^ ~~~~~~~~~~~~~~~~~~
| | |
| long unsigned int std::vector<hang_bo>::size_type {aka unsigned int}
| %u
../../src/intel/tools/intel_hang_viewer.cpp:366:31: error: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘std::vector<hang_exec>::size_type’ {aka ‘unsigned int’} [-Werror=format=]
366 | ImGui::Text("Execs %lu", context.execs.size());
| ~~^ ~~~~~~~~~~~~~~~~~~~~
| | |
| long unsigned int std::vector<hang_exec>::size_type {aka unsigned int}
| %u
../../src/intel/tools/intel_hang_viewer.cpp:367:31: error: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘std::vector<hang_map>::size_type’ {aka ‘unsigned int’} [-Werror=format=]
367 | ImGui::Text("Maps: %lu", context.maps.size());
| ~~^ ~~~~~~~~~~~~~~~~~~~
| | |
| long unsigned int std::vector<hang_map>::size_type {aka unsigned int}
| %u
cc1plus: some warnings being treated as errors
I'm not sure if STL's size_type is defined by the spec to be anything
specific, but for the platforms we care about it seems to be size_t,
so change it to %z.
Fixes: 33fd93f3b1 ("intel/tools: hang viewer/editor")
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26581 >
2023-12-08 22:53:03 +00:00
Eric Engestrom
b0ad9995d6
v3dv/ci: only trigger on relevant changes
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26597 >
2023-12-08 22:19:50 +00:00