Erik Faye-Lund
1fc40c081e
mesa/program_cache: remove unused shader-cache functions
...
These are no longer in use, so let's get rid of them.
Reviewed-by: Adam Jackson <ajax@redhat.com >
Acked-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22755 >
2023-05-19 13:51:19 +00:00
Erik Faye-Lund
a0683e243a
mesa/main: compile ff_fragment_shader as c-code
...
The reason this used to be C++ code, was because it needed ir_builder.
We no longer need that, so let's move this to C-code instead. This makes
some details a bit more straight-forward.
Reviewed-by: Adam Jackson <ajax@redhat.com >
Acked-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22755 >
2023-05-19 13:51:19 +00:00
Erik Faye-Lund
e607a89f22
mesa/main: ff-fragshader to nir
...
There's little point in emitting GLSL IR for the fixed-function fragment
shaders, when we can emit NIR directly instead.
This simplifies things a bit, and makes the fixed-function vertex and
fragment shaders look a lot more alike.
The reason the old code did the splats, was that TEXENV_SRC_ZERO and
TEXENV_SRC_ONE returned scalars. I decided to keep it vector, and let
the nir optimization passes clean this up instead when needed, as that
keeps the code a bit more straight forward.
Reviewed-by: Adam Jackson <ajax@redhat.com >
Acked-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22755 >
2023-05-19 13:51:19 +00:00
Erik Faye-Lund
a37051304a
compiler/nir: move find_state_var to common code
...
We're about to need this in another place, so let's move it to common
nir code, and clean up the name a bit.
Acked-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22755 >
2023-05-19 13:51:19 +00:00
Erik Faye-Lund
5e997beeb7
mesa/st: allow using nir for ff-fragment shaders
...
This is similar to what we do for ff-vertex shaders.
Reviewed-by: Adam Jackson <ajax@redhat.com >
Acked-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22755 >
2023-05-19 13:51:19 +00:00
Erik Faye-Lund
793840937f
mesa/st: refactor st_translate_fragment_program
...
This makes it look more like st_translate_vertex_program, which is doing
the same thing for vertex-shaders.
Reviewed-by: Adam Jackson <ajax@redhat.com >
Acked-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22755 >
2023-05-19 13:51:19 +00:00
Erik Faye-Lund
30d9be1f9f
mesa/main: clean up white-space in ff_fragment_shader.cpp
...
We're about to change this, so let's clean this up first!
Reviewed-by: Adam Jackson <ajax@redhat.com >
Acked-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22755 >
2023-05-19 13:51:19 +00:00
Erik Faye-Lund
185001a86f
meson: remove needless c++17-overrides
...
C++17 is the project-wide default since f9057cea51 ("fix(FTBFS):
meson: raise C++ standard to C++17"), so let's drop these local
overrides.
Reviewed-by: Eric Engestrom <eric@engestrom.ch >
Reviewed-by: Emma Anholt <emma@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23048 >
2023-05-19 12:45:31 +00:00
Frank Binns
886ad3b4ec
pvr: fix array overflow in pvr_device_tile_buffer_ensure_cap()
...
The function didn't properly handle the case where the requested capacity was
less than the existing capacity. This led to the loop limit being some huge
number and it writing past the end of the 'buffers' array.
Partially fixes:
dEQP-VK.renderpass.suballocation.multisample_resolve.r16g16b16a16_unorm
.max_attachments_8_samples_2
The test no longer hangs, but segfaults instead.
Signed-off-by: Frank Binns <frank.binns@imgtec.com >
Reviewed-by: Karmjit Mahil <Karmjit.Mahil@imgtec.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23104 >
2023-05-19 10:44:27 +00:00
Samuel Pitoiset
b83ce03a7d
radv: reserve cmdbuf space in radv_flush_gfx2ace_semaphore()
...
Fixes an assertion with test_amplification_shader in vkd3d-proton.
Cc: mesa-stable
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23057 >
2023-05-19 07:52:25 +00:00
Samuel Pitoiset
a1b88c0664
ci: rework vkd3d-proton runner and fix detecting failures
...
The script returned 0 (aka succcess) for assertions or segmentation
faults. Found this after introducing a regression that caused a
segfault in vkd3d with vk-cts-image but not with Mesa CI.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23057 >
2023-05-19 07:52:25 +00:00
Samuel Pitoiset
5a2a042ec7
ci: stop using the hang-detection tool for vkd3d-proton
...
It's no longer used for deqp-runner as well, and it's not really
useful for us because we can detect GPU hangs differently. It also
prevents returning the error code from vkd3d-proton.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23057 >
2023-05-19 07:52:25 +00:00
Samuel Pitoiset
bec100f9b5
ci,radv: use drm-shim instead of the null winsys for radv-fossils
...
Only RADV uses fossilize-runner.sh, so hardcoding LD_PRELOAD is fine.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23072 >
2023-05-19 06:59:31 +00:00
Samuel Pitoiset
66a33888f0
ci: build drm-shim in debian-testing
...
This will be needed by RADV for using AMDGPU drm-shim.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23072 >
2023-05-19 06:59:31 +00:00
Samuel Pitoiset
9f9feda85f
amd/drm-shim: update README about which file to modify
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23072 >
2023-05-19 06:59:30 +00:00
Samuel Pitoiset
400434e5ea
amd/drm-shim: add bonaire
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23072 >
2023-05-19 06:59:30 +00:00
Samuel Pitoiset
9234558a60
amd/drm-shim: add pitcairn
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23072 >
2023-05-19 06:59:30 +00:00
Samuel Pitoiset
714ae97669
amd/drm-shim: add navi21
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23072 >
2023-05-19 06:59:30 +00:00
Hyunjun Ko
e5536173dc
anv/ci: Add tests for video formats to the failing tests.
...
This should be removed once the issue is resolved.
(https://gitlab.khronos.org/Tracker/vk-gl-cts/-/issues/4280 )
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:02 +00:00
Hyunjun Ko
60f871dc9e
anv: enable the video h265 decode extension.
...
Currently tested on CometLake(gen9) and AlderLake(gen12)
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:02 +00:00
Hyunjun Ko
a64ae20d0f
anv: support HEVC 10-bit decoding
...
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:02 +00:00
Hyunjun Ko
ad02e21ad2
anv/image: get width/height for each plane of a surface for video decoding.
...
This is especially for p010 format, which isn't supported for YCbCr
conversion yet.
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:02 +00:00
Hyunjun Ko
50374b1f9a
anv: support P010 format for video 10-bit hevc decoding
...
Only for video 10-bit hevc decoding, so shouldn't enable such as YCbCr
conversion.
v1. Fix to avoid YCbCr CTS tests for this format.
( Lionel Landwerlin <lionel.g.landwerlin@intel.com > )
v2. Add a flag can_video so we could handle supported video formats
neatly.
( Lionel Landwerlin <lionel.g.landwerlin@intel.com > )
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:02 +00:00
Hyunjun Ko
8d519eb5f5
anv: add initial video decode support for h265
...
Tested on CometLake(gen9) and AlderLake(gen12)
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:02 +00:00
Hyunjun Ko
91235092ab
anv/image: allow VK_IMAGE_CREATE_ALIAS_BIT with a private binding.
...
when the image is for video decoding.
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:01 +00:00
Hyunjun Ko
23c338af5d
anv/image: allocate mv storage buffers for h265
...
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:01 +00:00
Hyunjun Ko
b4b31828e0
anv/image: Add a surface usage bit for video decoding
...
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:01 +00:00
Hyunjun Ko
b08614b96b
vulkan/video: add h265 reference structures and relevant util functions.
...
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:01 +00:00
Hyunjun Ko
efdcacb230
vulkan/video: add to parse h265 slice.
...
Vulkan spec doesn't provide any interface for slice decoding while some
devices may require them. So we need to keep this inside.
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Dave Airlie <airlied@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:01 +00:00
Hyunjun Ko
c78c5466e4
util/vl: initialize data/end pointers.
...
Since this util moved to public place it turned out it could cause
a build error on current CI like the following:
../src/util/vl_vlc.h:225:52: error: 'vlc.data' may be used uninitialized in this function [-Werror=maybe-uninitialized]
225 | assert(vl_vlc_valid_bits(vlc) >= num_bits || vlc->data >= vlc->end);
| ^~
../src/util/vl_vlc.h:225:65: error: 'vlc.end' may be used uninitialized in this function [-Werror=maybe-uninitialized]
225 | assert(vl_vlc_valid_bits(vlc) >= num_bits || vlc->data >= vlc->end);
| ^~
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:01 +00:00
Hyunjun Ko
d5f8265e05
intel/genxml: add a command VD_CONTROL_STATE to gen12/125
...
It's essentially needed to execute hevc decoding on gen12.
Note that we set HCP by default.
- Command OpCode : VDENC(1), HCP(7), AVP(3)
- SubOpcode : HCP(10), VDENC(11)
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:01 +00:00
Hyunjun Ko
27dcd18210
intel/genxml: align some fields on gen9/11/12/125 with media driver.
...
Most of them are length of each instruction and the rest are
some corrections on specific gens.
v1. Added a default value to DWordLength of each instruction.
( Lionel Landwerlin <lionel.g.landwerlin@intel.com > )
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:01 +00:00
Hyunjun Ko
b3a1a8c617
intel/genxml: conform some fields to each other gen.
...
There are same fields across gens but the existing xmls are not exactly same,
which needs to be fixed.
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:01 +00:00
Hyunjun Ko
44bc651aba
intel/genxml: fix num bits of some MOCS fields
...
Actually the first bit is a bit of protected mask (or reserved)
and the next 6 bits are for MOCS but they are being handled together
currently in isl_device_setup_mocs. So we need to fix some MOCS fields
defined as 6 bits to 7 bits.
Signed-off-by: Hyunjun Ko <zzoon@igalia.com >
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22202 >
2023-05-19 06:15:01 +00:00
Marek Olšák
1a24f43d97
amd/registers: update pitch definitions in descriptors
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:49 +00:00
Marek Olšák
dbc1febb33
ac/surface: add ac_surf_config::is_array
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
78088ebaea
ac/surface: fix overridden linear pitch for CPU access
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
3f5723a23f
ac/surface: validate overridden pitch for all chips
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
f449ff426f
ac/surface: define LINEAR_PITCH_ALIGNMENT
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
4705148c5e
ac/surface: clean up and move the PIPE_CONFIG helper to ac_surface.c
...
This will be used by following commits.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
ad0c490e38
radeonsi: fix image size calculation in fast clear
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
2f51ba5496
radeonsi: fix sparse image address calculation for large images by using uint64_t
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
df39962dc8
radeonsi: fix image address calculation for large images by using uint64_t
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
6d69aa38c1
radeonsi: fix SDMA image address calculation for large images by using uint64_t
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
4d9942d891
radv: fix SDMA image address calculation for large images by using uint64_t
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
c627bdc9b6
radv: fix sparse image address calculation for large images by using uint64_t
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Marek Olšák
cbc6bf8218
ac/surface: fix address calculation for large images by using uint64_t
...
also rename gfx9_surf_level -> gfx9_surf_meta_level
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23037 >
2023-05-19 02:58:48 +00:00
Qiang Yu
ce161ce463
radeonsi: fix uses_instanceid for merged mono shader stage
...
prev_shader.info.uses_instanceid is set by si_nir_lower_vs_inputs()
when attribute divisor is used.
Fixes: 894d92995c ("radeonsi: monolithic VS emit prolog in nir directly")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/9042
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/23101 >
2023-05-19 02:07:08 +00:00
norablackcat
b5ae645c16
rusticl/device: add cl_khr_integer_dot_product ext
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23011 >
2023-05-18 23:59:53 +00:00
norablackcat
9c1051d7cf
rusticl/kernel: remove nir_lower_pack pass
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/23011 >
2023-05-18 23:59:53 +00:00