summaryrefslogtreecommitdiffstats
path: root/src/amd
Commit message (Collapse)AuthorAgeFilesLines
* radv: Fix up 2_10_10_10 alpha sign.Bas Nieuwenhuizen2018-05-144-13/+98
| | | | | | | | | | | | Pre-Vega HW always interprets the alpha for this format as unsigned, so we have to implement a fixup to do the sign correctly for signed formats. v2: Improve indexing mess. CC: 18.0 18.1 <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=106480 Reviewed-by: Samuel Pitoiset <[email protected]>
* radv: Add support for IMG_DATA_FORMAT_32_32_32.Bas Nieuwenhuizen2018-05-143-4/+11
| | | | | | | | | | Basic sampling support for linear tiling. No CTS regressions, but it seems the blitting coverage is not very extensive. https://bugs.freedesktop.org/show_bug.cgi?id=106331 Reviewed-by: Samuel Pitoiset <[email protected]>
* radv: Translate logic ops.Bas Nieuwenhuizen2018-05-142-30/+59
| | | | | | | | | | | radeonsi could pass them through but the enum changed between Gallium and Vulkan, so we have to translate. In progress I made the register defines a bit more readable. CC: 18.0 18.1 <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=100430 Reviewed-by: Samuel Pitoiset <[email protected]>
* radv: Fix multiview queries.Bas Nieuwenhuizen2018-05-141-19/+20
| | | | | | | | | | | | | | | | | This moves the extra queries to after the main query ended, instead of doing it after the begin and hence doing nesting. We also emit only (view count - 1) extra queries, as the main query is already there for the first view. This fixes the CTS occasionally getting stuck in dEQP-VK.multiview.queries* waiting on results. Fixes: 32b4f3c38dc "radv/query: handle multiview queries properly. (v3)" CC: 18.1 <[email protected]> Reviewed-by: Dave Airlie <[email protected]> Reviewed-by: Samuel Pitoiset <[email protected]>
* radv: remove useless check in radv_create_shaders()Samuel Pitoiset2018-05-141-1/+1
| | | | | | | radv_can_dump_shader() already handles if module is NULL. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Timothy Arceri <[email protected]>
* radv: allow to dump the GS copy shader with RADV_DEBUG="shaders"Samuel Pitoiset2018-05-143-5/+8
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Timothy Arceri <[email protected]>
* radv: move {load,store}_var intrinsics scanning in different functionsSamuel Pitoiset2018-05-141-47/+80
| | | | | | | | These are going to be crazy and we are probably going to add more scan stuff in the future. Also use switch cases instead. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Timothy Arceri <[email protected]>
* radv: use compute path for multi-layer images.Dave Airlie2018-05-141-0/+2
| | | | | | | | | | | I don't think the hw resolve path can't handle multi-layer images. This fixes all the: dEQP-VK.renderpass.multisample_resolve.layers_* tests on my VI card. Reviewed-by: Bas Nieuwenhuizen <[email protected]> Cc: <[email protected]>
* radv: resolve all layers in compute resolve path.Dave Airlie2018-05-141-6/+42
| | | | | | | | | | | This path should iterate across all layers, I've some ideas for doing this in a single pass, but this is simpler for now. This passes the tests because we don't use the fragment path unless we have DCC, and we don't have DCC on layered images. Reviewed-by: Bas Nieuwenhuizen <[email protected]> Cc: <[email protected]>
* radv/resolve: do fmask decompress on all layers.Dave Airlie2018-05-141-1/+1
| | | | | | | | For a multi-layer subpass resolve we want to make sure we flush all the layers. Reviewed-by: Bas Nieuwenhuizen <[email protected]> Cc: <[email protected]>
* radv: add initial support for VK_PIPELINE_CREATE_DISABLE_OPTIMIZATION_BITTimothy Arceri2018-05-134-16/+28
| | | | | | | | | | | | | | | | | | | When VK_PIPELINE_CREATE_DISABLE_OPTIMIZATION_BIT is set we skip NIR linking optimisations and only run over the NIR optimisation loop once similar to the GLSLOptimizeConservatively constant used by some GL drivers. We need to run over the opts at least once to avoid errors in LLVM (e.g. dead vars it can't handle) and also to reduce the time spent compiling the IR in LLVM. With this change the Blacksmith Unity demos compilation times go from 329760 ms -> 299881 ms when using Wine and DXVK. V2: add bit to radv_pipeline_key Reviewed-by: Bas Nieuwenhuizen <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=106246
* radv: move ac_build_if_state on top of radv_nir_to_llvm.cSamuel Pitoiset2018-05-111-91/+92
| | | | | | | These helpers will be needed for future work. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Timothy Arceri <[email protected]>
* radv: minor cleanups in radv_fill_shader_variant()Samuel Pitoiset2018-05-111-14/+15
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Timothy Arceri <[email protected]>
* ac/gpu_info: add has_read_registers_queryMarek Olšák2018-05-102-0/+3
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add has_2d_tilingMarek Olšák2018-05-102-0/+3
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add has_sparse_vm_mappingsMarek Olšák2018-05-102-0/+9
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add has_unaligned_shader_loadsMarek Olšák2018-05-102-0/+4
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add has_indirect_compute_dispatchMarek Olšák2018-05-102-0/+3
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add kernel_flushes_tc_l2_after_ibMarek Olšák2018-05-102-0/+5
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add has_format_bc1_through_bc7Marek Olšák2018-05-102-0/+3
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add has_eqaa_surface_allocatorMarek Olšák2018-05-102-2/+5
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* radeonsi: clean up the reset status query implementationMarek Olšák2018-05-102-0/+6
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add has_bo_metadataMarek Olšák2018-05-102-0/+3
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add si_TA_CS_BC_BASE_ADDR_allowedMarek Olšák2018-05-102-0/+3
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add htile_cmask_support_1d_tilingMarek Olšák2018-05-102-0/+3
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/gpu_info: add kernel_flushes_hdp_before_ibMarek Olšák2018-05-102-0/+3
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/surface: add EQAA supportMarek Olšák2018-05-103-3/+30
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/surface: unify common legacy and gfx9 fmask fieldsMarek Olšák2018-05-103-23/+19
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/surface/gfx6: compute FMASK together with the color surfaceMarek Olšák2018-05-103-59/+94
| | | | | | instead of invoking FMASK computation separately. Reviewed-by: Nicolai Hähnle <[email protected]>
* ac/surface/gfx9: fix a typo in CMASK RB/pipe alignmentMarek Olšák2018-05-101-1/+1
| | | | | | No change in behavior because it's always aligned. Reviewed-by: Nicolai Hähnle <[email protected]>
* ac: set correct LLVM processor names for Raven & Vega12Marek Olšák2018-05-101-2/+4
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac: sort raster configsMarek Olšák2018-05-101-39/+27
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac: remove 1 RB raster config for IcelandMarek Olšák2018-05-101-5/+1
| | | | | | Iceland always reports 2 RBs. Reviewed-by: Nicolai Hähnle <[email protected]>
* ac: move the Fiji kernel workaround for raster config out of the switchMarek Olšák2018-05-101-8/+11
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* ac: enable both RBs on KaveriMarek Olšák2018-05-101-2/+13
| | | | | | | | | This can result in 2x increase in performance on non-harvested Kaveris. v2: don't do it on radeon Tested-by: Michel Dänzer <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]>
* radv: disable DCC for shareable images on GFX9+Andres Rodriguez2018-05-101-0/+7
| | | | | | | This seems to be broken at the moment for opengl interop. Signed-off-by: Andres Rodriguez <[email protected]> Reviewed-by: Samuel Pitoiset <[email protected]>
* radv: move handling nosisched option in a better placeSamuel Pitoiset2018-05-101-12/+6
| | | | | | | | It's a per-application optimization, so it makes more sense to do that in radv_handle_per_app_options(). Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* radv: assorted typo fixesGrazvydas Ignotas2018-05-106-11/+11
| | | | | | Trivial. Reviewed-by: Samuel Pitoiset <[email protected]>
* radv: handle arrays in the fmask descriptor.Dave Airlie2018-05-101-1/+1
| | | | | | This fixes the fmask descriptor generation to handle 2d ms arrays. Reviewed-by: Samuel Pitoiset <[email protected]>
* amd/common: use llvm.amdgcn.wqm for explicit derivativesNicolai Hähnle2018-05-041-0/+7
| | | | | | | To comply with an upcoming change in LLVM, see https://reviews.llvm.org/D46051 Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* compiler/lower_64bit_packing: rename the pass to be more genericIago Toral Quiroga2018-05-031-1/+1
| | | | | | It can do 32-bit packing too now. Reviewed-by: Jason Ekstrand <[email protected]>
* radv: UseEnumerateInstanceVersion for the default version.Bas Nieuwenhuizen2018-05-021-1/+1
| | | | Reviewed-by: Samuel Pitoiset <[email protected]>
* radv: Don't check the incoming apiVersion on CreateInstance.Bas Nieuwenhuizen2018-05-021-9/+0
| | | | | | | | | This fixes dEQP-VK.api.device_init.create_instance_invalid_api_version CC: 18.1 <[email protected]> Reviewed-by: Samuel Pitoiset <[email protected]>
* radv: Allow vkEnumerateInstanceVersion ProcAddr without instance.Bas Nieuwenhuizen2018-05-021-1/+1
| | | | | | | | | | | | Apparently the somewhere between 1.1.70 and 1.1.73 the loader started depending on this. The loader then creates a 1.0 instance, which gets into funny situation because we have a 1.1 device. No idea how to do line wrapping in Mako though, my random guesses did not work. CC: 18.1 <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* radv: fix multisample image copiesMatthew Nicholls2018-05-022-110/+196
| | | | | | | | | | | | | | | | | | | Previously before fb077b0728, the LOD parameter was being used in place of the sample index, which would only copy the first sample to all samples in the destination image. After that multisample image copies wouldn't copy anything from my observations. This fixes some copy_and_blit CTS tests. v3.1: - set lod to 0 for nir_txf_ms (Samuel) v2: - use GLSL_SAMPLER_DIM_MS instead of 2D (Samuel) - updated commit description (Samuel) Fix this properly by copying each sample in a separate radv_CmdDraw and using a pipeline with the correct rasterizationSamples for the destination image. Cc: 18.0 18.1 <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* radv: enable out-of-order rasterization by defaultSamuel Pitoiset2018-05-022-2/+3
| | | | | | | | | | | As the implementation is conservative, we can now enable it by default. It can be disabled with RADV_DEBUG=nooutoforder. Don't expect much more than 1% of improvements, but the gain seems consistent. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* radv: only disable out-of-order rast for perfect occlusion queriesSamuel Pitoiset2018-05-022-10/+12
| | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* radv: compute the number of subpass attachments correctlySamuel Pitoiset2018-05-011-2/+2
| | | | | | | | | Only count color attachments twice if resolves are used, also account for the depth stencil attachment if present. Cc: 18.0 18.1 <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]> Signed-off-by: Samuel Pitoiset <[email protected]>
* radv: set fmask_surf_index on fmask surfaces.Dave Airlie2018-05-021-1/+3
| | | | | | | | | This is needed for gfx9 and later for all fmask surface index. (Mentioned by Marek on irc) Reviewed-by: Bas Nieuwenhuizen <[email protected]> Reviewed-by: Samuel Pitoiset <[email protected]>
* radv/winsys: fix leaking resources from bo's imported by fdAndres Rodriguez2018-04-301-0/+1
| | | | | | | | | | | | A bo's ref_count was not being initialized when imported from an fd. Therefore, we would fail to free the resource during VkFreeMemory(). This patch fixes applications like hifi VR in threaded mode, which perform frequent imports/releases of IPC shared memory. Signed-off-by: Andres Rodriguez <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]> CC: 18.0 18.1 <[email protected]>