Thomas H.P. Andersen
458801e2c3
broadcom/compiler: use correct flag enum
...
They have the same value, so no functional change
Reviewed-by: Iago Torral Quiroga <itoral@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11764 >
2021-07-12 11:54:03 +00:00
Lionel Landwerlin
91dcbf1f56
intel/compiler: Track latency/perf of LSC fences
...
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com >
Reviewed-by: Sagar Ghuge <sagar.ghuge@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11759 >
2021-07-12 11:39:03 +00:00
Icecream95
48af341b36
panfrost: Fix GPU ID for t76x in get_perf_config
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11824 >
2021-07-12 09:07:48 +00:00
Iago Toral Quiroga
642812239e
v3dv: expose geometry shaders
...
A run of dEQP-VK.*geom* has 6328 test passes and 16 failures. 14 of
these failures are related to a CTS bug affecting atomic operations
for which I submitted a CL to Khronos. Another fail looks like it might
be a case of the error threshold in CTS being slightly low. There is
only one test fail in that list that looks like it might be an actual
driver bug, but it is a variable pointers test, so it might be unrelated
to geometry shaders in the end.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 09:25:28 +02:00
Iago Toral Quiroga
126eb5c8b9
broadcom/ci: update expected fails for v3dv after enabling geometry shaders
...
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 09:25:28 +02:00
Iago Toral Quiroga
c188d06326
v3dv: remove deferred vkCmdClearAtachments path
...
This was required to handle the case of secondary command buffers that
did not have framebuffer information available from the primary, since
we used to have an implementation that required this information to
be available for the fallback path of vkCmdClearAttachments. Now that
we can handle our our attachment clears in the current subpass by
emitting draw calls, we no longer need the framebuffer information to
be available and we can remove this.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 09:25:28 +02:00
Iago Toral Quiroga
5ba7f64b45
v3dv: remove fallback path for vkCmdClearAttachments
...
Now that we support layered clears this code is dead.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 09:25:28 +02:00
Iago Toral Quiroga
26d1c6893a
v3dv: implement layered attachment clears
...
Now that we have geometry shaders, we can leverage this to implement
clears of layered framebuffers by adding a geometry shader in our
clear pipelines that redirects the clear rect to the appropriate
layer in the framebuffer, instead of falling back to emitting separate
clear jobs for each layer, which is a lot slower.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 09:25:28 +02:00
Iago Toral Quiroga
ee11e9183d
broadcom/compiler: don't ignore constant offset on per-vertex input loads
...
Fixes:
dEQP-VK.clipping.user_defined.clip_distance.vert_geom.{5,6,7,8}
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:56 +02:00
Iago Toral Quiroga
e1a24a0047
broadcom/compiler: handle compact input arrays for geometry shaders
...
Clip distance arrays will come as compact array variables, so we need
to handle them as such, like we did for vertex inputs.
Fixes:
dEQP-VK.clipping.user_defined.clip_distance.vert_geom.{1,2,3,4}
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:56 +02:00
Iago Toral Quiroga
df1d08533c
v3dv: fix copy buffer to image TFU path for 3D images
...
This bug was exposed by the following CTS tests (requires
geometry shaders):
dEQP-VK.geometry.layered.3d.*.readback
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:56 +02:00
Iago Toral Quiroga
31a786c80a
v3dv: handle QUNIFORM_FB_LAYERS
...
There is a bit of a corner case here for secondary buffers that
don't inherit framebuffer information, since those won't have
access to the number of layers in the framebuffer by the time
we get here. Since we only emit this to sanitize the value of
gl_Layer produced from geometry shaders, I think it is probably
fine to lie about it and just use the maximum number of layers
we support. The only issue with that is that broken shaders that
emit out of bounds layer indices (which the spect states may lead
to unfined shading results) may cause undefined results.
In the future we could do better and patch the uniform streams
later when the secondary is executed inside a primary, since we
will have the required framebuffer information at that point,
but for now this seems like a reasonable compromise.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:55 +02:00
Iago Toral Quiroga
991cca2e77
v3dv: emit state packets for geometry shaders
...
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:55 +02:00
Iago Toral Quiroga
353f0a180f
broadcom/compiler: create a helper for computing VPM config
...
This code is the same across drivers.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:55 +02:00
Iago Toral Quiroga
9e7d9a6efb
v3dv: add support for geometry shaders to pipelines
...
This gets our graphics pipelines (and pipeline cache) to accept
and compile geometry shader modules.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:55 +02:00
Iago Toral Quiroga
2733a17b14
broadcom/compiler: track if geometry shaders write gl_PointSize
...
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:55 +02:00
Iago Toral Quiroga
4c94f93413
v3dv: add a few more broadcom shader stage helpers
...
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:55 +02:00
Iago Toral Quiroga
9803336016
v3dv: define a generic helper to create binning pipeline stages
...
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:55 +02:00
Iago Toral Quiroga
81b22d5aba
v3dv: extend broadcom stages to include geometry
...
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:55 +02:00
Iago Toral Quiroga
d448dafcd4
v3dv: always free pipeline stages after compiling
...
We were not freeing this when the pipeline was loaded from the cache.
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11783 >
2021-07-12 08:35:55 +02:00
Dave Airlie
8dcd4e4849
crocus: add GL_CLAMP emulation in driver again.
...
I removed this because I thought the state tracker could handle it,
and it really should handle it, but it has some minecraft side effects
I'm unsure about. This fixes the problem for now, we can revisit it later.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11822 >
2021-07-12 15:18:13 +10:00
Dave Airlie
ead3340262
crocus/gen8: fix wrap mode needs border color.
...
missing piece here.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11821 >
2021-07-12 14:24:35 +10:00
Alyssa Rosenzweig
dd98918a5a
agx: Flip point coordinates because OpenGL
...
Fixes dEQP-GLES2.functional.shaders.builtin_variable.pointcoord
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11818 >
2021-07-11 22:32:41 +00:00
Alyssa Rosenzweig
3291779c21
asahi: Handle point coordinates
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11818 >
2021-07-11 22:32:41 +00:00
Alyssa Rosenzweig
3d75cff7d7
asahi: Identify triangle/lines vs point varyings
...
Seems to allow skipping over point coords?
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11818 >
2021-07-11 22:32:41 +00:00
Alyssa Rosenzweig
e2176490d6
asahi: Unpack varying descriptors (1x)
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11818 >
2021-07-11 22:32:41 +00:00
Alyssa Rosenzweig
d37bb48211
asahi: Lower PIPE_CAPF_MAX_POINT_WIDTH to hw limit
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11818 >
2021-07-11 22:32:41 +00:00
Alyssa Rosenzweig
2468b123bb
asahi: Set bit for psiz
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11818 >
2021-07-11 22:32:41 +00:00
Alyssa Rosenzweig
88a8d7f76f
asahi: Set point magic bit in rasterizer
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11818 >
2021-07-11 22:32:41 +00:00
Alyssa Rosenzweig
af2a4bc163
asahi: Set bits in UNK11 needed for points
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11818 >
2021-07-11 22:32:41 +00:00
Mike Blumenkrantz
73f6bff07f
zink: fix mem info query to be more permissive
...
airlied was right, this was way too conservative
Fixes: ff4ba3d4a7
("zink: support PIPE_CAP_QUERY_MEMORY_INFO")
Reviewed-by: Dave Airlie <airlied@redhat.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11803 >
2021-07-11 20:18:16 +00:00
Alyssa Rosenzweig
05dc72f863
asahi/decode: Print some IOGPU stuff
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-11 14:49:00 -04:00
Alyssa Rosenzweig
da85e84206
asahi/decode: Print clear/store pipelines
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-11 14:48:59 -04:00
Alyssa Rosenzweig
15206428b9
asahi: Garbage collect senseless cmdbuf struct
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-11 14:48:59 -04:00
Alyssa Rosenzweig
bd9317dbe7
asahi: Consolidate some magic numbers
...
This is a bunch of software data structures concatenated, not a true command
buffer like previously thought.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-11 14:48:59 -04:00
Alyssa Rosenzweig
2f032283f8
asahi: Allocate global IDs
...
Use the same UABI as Metal. One less hack, trying to rule out possible
differences to Metal...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-11 14:48:59 -04:00
Alyssa Rosenzweig
87c4a1855c
asahi: Allow specifying an encoder ID
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-11 14:48:59 -04:00
Alyssa Rosenzweig
314324f320
asahi/decode: Fix decoding of draw calls
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-11 14:48:42 -04:00
Alyssa Rosenzweig
ed4b3a5d17
asahi/decode: Handle CULL packets
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-10 12:34:40 -04:00
Alyssa Rosenzweig
9854079d59
asahi/decode: Fix up high word
...
Not sure what's happening here, there's some magic for sure.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-10 12:34:40 -04:00
Alyssa Rosenzweig
d5580ee805
asahi: Identify more unknown fields in the memmap
...
From validating the memory map of a Metal sample and seeing what goes wrong.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-10 12:05:34 -04:00
Alyssa Rosenzweig
0eb4a4dd79
asahi: Reserve more space to stop a command buffer
...
Let's be safer.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-10 11:24:49 -04:00
Alyssa Rosenzweig
a9b8731fa1
asahi/decode: Check fewer zeroes after a command buffer
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-10 11:23:50 -04:00
Alyssa Rosenzweig
0b35a8f81a
asahi: Make track_free safer
...
Ensure that we don't free the same BO multiple times, which can lead to later
segfaults in decode.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-10 11:16:56 -04:00
Alyssa Rosenzweig
9b6ca87672
asahi/decode: Only dump mapped allocations
...
This matches the hardware's view of memory and helps catch spurious reads. (One
symptom of messing this up -- besides broken rendering -- is a kernel warning
about a "bogus texture handle 0".)
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-10 11:04:45 -04:00
Alyssa Rosenzweig
ea7892a74c
asahi: Remove unused bo_access property
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-10 11:01:25 -04:00
Alyssa Rosenzweig
aa36b4b202
asahi: Add missing copyright/guards for magic.c/h
...
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-10 10:51:06 -04:00
Alyssa Rosenzweig
0a7e22a968
asahi: Move fixed internal shaders to agx_blit.c
...
A more natural place to put them, as the clear/store shaders use a similar
mechanism as the reload shaders. Now magic.c is exclusively kernel side piping.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11815 >
2021-07-10 10:49:58 -04:00
Alyssa Rosenzweig
c70f45c759
panfrost: Set register allocation in the v7 RSD
...
Required to hit full occupancy. Now that this information is piped
through the compiler, we can do this correctly.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11733 >
2021-07-09 23:15:28 +00:00
Alyssa Rosenzweig
4a79bbdb38
panfrost: Generalize pan_blitter's reg count assert
...
Needed to avoid crashing on Bifrost/Valhall.
Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11733 >
2021-07-09 23:15:28 +00:00