aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* aco: add helpers for splitting storesRhys Perry2020-04-241-0/+155
| | | | | | | | | | | | | | split_store_data() splits a vector and p_as_uniforms it if needed. scan_write_mask()/advance_write_mask() are similar to u_bit_scan_consecutive_range(), but makes it easier to only clear part of the range and will also give ranges for zero'd bits. split_buffer_store() is a helper for splitting VMEM/SMEM stores. Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4639>
* aco: use emit_load helper for VMEM/SMEM loadsRhys Perry2020-04-241-494/+226
| | | | | | | | Also implements 8/16-bit loads for scratch/global. Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4639>
* aco: refactor load_lds to use new helpersRhys Perry2020-04-241-98/+75
| | | | | | Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4639>
* aco: add emit_load helperRhys Perry2020-04-241-0/+285
| | | | | | | | | | This helper is used for recombining split loads, passing the result to p_as_uniform, aligning the offset down and shifting it right if needed and handling large constant offsets. Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4639>
* aco: add and use RegClass::get() helperRhys Perry2020-04-242-14/+12
| | | | | | | | | | | | Eventually, we'll probably want to replace the current RegClass(type, size) constructor with this. This has a functional change in that get_reg_class() now creates v1/v2 instead of v4b/v8b. Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4639>
* aco: be more careful about using SMEM for load_globalRhys Perry2020-04-241-3/+4
| | | | | | Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4639>
* radv: allocate larger shader memory slabs if neededRhys Perry2020-04-241-2/+2
| | | | | | | | | Fixes dEQP-VK.ssbo.phys.layout.random.16bit.scalar.13 hang with ACO (features needed for the test are implemented in a later commit) Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Samuel Pitoiset <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4639>
* radv: align buffer descriptor sizes to dwordRhys Perry2020-04-242-2/+16
| | | | | | | | | This is needed to prevent bounds checking issues when load 8/16-bit values with dword loads. Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Samuel Pitoiset <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4639>
* aco: Move s_setprio to correct place after the gs_alloc_req.Timur Kristóf2020-04-241-2/+3
| | | | | | | | | Previously the setprio was inside the branch, so it would only reset the priority on the first wave, but not the others. Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4536>
* aco: Use 24-bit multiplication for NGG wave id and thread id.Timur Kristóf2020-04-241-2/+2
| | | | | | | | Both of them should always fit 24 bits anyway. Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4536>
* aco: Use 24-bit multiplication in TCS I/OTimur Kristóf2020-04-241-5/+5
| | | | | | | | | | | | | The TCS inputs and outputs must always fit into the LDS, which implies that their addresses also always fit 24 bits. On AMD GPUs, 24-bit multiplication is much faster than 32-bit multiplication, so we can take the opportunity to use that for TCS I/O instead. Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4536>
* aco: Const correctness for aco_print_ir.Timur Kristóf2020-04-242-26/+26
| | | | | | Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4536>
* aco: Const correctness for get_barrier_interaction.Timur Kristóf2020-04-242-11/+11
| | | | | | Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4536>
* aco: Abort when RA can't find a register.Timur Kristóf2020-04-241-1/+2
| | | | | | | | | | | | | Previously, it was just unreachable, which means it will generate invalid shaders when it encounters a situation when it can't allocate registers for eg. a large load. This commit makes it slightly easier to notice such problems without triggering a GPU hang. Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4536>
* aco: Increase barrier_count to 7 to include barrier_barrier.Timur Kristóf2020-04-241-1/+1
| | | | | | Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4536>
* aco: Only store TCS outputs to VMEM when they are read by TES.Timur Kristóf2020-04-241-12/+26
| | | | | | | | | Totals from affected shaders (GFX10): Code Size: 10832 -> 10736 (-0.89 %) bytes Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4536>
* radv: Add inputs read by TES to radv_shader_info.Timur Kristóf2020-04-242-0/+9
| | | | | | | Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Samuel Pitoiset <[email protected]> Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4536>
* turnip: add adreno 650Jonathan Marek2020-04-244-22/+46
| | | | | | | Tile alignment is 96, with gmem alignment of 0x6000 Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4608>
* turnip: use RESOLVE_TS eventJonathan Marek2020-04-241-1/+1
| | | | | | | This is required on a650 to flush the GMEM store. Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4608>
* turnip: remove unused RB_UNKNOWN_8E04_blitJonathan Marek2020-04-242-3/+0
| | | | | | | | New blit code doesn't change this value, and different values seem to be related to the driver version and not the GPU version. Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4608>
* zink: set UBO alignments in nir_intrinsic_load_uniform loweringMike Blumenkrantz2020-04-241-0/+2
| | | | | | | | | | | | resolves this error error: nir_intrinsic_align_offset(instr) < nir_intrinsic_align_mul(instr) (../src/compiler/nir/nir_validate.c:582) in ext_packed_depth_stencil-readdrawpixels piglit test port of f5b14d983e5afa1b8f75e6f3692830a1ee46d1df Fixes: fb64954d9dd ("nir: Validate that memory load/store ops work on whole bytes") Reviewed-by: Erik Faye-Lund <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4711>
* freedreno: allow FMT6_8_UNORM as a UBWC formatFritz Koenig2020-04-241-0/+1
| | | | | | FMT6_8_UNORM is necessary for NV12 textures. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4722>
* spirv: Rewrite CFG constructionJason Ekstrand2020-04-242-294/+503
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit completely rewrites the way we extract a structured CFG from SPIR-V. The new approach is different in a few ways: 1. It does a breadth-first search instead of depth-first. This means that we've visited the merge node for a construct before we visit any of the nodes inside the construct. This makes it easier to validate things like loop and switch nesting. 2. We record more information in the CFG. Earlier commits added a parent pointer to vtn_cf_node but we now record all of the merge and other special blocks for each CFG node. This lets us validate things more precisely. 3. It makes heavy use of merge blocks for walking the CFG. Previously, we sort of used them as hints for trying to guess the CFG structure but things got dicey whenever a merge was missing. We had some heuristics for how to handle short-circuiting if statements but it was a bunch of special cases. Now, we make them a fundamental part of walking the CFG. When we encounter a control-flow construct, we add the body components of the construct to the BFS work list and then jump to the merge block if one exists to continue scanning the current CFG nesting level. If no merge block exists, we assume that means that control-flow never re-converges in a normal way and that the only way to get back to normality is with a direct jump such as a loop break or continue. This should make things far more robust when trying to deal with the more creative placement (or lack thereof) of merge instructions. Reviewed-by: Alan Baker <[email protected]> Reviewed-by: Caio Marcelo de Oliveira Filho <[email protected]> Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3820> Closes: #2760 Acked-by: Samuel Pitoiset <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4446>
* anv: Add support for HiZ+CCSJason Ekstrand2020-04-242-2/+40
| | | | | Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* intel/isl: Refactor isl_surf_get_ccs_surfJason Ekstrand2020-04-242-139/+178
| | | | | | | | | This refactor breaks out a new isl_surf_supports_ccs function which does most of the validity checking. The isl_surf_get_ccs_surf function calls this function and then dives right into constructing the CCS aux_surf. Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* intel/isl: Delete a misleading commentJason Ekstrand2020-04-241-3/+0
| | | | | | | | Untyped messages are only use on Gen9+ for UBOs and SSBOs. They will never be used on anything using an isl_surf. Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* anv/cmd_buffer: Move anv_image_init_aux_tt higherJason Ekstrand2020-04-241-99/+99
| | | | | Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* anv: Simplify a case in layout_to_aux_usageJason Ekstrand2020-04-241-6/+1
| | | | | | | | If it's depth, the only possible value of planes[plane].aux_usage is ISL_AUX_USAGE_HIZ at least right now. Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* intel/blorp: Allow more HiZ usages in hiz_clear_depth_stencilJason Ekstrand2020-04-241-1/+1
| | | | | Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* anv: Generalize some aux usage checksJason Ekstrand2020-04-242-6/+7
| | | | | | | | | For the checks dealing with fast-clear values, we change them to check for the depth aspect because the distinction there really is between color and depth more than between HiZ and CCS. Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* anv/blorp: Do less hard-coding of aux usagesJason Ekstrand2020-04-241-5/+9
| | | | | Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* anv: Rework anv_layout_to_aux_stateJason Ekstrand2020-04-241-73/+81
| | | | | Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* anv: Be more conservative about image view usageJason Ekstrand2020-04-241-5/+32
| | | | | | | | | We were ORing together the image and stencil usage rather than actually following the formula in the spec. This can lead to assertions in other parts of the driver if we're not careful. Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* anv: Move vk_image_layout_is_read_only higherJason Ekstrand2020-04-241-44/+44
| | | | | | | While we're at it, we drop some _KHR suffixes Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* anv: Add a vk_image_layout_to_usage_flags helperJason Ekstrand2020-04-241-0/+109
| | | | | Reviewed-by: Rafael Antognolli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4100>
* anv: Enable HiZ on multi-layer depth buffers.Rafael Antognolli2020-04-242-11/+11
| | | | | | | | Improves The Witcher 3 fps by 2-10% on ICL (depending on the configs and system). Reviewed-by: Jason Ekstrand <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4661>
* etnaviv: support for using generic blit pathChristian Gmeiner2020-04-244-59/+51
| | | | | | Signed-off-by: Christian Gmeiner <[email protected]> Reviewed-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/1641>
* etnaviv: call util_blitter_save_fragment_constant_buffer_slot(..)Christian Gmeiner2020-04-241-0/+2
| | | | | | Signed-off-by: Christian Gmeiner <[email protected]> Reviewed-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/1641>
* etnaviv: drop default state for FE_HALTI5_ID_CONFIGChristian Gmeiner2020-04-241-1/+0
| | | | | | | | It gets emitted when needed - see emit_halti5_only_state(..). Signed-off-by: Christian Gmeiner <[email protected]> Reviewed-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4729>
* docs/features: mark GL_ARB_texture_filter_anisotropic as done for etnavivChristian Gmeiner2020-04-241-1/+1
| | | | | | | | Needs GPUs with HALT0. Signed-off-by: Christian Gmeiner <[email protected]> Reviewed-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4725>
* freedreno/ir3: fix incorrect conversion foldingJonathan Marek2020-04-241-0/+7
| | | | | | | Fixes dEQP-VK.glsl.builtin.function.pack_unpack.unpackhalf2x16_compute Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4708>
* freedreno/ir3: set even bit for f2f16_rtneJonathan Marek2020-04-241-2/+7
| | | | | Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4708>
* freedreno/ir3: fix 16-bit ssbo accessJonathan Marek2020-04-243-5/+12
| | | | | | | Update cat6 instruction type, and shift 1 in lower_offset_for_ssbo. Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4708>
* aco: fix outdated label_vec from p_create_vector labellingRhys Perry2020-04-241-3/+5
| | | | | | | | | | | Fixes random dEQP-VK.transform_feedback.fuzz.* crashes. Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Fixes: 2dc550202e82c5da198ad0a416a5d24dd89addd8 ('aco: copy-propagate p_create_vector copies of vectors') Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4730>
* nir/lower_subgroups: Mask off unused bits in ballot opsJason Ekstrand2020-04-241-0/+26
| | | | | | | | | Thanks to VK_EXT_subgroup_size_control, we can end up with gl_SubgroupSize being as low as 8 on Intel. Fixes: d10de253097 "anv: Implement VK_EXT_subgroup_size_control" Reviewed-by: Caio Marcelo de Oliveira Filho <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4694>
* anv: Drop an assertJason Ekstrand2020-04-241-1/+0
| | | | | | | | | Ever since Vulkan 1.2, this feature has been in core so enabling the extension is no longer required. Fixes: 4ef3f7e3d37e "anv: Enable Vulkan 1.2 support" Reviewed-by: Caio Marcelo de Oliveira Filho <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4694>
* radeonsi: use pipe_blend_state::max_rt to update fewer blend registersMarek Olšák2020-04-241-3/+7
| | | | | Reviewed-by: Pierre-Eric Pelloux-Prayer <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4698>
* ac,radeonsi: simplify checking for Navi1x chipsMarek Olšák2020-04-245-21/+10
| | | | | | Reviewed-by: Samuel Pitoiset <[email protected]> Reviewed-by: Pierre-Eric Pelloux-Prayer <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4698>
* ac: out-of-order rasterization is not supported on gfx10Marek Olšák2020-04-241-0/+1
| | | | | | Reviewed-by: Samuel Pitoiset <[email protected]> Reviewed-by: Pierre-Eric Pelloux-Prayer <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4698>
* turnip: divide cube map depth by 6Jonathan Marek2020-04-241-2/+12
| | | | | | | | | This matches the GL driver and fixes these tests: dEQP-VK.glsl.texture_functions.query.texturesize.samplercubearray* Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4709>