Eric Anholt
1eb79dfade
util/xmlconfig: Add a unit test of the code.
...
I want to build a non-XML-based alternative for Android, and to do that I
want to know that my equivalent code still works.
Reviewed-by: Kristian H. Kristensen <hoegsberg@google.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6753 >
2020-09-25 19:36:23 +00:00
Nanley Chery
7f3e881c6c
blorp: Ensure aligned HIZ_CCS_WT partial clears
...
Fixes: 5425fcf2cb
("intel/blorp: Satisfy HIZ_CCS fast-clear alignments")
Reported-by: Sagar Ghuge <sagar.ghuge@intel.com >
Tested-by: Ivan Briano <ivan.briano@intel.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6854 >
2020-09-25 19:18:51 +00:00
zhu yong
7898993bcd
meson: add support for loongson's mips/mips64 arch.
...
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6836 >
2020-09-25 17:04:04 +00:00
Samuel Iglesias Gonsálvez
b54a0bb528
freedreno/layout: add tile_all flag to the layout
...
Added a new tile_all flag which is used to set the TILE_ALL flag of
the texture. Enabled tile_all to depth/stencil images are they are
non-linear.
Signed-off-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com >
Reviewed-by: Jonathan Marek <jonathan@marek.ca >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6848 >
2020-09-25 15:38:47 +00:00
Jason Ekstrand
0206fb3941
nir/liveness: Consider if uses in nir_ssa_defs_interfere
...
Fixes: f86902e75d
"nir: Add an SSA-based liveness analysis pass"
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3428
Reviewed-by: Eric Anholt <eric@anholt.net >
Reviewed-by: Yevhenii Kharchenko <yevhenii.kharchenko@globallogic.com >
Reviewed-by: Connor Abbott <cwabbott0@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6824 >
2020-09-25 14:16:15 +00:00
Jonathan Marek
dcba32bac0
turnip: implement VK_EXT_extended_dynamic_state
...
Passes dEQP-VK.pipeline.extended_dynamic_state.*
Signed-off-by: Jonathan Marek <jonathan@marek.ca >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5641 >
2020-09-25 12:59:02 +00:00
Jonathan Marek
b2fa2d99ae
turnip: move A6XX_RB_ALPHA_CONTROL write to init_hw
...
Its always 0.
Signed-off-by: Jonathan Marek <jonathan@marek.ca >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5641 >
2020-09-25 12:59:02 +00:00
Jonathan Marek
d1588c78ab
turnip: fix wrong indentation in tu6_draw_common
...
Signed-off-by: Jonathan Marek <jonathan@marek.ca >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5641 >
2020-09-25 12:59:02 +00:00
Rhys Perry
a18c84ecce
nir/instr_set: hash intrinsic sources
...
ministat (CSE only):
Difference at 95.0% confidence
-9.80325 +/- 0.173089
-41.4434% +/- 0.461972%
(Student's t, pooled s = 0.0763653)
ministat (entire run):
Difference at 95.0% confidence
-3.13667 +/- 0.61519
-5.11107% +/- 0.990737%
(Student's t, pooled s = 0.271416)
Signed-off-by: Rhys Perry <pendingchaos02@gmail.com >
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Reviewed-by: Matt Turner <mattst88@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6860 >
2020-09-25 10:18:36 +00:00
Andreas Baierl
b8c31ac06d
lima: fix glCopyTexSubImage2D
...
The reload texture descriptor needs to take care of the mipmap level
and the layer in case of GL_TEXTURE_CUBE_MAP.
glCopyTexSubImage2D triggers the lima_blit function which ends in a draw.
A reload is necessary. The reload texture descriptor is always built with
just one mipmap level, but this needs to be the level we want to reload,
not just 0. We also have to take care of the cubemap face.
This fixes the following dEQP tests:
dEQP-GLES2.functional.texture.specification.basic_copytexsubimage2d.2d_rgb
dEQP-GLES2.functional.texture.specification.basic_copytexsubimage2d.2d_rgba
dEQP-GLES2.functional.texture.specification.basic_copytexsubimage2d.cube_rgb
dEQP-GLES2.functional.texture.specification.basic_copytexsubimage2d.cube_rgba
Reviewed-by: Erico Nunes <nunes.erico@gmail.com >
Signed-off-by: Andreas Baierl <ichgeh@imkreisrum.de >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6816 >
2020-09-25 10:11:36 +00:00
Guido Günther
7b9cf779f2
kmsro: Extend to include imx-dcss
...
This allows using the dcss display controllers (with the dcss drm
modesetting driver) along with the Etnaviv render-only drivers. DCSS is
found on i.MX SoCs.
Signed-off-by: Guido Günther <agx@sigxcpu.org >
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3449 >
2020-09-25 09:55:15 +00:00
Danylo Piliaiev
77486db867
intel/fs: Disable sample mask predication for scratch stores
...
Scratch stores are being lowered to the instructions with side-effects,
however they should be enabled in fs helper invocations, since they
are produced from operations which don't imply side-effects.
To fix this - we move the decision of whether the sample mask predication
is enable to the point where logical brw instructions are created.
GLSL example of the issue:
int tmp[1024];
...
do {
// changes to tmp
} while (some_condition(tmp))
If `tmp` is lowered to scrach memory, `some_condition` would be
undefined if scratch write is predicated on sample mask, making
possible for the while loop to become infinite and hang the GPU.
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3256
Fixes: 53bfcdeecf
Signed-off-by: Danylo Piliaiev <danylo.piliaiev@globallogic.com >
Reviewed-by: Matt Turner <mattst88@gmail.com >
Acked-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6056 >
2020-09-25 09:48:06 +00:00
Erik Faye-Lund
cbef2dc7d3
zink: only set stencil-ref for back if two-sided
...
Otherwise, we want to set both front and back to the same state.
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6853 >
2020-09-25 09:16:27 +00:00
Erik Faye-Lund
4b2525b68d
zink: store base-object of DSA-state
...
This is useful in the next commit, where we need to inspect the
base-state.
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6853 >
2020-09-25 09:16:27 +00:00
Erik Faye-Lund
9e94dcca67
zink: correct typo in stencil-setup
...
Without this, we end up using two-sided stencil when one-sided stencil
should be used. Whoops.
Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6853 >
2020-09-25 09:16:27 +00:00
Marek Olšák
d1d27e9db4
radeonsi: remove redundant info.uses_fbfetch
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6782 >
2020-09-25 04:37:23 -04:00
Marek Olšák
7b1e01fec7
radeonsi: remove redundant variables from struct si_compute
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6782 >
2020-09-25 04:37:23 -04:00
Marek Olšák
16afaf0355
radeonsi: assume that constant load_local_group_size has been optimized out
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6782 >
2020-09-25 04:37:23 -04:00
Marek Olšák
0492adaca7
radeonsi: run NIR optimizations that glsl_to_nir runs but other places might not
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6782 >
2020-09-25 04:37:23 -04:00
Marek Olšák
8a1d556c5a
radeonsi: get input/output usage flags from shader_info directly
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6782 >
2020-09-25 04:37:23 -04:00
Marek Olšák
0280cc75ba
radeonsi: get information about FS color outputs from shader_info directly
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6782 >
2020-09-25 04:37:23 -04:00
Marek Olšák
343e5caa75
radeonsi: use info.system_values_read
...
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6782 >
2020-09-25 04:37:23 -04:00
Marek Olšák
cce3556abd
radeonsi: call nir_shader_gather_info after lowering and optimizing NIR
...
to get more accurate info
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6782 >
2020-09-25 04:37:23 -04:00
Marek Olšák
8be46d6558
radeonsi: fix indirect dispatches with variable block sizes
...
The block size input was uninitialized.
Fixes: 77c81164bc
"radeonsi: support ARB_compute_variable_group_size"
Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6782 >
2020-09-25 04:37:23 -04:00
Christian Gmeiner
a7e3cc7a0e
etnaviv: simplify linear stride implementation
...
As documented in the galcore kernel driver "only LOD0 is valid
for this register". This makes sense, as NTE's LINEAR_STRIDE is
only capable to store one linear stride value per sampler.
This fixes linear textures in sampler slot != 0.
Fixes: 34458c1cf6
("etnaviv: add linear sampling support")
CC: <mesa-stable@lists.freedesktop.org >
Signed-off-by: Christian Gmeiner <christian.gmeiner@gmail.com >
Reviewed-by: Michael Tretter <m.tretter@pengutronix.de >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3285 >
2020-09-25 08:03:17 +00:00
Boris Brezillon
f7583bda8f
ci: Extend meson-clang coverage by compiling all gallium drivers
...
Some compile-time regressions go unnoticed because not all gallium
drivers are compiled as part of the meson-clang job. Let's pass an
explicit list of drivers to compile instead of setting GALLIUM_DRIVERS
to "auto" to increase CI coverage.
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Acked-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6811 >
2020-09-25 09:08:34 +02:00
Boris Brezillon
1dd4505bc1
panfrost: gen_pack: Fix gnu-empty-initializer errors
...
Fixes: 1b27817f17
("panfrost: gen_pack: Allow empty structs")
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com >
Tested-by: Vinson Lee <vlee@freedesktop.org >
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com >
Reviewed-by: Tomeu Vizoso <tomeu.vizoso@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6811 >
2020-09-25 09:07:45 +02:00
Marek Olšák
ea77958fea
nir: gather information about fbfetch and dual source color
...
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6758 >
2020-09-25 02:29:30 -04:00
Marek Olšák
a6abf175ef
nir: fix input/output info gathering for lowered IO
...
Ooops.
Fixes: 17af07024d
- nir: gather all IO info from IO intrinsics
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6758 >
2020-09-25 02:29:30 -04:00
Marek Olšák
ef98c175c0
nir: gather fs.uses_sample_qualifier from lowered IO
...
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6758 >
2020-09-25 02:29:30 -04:00
Marek Olšák
7b108e6ac4
nir: set system_values_read for all intrinsics
...
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6758 >
2020-09-25 02:29:30 -04:00
Marek Olšák
abe9588ff0
nir: gather tess.tcs_cross_invocation info from lowered IO intrinsics
...
Reviewed-by: Eric Anholt <eric@anholt.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6758 >
2020-09-25 02:29:30 -04:00
Marek Olšák
10be706778
nir: gather indirect info from lowered IO intrinsics
...
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6758 >
2020-09-25 02:29:30 -04:00
Jason Ekstrand
3173367a47
spirv: vtn_fail with a nice message on unsupported rounding modes
...
Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6845 >
2020-09-25 01:43:28 +00:00
Vinson Lee
03e7b75c22
gallium/dri2: Move image->texture assignment after image NULL check.
...
Fix defect reported by Coverity Scan.
Dereference before null check (REVERSE_INULL)
check_after_deref: Null-checking image suggests that it may be
null, but it has already been dereferenced on all paths leading to
the check.
Fixes: ad609bf55a
("frontend/dri: Implement mapping individual planes.")
Signed-off-by: Vinson Lee <vlee@freedesktop.org >
Reviewed-by: Tapani Pälli <tapani.palli@intel.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6807 >
2020-09-25 00:47:26 +00:00
Vinson Lee
4bd0df0e4a
r600/sfn: Initialize GPRValue member m_pin_to_channel.
...
Fix defects reported by Coverity Scan.
Uninitialized scalar field (UNINIT_CTOR)
uninit_member: Non-static class member m_pin_to_channel is not
initialized in this constructor nor in any functions that it calls.
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/6830 >
2020-09-24 17:29:04 -07:00
Eric Anholt
974981c4e6
gallium/drm: Make the pipe loader handle the driconf merging.
...
We can pretty easily handle merging the driver's driconf with the common
driverconf right there, rather than pushing that to each driver.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6751 >
2020-09-24 16:35:17 -07:00
Eric Anholt
87392385b5
gallium/drm: Define the DRM entrypoints in drm_helper.h
...
This cuts even more code duplication.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6751 >
2020-09-24 16:35:17 -07:00
Eric Anholt
bc10b4968e
gallium/drm: Refactor the stub screen create functions.
...
This gives me one place to document why it works this way. This does make
the debug message a little less helpful ("etna" instead of "etnaviv" and
"vmwgfx" instead of "svga", but you should only be able to reach this when
doing something like trying the radeon/nouveau vdpau target on the wrong
DRM device for example.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6751 >
2020-09-24 15:34:52 -07:00
Eric Anholt
9ec28b8d22
gallium/drm: Deduplicate screen creation for the dynamic (clover) pipe loader.
...
We can just reuse drm_helper.h, which has either the real code or the stub
for all pipe_screens based on the GALLIUM_* driver defines, and the
dynamic pipe loader's .c build will only define one GALLIUM_* driver
define. The remaining stubs should get GCed by the linker.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6751 >
2020-09-24 15:34:52 -07:00
Jason Ekstrand
472a20c5fc
radeonsi: Only call nir_lower_var_copies at the end of the opt loop
...
In 283ad85944
, radeonsi started using nir_find_var_copies. However,
it was also calling nir_lower_var_copies in the optimization loop and
the two can end up fighting. The simple solution is to wait to lower
copies until the end of the optimization loop.
Fixes: 283ad85944
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3550
Reviewed-by: Marek Olšák <marek.olsak@amd.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6841 >
2020-09-24 21:01:30 +00:00
Mike Blumenkrantz
7971918924
zink: reorder create_stream_output_target to fix failure case leak
...
the previous version of this leaked a reference to the streamout buffer here
thanks to deltragon on my blog for pointing this out!
Fixes: 37778fcd9a
("zink: implement transform feedback support to finish off opengl 3.0")
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6457 >
2020-09-24 20:55:02 +00:00
Mike Blumenkrantz
bc5c0433be
zink: apply viewport count when creating pipelines
...
without VK_EXT_extended_dynamic_state, we need to pass this directly or
else only the first viewport will work
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6349 >
2020-09-24 20:48:51 +00:00
Mike Blumenkrantz
cc939fe9b7
zink: correctly set up fb-sized scissors for each viewport
...
each viewport must have a corresponding scissor, so we need to generate
an array of these to ensure our states match up
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6349 >
2020-09-24 20:48:51 +00:00
Mike Blumenkrantz
8a2ddcb4a9
zink: set multiviewport cap in ntv when gl_ViewportIndex is a written output
...
this cap varies based on the shader stage, but it must be enabled any time this
output is written
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6349 >
2020-09-24 20:48:51 +00:00
Mike Blumenkrantz
09be30b9e4
zink: move viewport count to zink_gfx_pipeline_state
...
this is part of the pipeline state (there's an extension for setting it
dynamically but we don't supprot that atm
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6349 >
2020-09-24 20:48:51 +00:00
Mike Blumenkrantz
818bd61099
zink: implement ARB_instanced_arrays
...
this is just a simple case of connecting up the vertex state to the pipeline
state
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6270 >
2020-09-24 20:40:39 +00:00
Mike Blumenkrantz
0051551701
zink: verify that src and dst aspects are the same in resource_copy_region hook
...
this is required by spec
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6263 >
2020-09-24 20:31:37 +00:00
Mike Blumenkrantz
6feec2d40e
zink: clamp min created fb size to 1x1
...
this is required by spec
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6263 >
2020-09-24 20:31:37 +00:00
Mike Blumenkrantz
9ce1e99913
zink: use correct layer count when creating framebuffer
...
pipe_framebuffer_state::layers doesn't necessarily reflect the value we
need to use here, so we can use the util function to verify
Reviewed-by: Erik Faye-Lund <erik.faye-lund@collabora.com >
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6263 >
2020-09-24 20:31:37 +00:00