Jason Ekstrand
1a14d98fa2
nir: Document all the ALU opcodes
...
Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11438 >
2021-06-21 16:47:00 +00:00
Jason Ekstrand
73188c6954
nir,docs: Add docs for NIR ALU instructions
...
About half or more of the text here is actually from Connor Abbot. I've
edited it a bit to bring it up-to-date and make a few things more clear.
Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11438 >
2021-06-21 16:46:59 +00:00
Jason Ekstrand
f00b5a30f5
nir: Require vectorized ALU ops to be all-or-nothing
...
Long ago, the semantics of bcsel were such that it took a single boolean
value and selected between whole vectors. These days, it takes a vector
boolean with the assumption that if you want the old behavior you can
just use a .xxxx swizzle. There currently are no opcodes which use a
output_size of 0 but have a scalar or fixed-vector input. Let's
disallow it for now to force us to think through the semantics again if
this ever comes up as something someone actually wants.
Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11438 >
2021-06-21 16:46:59 +00:00
Rhys Perry
ea68d4a676
nir/propagate_invariant: add invariant_prim option
...
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11035 >
2021-06-21 15:13:05 +00:00
Mike Blumenkrantz
7144f33802
zink: handle custom border color without matching wrap mode case
...
this is just default border color and the custom color is ignored
Fixes: 36f4e61403 ("zink: rework border color handling")
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11495 >
2021-06-21 14:54:33 +00:00
Jason Ekstrand
69d4fa3a1c
vulkan: Update the XML and headers to 1.2.182
...
Acked-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11497 >
2021-06-21 14:29:16 +00:00
Jason Ekstrand
2e08bae9b3
nir,vc4: Suffix a bunch of unorm 4x8 opcodes _vc4
...
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com>
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11463 >
2021-06-21 09:04:08 -05:00
Jason Ekstrand
0afbfee8da
nir,panfrost: Suffix fsat_signed and fclamp_pos with _mali
...
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11463 >
2021-06-21 09:03:34 -05:00
Jason Ekstrand
f0f713960b
nir,amd: Suffix nir_op_cube_face_coord/index with _amd
...
Reviewed-by: Alyssa Rosenzweig <alyssa@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11463 >
2021-06-21 09:03:34 -05:00
Timur Kristóf
e5510536e7
aco: Fix checking if load_shared is used by cross lane instructions.
...
This commit fixes two issues with it:
1. Prevent it from going into an infinite loop.
2. Check all uses, not just first use.
Closes : #4916
Fixes: b4e22eb482
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Reviewed-by: Tony Wasserka <tony.wasserka@gmx.de>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11361 >
2021-06-21 13:42:52 +00:00
Andres Gomez
90c7ab08ea
ci: use bash with download-git-cache.sh
...
It's a bash script, so make sure we use bash and not just sh.
Reviewed-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Signed-off-by: Andres Gomez <agomez@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9865 >
2021-06-21 15:05:25 +03:00
Bas Nieuwenhuizen
d074cc4af4
util/fossilize_db: Only lock the db file, not the index.
...
This thing is entirely opt-in wrt caring about it when writing to
a file anyway. Since we also lock the two at the same time and they
have an 1-1 relation we can just lock one of the two files. Saves
some syscalls.
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11485 >
2021-06-21 10:05:12 +00:00
Bas Nieuwenhuizen
4f0f8133a3
util/fossilize_db: Do not lock the fossilize db permanently.
...
This avoids all locks for reads and using lock only while actually
writing.
This is enabled by doing two things:
1) Reading the index incrementally. This way we get new entries
written by other processes and do not write duplicate entries.
2) Taking the lock only during writes, and applying the incremental
read while holding the lock so we always append to the actual end of the file.
Fixes: eca6bb9540 ("util/fossilize_db: add basic fossilize db util to read/write shader caches")
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11485 >
2021-06-21 10:05:12 +00:00
Bas Nieuwenhuizen
2ec1bff0f3
util/fossilize_db: Split out reading the index.
...
Fixes: eca6bb9540 ("util/fossilize_db: add basic fossilize db util to read/write shader caches")
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11485 >
2021-06-21 10:05:12 +00:00
Bas Nieuwenhuizen
bd41c51c8f
util/fossilize_db: Pull seek into lock.
...
Otherwise the seek can overlap with other reads/writes.
Fixes: eca6bb9540 ("util/fossilize_db: add basic fossilize db util to read/write shader caches")
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11485 >
2021-06-21 10:05:12 +00:00
Bas Nieuwenhuizen
a99474fae5
radv: Add -Wpointer-arith.
...
Gives earlier indications of MSVC issues.
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11478 >
2021-06-21 09:32:00 +00:00
Timur Kristóf
72174a3eef
ac/nir: Update TCS output barriers with nir_var_mem_shared.
...
Output loads and stores are lowered to shared memory access,
so we have to update the barriers to also reflect this.
Closes : #4955
Fixes: bf966d1c1d
Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11484 >
2021-06-21 08:27:14 +00:00
Erik Faye-Lund
ed04cb62d8
docs: use rst captions
...
This is slightly stronger semantically.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11464 >
2021-06-21 08:22:51 +00:00
Erik Faye-Lund
e41efc173b
docs: use more file-roles
...
This makes the documentation a bit easier to read, and aids
spell-checkers, so let's specify these using file-roles.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11464 >
2021-06-21 08:22:51 +00:00
Erik Faye-Lund
63c9d51981
docs: drop historic meson details
...
Similar to the last few commits, we require Meson 0.52 now. There's no
point in confusing users with specifying what versions supports what
here, as all supported versions works the same way now.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11464 >
2021-06-21 08:22:51 +00:00
Erik Faye-Lund
07cd8897fb
docs: remove outdated clarification
...
Similar to the previous commit, we now require Meson 0.52 all the time,
so there's no point in singling this out.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11464 >
2021-06-21 08:22:51 +00:00
Erik Faye-Lund
309b549f0e
docs: remove outdated meson-section
...
We're already requiring Meson 0.52, so there's no point in mentioning
this old work-around.
Reviewed-by: Eric Engestrom <eric@engestrom.ch>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11464 >
2021-06-21 08:22:51 +00:00
Iago Toral Quiroga
fa8868192b
v3dv: remove const qualifier for resource pointer in view objects
...
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11443 >
2021-06-21 06:00:56 +00:00
Iago Toral Quiroga
b8abedb974
v3dv: expose VK_KHR_copy_commands2
...
Relevant CTS tests:
dEQP-VK.api.copy_and_blit.copy_commands2.*
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11443 >
2021-06-21 06:00:56 +00:00
Iago Toral Quiroga
aa61a653a5
v3dv: implement vkCmdResolveImage2KHR
...
The common Vulkan code will call this to implement vkCmdResolveImage.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11443 >
2021-06-21 06:00:56 +00:00
Iago Toral Quiroga
8e358a74d0
v3dv: implement vkCmdCopyImage2KHR
...
The common Vulkan code will call this to implement vkCmdCopyImage.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11443 >
2021-06-21 06:00:56 +00:00
Iago Toral Quiroga
3bdc03fd28
v3dv: implement vkCmdCopyBufferToImage2KHR and vkCmdCopyImageToBuffer2KHR
...
The common Vulkan code will call this to implement vkCmdCopyImageToBuffer.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11443 >
2021-06-21 06:00:56 +00:00
Iago Toral Quiroga
47390d6669
v3dv: implement vkCmdCopyBuffer2KHR
...
The common Vulkan code will call this to implement vkCmdCopyBuffer.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11443 >
2021-06-21 06:00:56 +00:00
Iago Toral Quiroga
06a9a3ead5
v3dv: implement vkCmdBlitImage2KHR
...
The common Vulkan code will call this to implement vkCmdBlitImage.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11443 >
2021-06-21 06:00:56 +00:00
Yurii Kolesnykov
89b4f337d5
c_std=c11 in meson default_options
...
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/1020
Co-authored-by: Kristian Høgsberg <krh@bitplanet.net>
Acked-by: Karol Herbst <kherbst@redhat.com>
Acked-by: Eric Engestrom <eric@engestrom.ch>
Signed-off-by: Yurii Kolesnykov <root@yurikoles.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6935 >
2021-06-20 11:36:06 +03:00
Marek Olšák
61a845ca19
ac/surface: don't set DCC_PIPE_ALIGN modifier bit for gfx10 with 1 RB
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11486 >
2021-06-20 01:22:01 -04:00
Marek Olšák
2acd34f266
ac/surface/tests: fix RB counts
...
The real number of RBs can be less than what GB_ADDR_CONFIG contains.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11486 >
2021-06-20 01:22:01 -04:00
Marek Olšák
9c3225cb53
radeonsi: move the accepting code into the bbox cull branch in NGG cull code
...
This reduces the number of jumps. No change in behavior.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11486 >
2021-06-20 01:22:01 -04:00
Marek Olšák
12d2df15f1
ac/llvm: add a callback to ac_cull_triangle to generate code in inner-most block
...
This will reduce jumps in culling code.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11486 >
2021-06-20 01:22:01 -04:00
Marek Olšák
1805572694
radeonsi: fix multi draws for the prim discard CS
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11486 >
2021-06-20 01:22:01 -04:00
Marek Olšák
848dbe9ff7
radeonsi: fix incorrect counting of compute_num_verts_rejected
...
Both cases should subtract to undo what is done in the conditional.
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11486 >
2021-06-20 01:22:01 -04:00
Marek Olšák
3cde2f96f9
radeonsi: use ac_build_bit_count instead of opencoding it
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11486 >
2021-06-20 01:22:01 -04:00
Marek Olšák
70b5a5cbbf
radeonsi: fix compile failures with SI_PRIM_DISCARD_DEBUG enabled
...
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11486 >
2021-06-20 01:22:01 -04:00
Eleni Maria Stea
b4d90b1182
egl: fix in expected type
...
Function mincore expects a pointer of type char* but we use an unsigned
char* instead generating signedness related warnings.
v2: Made the fix FreeBSD specific because the type is unsigned char* for
Linux and char* for FreeBSD. (Adam Jackson)
v3: We'd rather cast the param to (void*) to avoid warnings in all
systems (Adam Jackson)
Signed-off-by: Eleni Maria Stea <elene.mst@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11298 >
2021-06-19 19:34:20 +00:00
Jason Ekstrand
7b8199e4a2
crocus: Drop extra_aux support
...
This exists for combined MCS+CCS or HiZ+CCS which was introduced on
Tigerlake. Crocus will never support hardware that has these features
so there's no point carrying the dead copied+pasted code from iris.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11483 >
2021-06-19 14:57:25 +00:00
Bas Nieuwenhuizen
82de184c3a
radv: Enable VK_KHR_acceleration_structure with RADV_PERFTEST=rt.
...
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11078 >
2021-06-18 22:16:27 +00:00
Bas Nieuwenhuizen
c27e3a6248
radv: Add rt perftest flag.
...
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11078 >
2021-06-18 22:16:27 +00:00
Bas Nieuwenhuizen
438cb7f9a3
radv: Expose formats for acceleration structure.
...
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11078 >
2021-06-18 22:16:27 +00:00
Bas Nieuwenhuizen
9920eadf83
radv: Implement load_vulkan_descriptor for acceleration structures.
...
It always uses nir_address_format_64bit_global.
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11078 >
2021-06-18 22:16:27 +00:00
Bas Nieuwenhuizen
85e39cb325
radv: Convert lower_intrinsics to a switch statement
...
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11078 >
2021-06-18 22:16:27 +00:00
Bas Nieuwenhuizen
a4b3ce5d56
radv: Add acceleration structure descriptor set support.
...
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11078 >
2021-06-18 22:16:27 +00:00
Bas Nieuwenhuizen
0dad88b469
radv: Implement device-side BVH building.
...
Same naive algorithm as the host build.
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11078 >
2021-06-18 22:16:27 +00:00
Bas Nieuwenhuizen
d51a4b4c4b
radv: Add initial CPU BVH building.
...
The algorithm used for the BVH:
1) first create 1 leaf per primitive (triangle/aabb/instance)
2) Then create internal layers from the bottom up until we are left with
1 node in the top layer. Node i in the layer will have children
(i*4+0) ... (i*4+3) in the previous layer.
This results in a very naive algorithm but it is also very simple to implement.
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11078 >
2021-06-18 22:16:27 +00:00
Bas Nieuwenhuizen
67e949a8f8
radv: Use the global BO list for acceleration structures.
...
We have nested structures so tracking this from the descriptor
set is going to be a mess.
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11078 >
2021-06-18 22:16:27 +00:00
Jason Ekstrand
f31bfda34a
util: Move the 4x4 matrix inverse function to u_math
...
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11078 >
2021-06-18 22:16:27 +00:00