Connor Abbott
08d22bb908
tu: Fix IBO descriptor for cubes
...
They act the same as 2D arrays when used as storage images, and we're
supposed to override the IBO descriptor to reflect this.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5122 >
2020-05-26 11:16:09 +00:00
Marcin Ślusarz
f7ab9c4eb1
glsl: cleanup vertex shader input checks
...
Signed-off-by: Marcin Ślusarz <marcin.slusarz@intel.com >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5133 >
2020-05-26 10:15:17 +00:00
Marcin Ślusarz
e89d34aaca
glsl_to_tgsi: add fallthrough comments
...
All those cases are supposed to hit an assert in ir_binop_bit_or case.
Signed-off-by: Marcin Ślusarz <marcin.slusarz@intel.com >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5133 >
2020-05-26 10:15:17 +00:00
Marek Olšák
38a4b86145
radeonsi/gfx10: implement most performance counters
...
PAL has all of them.
GE perf counters don't work - no idea why.
I only tested the few that I like to use.
There is no documentation, though most of the enums had already been
in the headers.
Acked-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5184 >
2020-05-26 06:00:54 -04:00
Marek Olšák
2a3806ffa3
amd: replace SH -> SA (shader array) in comments
...
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5184 >
2020-05-26 06:00:54 -04:00
Marek Olšák
2cf46f2e3d
ac/gpu_info: replace num_good_cu_per_sh with min/max_good_cu_per_sa
...
Perf counters use the new max number.
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5184 >
2020-05-26 06:00:54 -04:00
Marek Olšák
8c3fe285c9
radeonsi: don't hardcode most perf counter block counts
...
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5184 >
2020-05-26 06:00:54 -04:00
Erik Faye-Lund
f3c1833b77
docs/features: mark GL_ARB_texture_multisample as done for zink
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5159 >
2020-05-26 07:55:17 +00:00
Erik Faye-Lund
cd1639cbe3
zink: expose PIPE_CAP_TEXTURE_MULTISAMPLE
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5159 >
2020-05-26 07:55:17 +00:00
Erik Faye-Lund
4f90e818c8
zink: implement nir_texop_txf_ms
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5159 >
2020-05-26 07:55:17 +00:00
Gert Wollny
caa83e4d79
r600/sfn: remove debug output leftover
...
Signed-off-by: Gert Wollny <gert.wollny@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5187 >
2020-05-26 06:17:42 +00:00
Gert Wollny
cead23cb8a
r600/sfn: Correctly update the number of literals when forcing a new
...
group
When forcing a new instruction group by adding a ALU_OP_NOP, the
literals for the instruction that triggered this must be taken into
account for the next group, so update the number of literals
accordingly.
Signed-off-by: Gert Wollny <gert.wollny@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5187 >
2020-05-26 06:17:42 +00:00
Gert Wollny
12381a0410
r600/sfn: use modern c++ in printing LDS read instruction
...
Closes #3021
Signed-off-by: Gert Wollny <gert.wollny@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5187 >
2020-05-26 06:17:42 +00:00
Gert Wollny
eccf939b6f
r600/sfn: Fix mapping for f32tof64 and f64tof32
...
We define the mapping based on the vector unit opcode.
Closes #3013
Signed-off-by: Gert Wollny <gert.wollny@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5187 >
2020-05-26 06:17:42 +00:00
Gert Wollny
901793d558
r600: Fix duplicated subexpression in r600_asm.c
...
Fixes: 4422ce1b04
r600: force new CF with TEX only if any texture value is written
Closes #3012
Signed-off-by: Gert Wollny <gert.wollny@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5187 >
2020-05-26 06:17:42 +00:00
Rob Clark
ceab349483
freedreno/drm: disallow exported buffers in bo cache
...
Otherwise we can MADVISE(WONTNEED) a bo that someone else is still
using. We already handled that in the dma-buf and flink-name export
paths.
Signed-off-by: Rob Clark <robdclark@chromium.org >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5204 >
2020-05-25 20:47:24 +00:00
Vinson Lee
1241f8cb4c
r600/sfn: Use correct setter method.
...
Fix warning reported by Coverity Scan.
Useless call (USELESS_CALL)
side_effect_free: Calling v->pin_to_channel() is only useful for its
return value, which is ignored.
Fixes: 5d10e3ec60 ("r600/nir: Pin interpolation results to channel")
Signed-off-by: Vinson Lee <vlee@freedesktop.org >
Reviewed-by: Gert Wollny <gert.wollny@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5197 >
2020-05-25 20:34:36 +00:00
Erik Faye-Lund
ed1fd7bcc6
zink: pass batch instead of context for queries
...
This makes things a bit more consistent IMO.
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5141 >
2020-05-25 20:20:49 +00:00
Erik Faye-Lund
43c691b5b0
zink: do not dig into resource for nr_samples
...
The pipe_surface also know this, so no point in digging so deep.
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5141 >
2020-05-25 20:20:49 +00:00
Erik Faye-Lund
e38513e828
zink: use samples from state
...
There's no reason to compute this, when it's already passed in.
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5141 >
2020-05-25 20:20:49 +00:00
Alyssa Rosenzweig
fcbc022787
nir: Add un/pack_32_4x8 opcodes
...
Complement the existing un/pack_32_2x16 opcodes. These are useful for
8-bit format packing. On Midgard, they are equivalent to just a 32-bit
move, but other GPUs could lower to other packs if needed.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5107 >
2020-05-25 20:03:52 +00:00
Dmitriy Nester
46d5b07c5c
util: delete fnv1a hash function
...
xxhash is faster than fnv1a in almost all circumstances, so we're
switching to it globally.
Signed-off-by: Dmytro Nester <dmytro.nester@globallogic.com >
Reviewed-by: Eric Anholt <eric@anholt.net >
Closes: https://gitlab.freedesktop.org/mesa/mesa/issues/2405
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4020 >
2020-05-25 19:41:09 +00:00
Dmitriy Nester
bf4d652f3f
zink: replace fnv1a hash function with xxhash
...
xxhash is faster than fnv1a in almost all circumstances, so we're
switching to it globally.
Signed-off-by: Dmytro Nester <dmytro.nester@globallogic.com >
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4020 >
2020-05-25 19:41:09 +00:00
Dmitriy Nester
33fd35e2d3
r600: replace fnv1a hash function with xxhash
...
xxhash is faster than fnv1a in almost all circumstances, so we're
switching to it globally.
Signed-off-by: Dmytro Nester <dmytro.nester@globallogic.com >
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4020 >
2020-05-25 19:41:09 +00:00
Dmitriy Nester
387176829b
util/hash_table: replace fnv1a hash function with xxhash
...
xxhash is faster than fnv1a in almost all circumstances, so we're
switching to it globally.
Signed-off-by: Dmytro Nester <dmytro.nester@globallogic.com >
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4020 >
2020-05-25 19:41:09 +00:00
Dmitriy Nester
013df58498
i965: replace fnv1a hash function with xxhash
...
xxhash is faster than fnv1a in almost all circumstances, so we're
switching to it globally.
Signed-off-by: Dmytro Nester <dmytro.nester@globallogic.com >
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4020 >
2020-05-25 19:41:09 +00:00
Dmitriy Nester
edd62619a1
freedreno: replace fnv1a hash function with xxhash
...
xxhash is faster than fnv1a in almost all circumstances, so we're
switching to it globally.
Signed-off-by: Dmytro Nester <dmytro.nester@globallogic.com >
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4020 >
2020-05-25 19:41:09 +00:00
Dmitriy Nester
0e9af02323
nir: replace fnv1a hash function with xxhash
...
xxhash is faster than fnv1a in almost all circumstances, so we're
switching to it globally.
Signed-off-by: Dmytro Nester <dmytro.nester@globallogic.com >
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4020 >
2020-05-25 19:41:09 +00:00
Alyssa Rosenzweig
1d647b1c48
panfrost: Only run batch debug when specifically asked
...
It's expensive and in a hot path; even for general debug builds we won't
need this, only if we're specifically hacking on batch code.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5202 >
2020-05-25 16:01:18 +00:00
Alyssa Rosenzweig
4c5d1e2860
panfrost: Add debug print before query flushes
...
Just so we know if they're happening.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5202 >
2020-05-25 16:01:18 +00:00
Bas Nieuwenhuizen
be784cc77b
radv: Implement vkGetSwapchainGrallocUsage2ANDROID.
...
This was implemented in version 6 of the VK_ANDROID_native_buffer
extension and we only implement version 5. However, the Android
Vulkan loader only checks whether vkGetInstanceProcAddr for the
function is not NULL.
This all went wrong when we switched to the layer code from ANV.
Because the function may now be different per device, it adds fallback
functions that dispatch to the dispatch table. So if we didn't implement
the function we still returned a pointer to the dispatch function,
which made the Android Vulkan loader believe it was supported.
Dispatch functions:
https://gitlab.freedesktop.org/mesa/mesa/-/blob/d555794f3032594dbef3623052103900138d2356/src/amd/vulkan/radv_entrypoints_gen.py#L328
Fixes: d555794f30 "radv: update entrypoints generation from ANV"
Gitlab: https://gitlab.freedesktop.org/mesa/mesa/-/issues/2936
Acked-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5198 >
2020-05-25 15:34:44 +00:00
Simon Ser
9a74746bd1
EGL: sync headers with Khronos
...
Taken from EGL-Registry commit 90b78b0662e2f0548cfd1926fb77bf628933541b.
With this update EGL_WL_bind_wayland_display and
EGL_WL_create_wayland_buffer_from_image are now in the registry, so we
don't need to define them in eglmesaext.h anymore.
The eglSwapBufferWithDamage* functions now take a const rects argument.
The eglapi.c function signature is updated accordingly.
Signed-off-by: Simon Ser <contact@emersion.fr >
Acked-by: Marek Olšák <marek.olsak@amd.com >
Reviewed-by: Eric Engestrom <eric@engestrom.ch >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4953 >
2020-05-25 14:06:38 +00:00
Danylo Piliaiev
045267d1e6
st/mesa: Clear texture's views when texture is removed from Shared->TexObjects
...
If texture is shared between several contexts, calling glDeleteTextures
will remove it from ctx->Shared->TexObjects - which makes impossible for
contexts, when destroyed, to release their views to this texture. Which
leaves dangling pointers to destroyed contexts.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/2960
Signed-off-by: Danylo Piliaiev <danylo.piliaiev@globallogic.com >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5106 >
2020-05-25 12:32:16 +00:00
Bas Nieuwenhuizen
a51ab5f956
radv: Do not close fd -1 when NULL-winsys creation fails.
...
Fixes: cd6ec2b1ab "radv: implement a dummy winsys for creating devices without AMDGPU"
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5181 >
2020-05-25 11:12:07 +00:00
Bas Nieuwenhuizen
cd0c5b64cc
radv: Remove dead code.
...
pool is always non-NULL, and is also accessed before this check
in the function, so remove the pool = NULL case.
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5181 >
2020-05-25 11:12:07 +00:00
Bas Nieuwenhuizen
cd61f5234d
radv: Handle failing to create .cache dir.
...
Fixes: f4e499ec79 "radv: add initial non-conformant radv vulkan driver"
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5181 >
2020-05-25 11:12:07 +00:00
Bas Nieuwenhuizen
906435fb0e
radv/winsys: Remove extra sizeof multiply.
...
The pointer is already uint64_t*, so the sizeof was too much ...
Fixes: eeff7e1154 "radv: Add userspace fence buffer per context."
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5181 >
2020-05-25 11:12:07 +00:00
Michel Dänzer
6c99de98ec
gitlab-ci: Enable -Werror in meson-s390x job
...
It's warning-clean.
v2:
* Prevent -Werror from being enabled in `meson-ppc64le` job as well
Reviewed-by: Eric Engestrom <eric@engestrom.ch >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5185 >
2020-05-25 08:49:25 +00:00
Samuel Pitoiset
b3c0f82841
radv: advertise VK_AMD_texture_gather_bias_lod
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5147 >
2020-05-25 08:51:10 +02:00
Samuel Pitoiset
2e265b94a2
radv: add support for querying which formats support texture gather LOD
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5147 >
2020-05-25 08:51:10 +02:00
Samuel Pitoiset
94570e87bd
aco: add support for bias/lod with texture gather
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5147 >
2020-05-25 08:51:10 +02:00
Samuel Pitoiset
e99c818cf0
ac/nir: add support for bias/lod with texture gather
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5147 >
2020-05-25 08:51:10 +02:00
Samuel Pitoiset
41dc3ce449
spirv: add support for bias/lod with OpImageGather
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5147 >
2020-05-25 08:51:10 +02:00
Samuel Pitoiset
dd39bf52b0
spirv: add SpvCapabilityImageGatherBiasLodAMD
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5147 >
2020-05-25 08:51:10 +02:00
Yevhenii Kolesnikov
c7943343a0
glsl: subroutine signatures must match exactly
...
From GLSL 4.60.7 spec, section 6.1.2 "Subroutines":
It is a compile-time error if arguments and return type don’t match
between the function and each associated subroutine type.
Before, if subroutine type and implementation function were declared
with types, that could be implicitly converted, it led to a runtime crash.
Signed-off-by: Yevhenii Kolesnikov <yevhenii.kolesnikov@globallogic.com >
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5125 >
2020-05-24 23:55:44 +00:00
Samuel Pitoiset
5bc18b79a4
radv: advertise shaderDeviceClock on GFX8+
...
Unsupported on GFX6-GFX7.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5117 >
2020-05-24 20:37:59 +02:00
Samuel Pitoiset
14292310d9
ac/nir: implement nir_intrinsic_shader_clock with device scope
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5117 >
2020-05-24 20:37:58 +02:00
Samuel Pitoiset
b034f6cf2a
ac/nir: fix shader clock with subgroup scope
...
The compiler should emit s_memtime instead of s_memrealtime for
the subgroup scope. I don't know why this LLVM 9 checks was for
but LLVM 8 also has this amdgcn intrinsic.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5117 >
2020-05-24 20:37:54 +02:00
Samuel Pitoiset
cecd4aad46
aco: implement nir_intrinsic_shader_clock with device scope
...
Use s_memrealtime instead.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5117 >
2020-05-24 20:37:52 +02:00
Samuel Pitoiset
37c88c670f
spirv: add ReadClockKHR support with device scope
...
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com >
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5117 >
2020-05-24 20:37:50 +02:00