aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r600
Commit message (Collapse)AuthorAgeFilesLines
...
* r600/sfn: Add a load GDS result instructionGert Wollny2020-02-102-0/+32
| | | | | | | This is required to read results for atomic SSBO instructions Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600/sfn: Add lowering arrays to scratch and according instructionsGert Wollny2020-02-1010-4/+281
| | | | | | | | | Make use of the scratch space for arrays that are larger then 100 elements. Since for IO r600 is vector based, there is a bit of a scratch space waste here for arrays that use types smaller then vec4. Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600/sfn: add register remappingGert Wollny2020-02-1012-0/+171
| | | | | | | | | Make use of the live range evaluation to merge registers. Since the live ranges are evaluated for register indices, the algorithm is not optimal, but for most piglits up to glsl-3.3 it does the job. Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600/sfn: add live range evaluation for the GPRGert Wollny2020-02-1013-1/+1571
| | | | | | | | The algoritm is basically a copy of the TGSI implementation without the array bits. Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600/sfn: Add the WaitAck instructionGert Wollny2020-02-106-0/+115
| | | | | Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600/sfn: Add the VS in and FS out vectorizationGert Wollny2020-02-107-0/+977
| | | | | | | | | Since the nir default implementation doesn't support vectorizing the VS inputs and FS outputs, additional lowering passes are added here to do just that. The work is based on the Timothy Arceri's related work. Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600: enable NIR backend DEBUG flag for supported architecturesGert Wollny2020-02-103-27/+115
| | | | | | | | When NIR is enabled, a few features that are not yet supported will be explicitely disabled. Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600/sfn: Add a basic nir shader backendGert Wollny2020-02-1047-6/+12955
| | | | | | | | | | | | | This commit adds support for vertex and fragment shaders from NIR, and support for most TEX and ALU instructions. Thanks Dave Airlied for adding support for a number of ALU instructions. v2: fix compilation with gcc-6 v3: rebase: use mesa/core glsl_type_size function Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600: Update state code to accept NIR shadersGert Wollny2020-02-104-24/+67
| | | | | | | v2: Correct commit message (Konstantin Kharlamov) Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600: Add NIR compiler optionsGert Wollny2020-02-101-0/+29
| | | | | Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600: Increase space for IO values to agree with PIPE_MAX_SHADER_IN/OUTPUTSGert Wollny2020-02-101-2/+2
| | | | | Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* r600: force new CF with TEX only if any texture value is writtenGert Wollny2020-02-101-1/+3
| | | | | | | This works aound splitting the CF when the gradient is set. Signed-off-by: Gert Wollny <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3225>
* gallium: Add and use a helper for packing uc from a color_union.Eric Anholt2020-02-041-5/+1
| | | | | | | | The same pattern kept coming up, and we don't need to hit util_format_write_4* to do it when we have util_format_pack_rgba(). Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/2744>
* util: Make helper functions for pack/unpacking pixel rows.Eric Anholt2020-02-041-9/+3
| | | | | | | | | Almost all users of the unpack functions don't have strides to plug in (and many are only doing one pixel!), and this will help simplify them. Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/2744>
* r600: Move get_pic_param to radeon_vce.cTimur Kristóf2020-01-222-4/+4
| | | | | | Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3488>
* r600: Remove a bunch of default handling of pipe caps.Eric Anholt2020-01-211-53/+0
| | | | | | | | u_screen will return 0 for all of these, which means that this is one less driver to see in git grep when I'm checking who exposes a cap. Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3493>
* r600: Delete vertex buffer only if there is actually a shader stateGert Wollny2020-01-041-1/+2
| | | | | | | Fixes: gl-2.0-vertexattribpointer Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Konstantin Kharlamov <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3286>
* r600: Make SID and unsigned valueGert Wollny2020-01-041-1/+1
| | | | | | | | | The value is never negative, and makeing it unsigned fixes some warnings Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Konstantin Kharlamov <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3286>
* r600: Fix maximum line widthGert Wollny2020-01-041-4/+1
| | | | | | | | | | | | | | | | | | | There are only 13 bits available to store the line width, hence it can't be larger than 8191 v2: Add Fixes tag v3: - Unify value since for all r600 archs (Konstantin Kharlamov) - Correct the value the line width value is emitted as a 12.4 fixed point value of 1/2 line width on r600-r700 and as 8 * line width on Evergreen and newer. Fixes: 06bfb2d28f7adca7edc6be9c210a7a3583023652 r600: fork and import gallium/radeon Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Konstantin Kharlamov <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3286>
* r600/sb: Correct SB disassambler for better debuggingGert Wollny2020-01-042-1/+8
| | | | | | Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Konstantin Kharlamov <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3286>
* r600: Make it possible to include r600_asm.h in a C++ fileGert Wollny2020-01-041-0/+9
| | | | | | Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Konstantin Kharlamov <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3286>
* r600: Add functions to dump the shader infoGert Wollny2020-01-044-0/+211
| | | | | | | | This will be helpful to compare TGSI and NIR code path, Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Konstantin Kharlamov <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3286>
* r600: Remove HEVC related code since HEVC is not supportedThong Thai2020-01-032-63/+2
| | | | | | | Signed-off-by: Thong Thai <[email protected]> Reviewed-by: Leo Liu <[email protected]> Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3153> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3153>
* radeon: Use P010 for decoding of 10-bit videosThong Thai2020-01-031-1/+2
| | | | | | | | | | | Previously, P016 was used for the decoding of 10-bit HEVC/H.265 encoded videos, which worked fine for mpv and ffmpeg. GStreamer specifically looks for P010, so this patch sets the default buffer type to P010 for HEVC decoding. Signed-off-by: Thong Thai <[email protected]> Reviewed-by: Leo Liu <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3153>
* r600: Disable eight bit three channel formatsGert Wollny2019-11-261-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 0899bf55 made some deqp-gles3 tests related to RGB8 PBOs fail on R600 because it exposed PIPE_FORMAT_R8G8B8_UNORM and R600 doesn't propely handle this. Disabling this format also for buffers fixes the issue. In addition, disabling also the related RGB8 integer formats for buffers fixes some deqp-gles3 tests: dEQP-GLES3.functional.texture.specification.teximage2d_pbo.rgb8ui_cube dEQP-GLES3.functional.texture.specification.texsubimage2d_pbo.rgb8i_2d dEQP-GLES3.functional.texture.specification.texsubimage2d_pbo.rgb8i_cube dEQP-GLES3.functional.texture.specification.texsubimage2d_pbo.rgb8ui_2d dEQP-GLES3.functional.texture.specification.texsubimage2d_pbo.rgb8ui_cube dEQP-GLES3.functional.texture.specification.teximage3d_pbo.rgb8i_2d_array dEQP-GLES3.functional.texture.specification.teximage3d_pbo.rgb8i_3d dEQP-GLES3.functional.texture.specification.teximage3d_pbo.rgb8ui_2d_array dEQP-GLES3.functional.texture.specification.teximage3d_pbo.rgb8ui_3d dEQP-GLES3.functional.texture.specification.texsubimage3d_pbo.rgb8i_2d_array dEQP-GLES3.functional.texture.specification.texsubimage3d_pbo.rgb8i_3d dEQP-GLES3.functional.texture.specification.texsubimage3d_pbo.rgb8ui_2d_array dEQP-GLES3.functional.texture.specification.texsubimage3d_pbo.rgb8ui_3d Fixes: 0899bf55 st/mesa: Map MESA_FORMAT_RGB_UNORM8 <-> PIPE_FORMAT_R8G8B8_UNORM Closes #2118 Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
* ac: add radeon_info::num_rings and move ring_type to amd_family.hMarek Olšák2019-11-191-3/+3
| | | | Reviewed-by: Pierre-Eric Pelloux-Prayer <[email protected]>
* util: Move gallium's PIPE_FORMAT utils to /util/format/Eric Anholt2019-11-145-5/+5
| | | | | | | | | | | | | | | To make PIPE_FORMATs usable from non-gallium parts of Mesa, I want to move their helpers out of gallium. Since u_format used util_copy_rect(), I moved that in there, too. I've put it in a separate directory in util/ because it's a big chunk of related code, and it's not clear to me whether we might want it as a separate library from libmesa_util at some point. Closes: #1905 Acked-by: Marek Olšák <[email protected]> Reviewed-by: Kristian H. Kristensen <[email protected]> Reviewed-by: Alyssa Rosenzweig <[email protected]>
* util: rename PIPE_ARCH_*_ENDIAN to UTIL_ARCH_*_ENDIANDylan Baker2019-11-052-2/+2
| | | | | | | | | | | As requested by Tim. This was generated with: grep 'PIPE_ARCH_.*_ENDIAN' -rIl | xargs sed -ie 's@PIPE_ARCH_\(.*\)_ENDIAN@UTIL_ARCH_\1_ENDIAN@'g v2: - add this patch Reviewed-by: Eric Engestrom <[email protected]>
* util/u_endian: set PIPE_ARCH_*_ENDIAN to 1Dylan Baker2019-11-052-2/+2
| | | | | | | | | | | | This will allow it to be used as a drop in replacement for _mesa_little_endian in a number of cases. v2: - Always define PIPE_ARCH_LITTLE_ENDIAN and PIPE_ARCH_BIG_ENDIAN, define the one that reflects the host system to 1 and the other to 0 - replace all uses of #ifdef, #ifndef, and #if defined() with #if and #if ! with PIPE_ARCH_*_ENDIAN Reviewed-by: Eric Engestrom <[email protected]>
* util: remove LIST_IS_EMPTY macroTimothy Arceri2019-10-281-2/+2
| | | | | | | Just use the inlined function directly. The new function was introduced in addcf410. Reviewed-by: Eric Engestrom <[email protected]>
* util: remove LIST_DEL macroTimothy Arceri2019-10-282-4/+4
| | | | | | | Just use the inlined function directly. The macro was replaced with the function in ebe304fa540f. Reviewed-by: Eric Engestrom <[email protected]>
* util: remove LIST_DELINIT macroTimothy Arceri2019-10-282-2/+2
| | | | | | | Just use the inlined function directly. The macro was replaced with the function in ebe304fa540f. Reviewed-by: Eric Engestrom <[email protected]>
* util: remove LIST_ADD macroTimothy Arceri2019-10-281-3/+3
| | | | | | | Just use the inlined function directly. The macro was replaced with the function in ebe304fa540f. Reviewed-by: Eric Engestrom <[email protected]>
* util: remove LIST_ADDTAIL macroTimothy Arceri2019-10-284-9/+9
| | | | | | | Just use the inlined function directly. The macro was replaced with the function in ebe304fa540f. Reviewed-by: Eric Engestrom <[email protected]>
* util: remove LIST_INITHEAD macroTimothy Arceri2019-10-284-18/+18
| | | | | | | Just use the inlined function directly. The macro was replaced with the function in ebe304fa540f. Reviewed-by: Eric Engestrom <[email protected]>
* gallium: remove PIPE_SHADER_CAP_SCALAR_ISAMarek Olšák2019-10-101-2/+0
| | | | | | Reviewed-by: Timothy Arceri <[email protected]> Reviewed-by: Christian Gmeiner <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* vl: use u_format in vl_video_buffer_formatsMarek Olšák2019-10-091-4/+2
| | | | Reviewed-by: Bas Nieuwenhuizen <[email protected]>
* amd: Move all amd/common code that depends on LLVM to amd/llvm.Timur Kristóf2019-10-081-1/+3
| | | | | | | | | | | | | This commit is a step towards the goal of being able to build RADV without LLVM. In the future we would like to offer the option to use RADV solely with ACO. There is still a need for the common AMD code located in amd/common but the LLVM specific parts need to be separated. Signed-off-by: Timur Kristóf <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]> Acked-by: Marek Olšák <[email protected]> Acked-by: Samuel Pitoiset <[email protected]>
* gallium: add PIPE_RESOURCE_FLAG_SINGLE_THREAD_USE to skip util_range lockMarek Olšák2019-10-075-9/+9
| | | | | | | | | u_upload_mgr sets it, so that util_range_add can skip the lock. The time spent in tc_transfer_flush_region decreases from 0.8% to 0.2% in torcs on radeonsi. Reviewed-by: Kenneth Graunke <[email protected]>
* r600: Fix interpolateAtCentroidGert Wollny2019-10-044-1/+14
| | | | | | | | | | If the instruction interpolateAtCentroid is used the extra interpolator must also be enabled in the state. Fixes: fs-interpolateatcentroid-block Signed-off-by: Gert Wollny <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* rename pipe_llvm_program_header to pipe_binary_program_headerKarol Herbst2019-09-211-1/+1
| | | | | | | | We want to use it for other formats as well, so give it a more generic name Signed-off-by: Karol Herbst <[email protected]> Reviewed-by: Francisco Jerez <[email protected]> Reviewed-by: Pierre Moreau <[email protected]>
* gallium: add blob field to pipe_llvm_program_headerKarol Herbst2019-09-211-3/+1
| | | | | | | | makes it easier to consume a IR_NATIVE binary Signed-off-by: Karol Herbst <[email protected]> Reviewed-by: Francisco Jerez <[email protected]> Reviewed-by: Pierre Moreau <[email protected]>
* r300,r600,radeonsi: set winsys_handle::stride,offset in drivers, not winsysesMarek Olšák2019-09-091-2/+4
| | | | Acked-by: Pierre-Eric Pelloux-Prayer <[email protected]>
* r300,r600,radeonsi: read winsys_handle::stride,offset in drivers, not winsysesMarek Olšák2019-09-091-10/+8
| | | | Acked-by: Pierre-Eric Pelloux-Prayer <[email protected]>
* r600: replace binary HAVE_LLVM checks with LLVM_AVAILABLEEric Engestrom2019-09-061-6/+2
| | | | | Signed-off-by: Eric Engestrom <[email protected]> Acked-by: Michel Dänzer <[email protected]>
* tree-wide: replace MAYBE_UNUSED with ASSERTEDEric Engestrom2019-07-311-1/+1
| | | | | | Suggested-by: Jason Ekstrand <[email protected]> Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* r600: replace MAYBE_UNUSED with specific #ifdefEric Engestrom2019-07-311-2/+2
| | | | | Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* r600: move variable to proper scopeEric Engestrom2019-07-311-2/+1
| | | | | | | It helps show when it's actually used. Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* u_blitter: add a msaa parameter to util_blitter_clearPierre-Eric Pelloux-Prayer2019-07-231-1/+2
| | | | | | | Fixes: ea5b7de138b ("radeonsi: make gl_SampleMaskIn = 0x1 when MSAA is disabled") Tested-by: Michel Dänzer <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* gallium: switch boolean -> bool at the interface definitionsIlia Mirkin2019-07-229-57/+57
| | | | | | | | | | | | | | | | | | This is a relatively minimal change to adjust all the gallium interfaces to use bool instead of boolean. I tried to avoid making unrelated changes inside of drivers to flip boolean -> bool to reduce the risk of regressions (the compiler will much more easily allow "dirty" values inside a char-based boolean than a C99 _Bool). This has been build-tested on amd64 with: Gallium drivers: nouveau r300 r600 radeonsi freedreno swrast etnaviv v3d vc4 i915 svga virgl swr panfrost iris lima kmsro Gallium st: mesa xa xvmc xvmc vdpau va Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Acked-by: Alyssa Rosenzweig <[email protected]>