George Kyriazis [Sat, 27 Jan 2018 06:19:07 +0000 (00:19 -0600)]
swr/rast: Remove some JIT debug code
Reviewed-by: Bruce Cherniak <bruce.cherniak@intel.com>
George Kyriazis [Sat, 27 Jan 2018 01:20:41 +0000 (19:20 -0600)]
swr/rast: Don't include private context in gather args
Move mpPrivateContext to compensate
Reviewed-by: Bruce Cherniak <bruce.cherniak@intel.com>
George Kyriazis [Fri, 26 Jan 2018 22:01:56 +0000 (16:01 -0600)]
swr/rast: Cleanup knob definitions
Rename some of the categories and move some options around.
Reviewed-by: Bruce Cherniak <bruce.cherniak@intel.com>
George Kyriazis [Thu, 25 Jan 2018 03:54:46 +0000 (21:54 -0600)]
swr/rast: Add missing parameter to a few gather functions
We now pass pDrawContext as a default parameter
Reviewed-by: Bruce Cherniak <bruce.cherniak@intel.com>
Philipp Zabel [Mon, 12 Feb 2018 14:25:26 +0000 (15:25 +0100)]
etnaviv: add useful information to BO import errors
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Daniel Stone [Thu, 15 Feb 2018 09:17:52 +0000 (09:17 +0000)]
egl/wayland: Always use in-tree wayland-egl-backend.h
A recent patchset to Wayland[0] migrated Mesa's libwayland-egl backend
into Wayland itself, so implementations could provide backends. Mesa
still uses its own, and the two have already diverged[1].
The include from egl_dri2.h could pick up either the installed Wayland
wayland-egl-backend.h (with a 'driver_private' member), or the Mesa
internal wayland-egl-backend.h (with a 'private' member), failing the
build in the first instance.
Add an explicit directory prefix to the include, so we always get our
in-tree version.
[0]: https://patchwork.freedesktop.org/series/31663/
[1]: https://cgit.freedesktop.org/wayland/wayland/commit/?id=
9fa60983b579
Signed-off-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105103
Fixes:
198af27c679c ("wayland-egl: rename wayland-egl-{priv,backend}.h")
Daniel Stone [Thu, 25 Jan 2018 08:29:38 +0000 (08:29 +0000)]
meson: Move Wayland dmabuf to wayland-drm
As the comment notes: linux-dmabuf has nothing to do with wayland-drm,
but we need a single place to build these files we can use from both EGL
and Vulkan, which is guaranteed to be included before both EGL and
Vulkan WSI.
Signed-off-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.co.uk>
Eric Engestrom [Thu, 15 Feb 2018 11:10:22 +0000 (11:10 +0000)]
egl/wayland: check for invalid format index
v2: just tell the compiler to assume the format will always be found, as
it comes from the table itself to begin with. (DanielS)
CID: 1429516
Fixes:
d32b23f3830099a328b91 "egl/wayland: Add bpp to visual map"
Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Eric Engestrom [Thu, 15 Feb 2018 10:59:24 +0000 (10:59 +0000)]
glsl: fix sizeof(pointer) bug
Doesn't really change anything to the test though ¯\_(ツ)_/¯
CID: 1429511
Fixes:
e8495646afb06a9dd7786 "glsl/tests: changes to test_disk_cache_create test"
Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Timothy Arceri [Thu, 15 Feb 2018 04:08:49 +0000 (15:08 +1100)]
radeonsi/nir: set TGSI_PROPERTY_FS_EARLY_DEPTH_STENCIL correctly
We set this for post_depth_coverage in addition to early_fragment_tests.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Dave Airlie [Wed, 14 Feb 2018 02:52:27 +0000 (12:52 +1000)]
virgl: remap query types to hw support.
The gallium query types changed, so we need to remap from the
gallium ones to the virgl ones.
Fixes:
dEQP-GLES3.functional.transform_feedback.basic_types*
"This also fixes:
dEQP-GLES3.functional.transform_feedback.array.separate*
dEQP-GLES3.functional.transform_feedback.array_element*
dEQP-GLES3.functional.transform_feedback.interpolation.*
Gallium's p_defines.h and virglrenderer's p_defines.h have diverged
quite a bit, so not including
PIPE_QUERY_OCCLUSION_PREDICATE_CONSERVATIVE there makes sense for now."
- Gurchetan Singh
Fixes:
3f6b3d9db (gallium: add PIPE_QUERY_OCCLUSION_PREDICATE_CONSERVATIVE)
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Tested-by: Gurchetan Singh <gurchetansingh@chromium.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Anuj Phogat [Wed, 17 Jan 2018 22:33:17 +0000 (14:33 -0800)]
i965/icl: Add render target flush after uploading binding table
From PIPE_CONTROL command description in gfxspecs:
"Whenever a Binding Table Index (BTI) used by a Render Taget Message
points to a different RENDER_SURFACE_STATE, SW must issue a Render
Target Cache Flush by enabling this bit. When render target flush
is set due to new association of BTI, PS Scoreboard Stall bit must
be set in this packet."
V2: Move the PIPE_CONTROL to update_renderbuffer_surfaces() in
brw_wm_surface_state.c (Ken).
Fixes a fulsim error and a GPU hang described in below JIRA.
JIRA: MD5-322
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Fri, 3 Nov 2017 21:48:29 +0000 (14:48 -0700)]
i965/icl: Enable float blend optimization and Wa3DStateMode
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Wed, 14 Feb 2018 22:30:27 +0000 (14:30 -0800)]
intel/common/icl: Add has_sample_with_hiz flag in gen_device_info
Sampling from hiz is enabled in i965 for GEN9+ but this feature has
been removed from gen11. So, this new flag will be useful to turn
the feature on/off for different gen h/w. It will be used later
in a patch adding device info for gen11.
Suggested-by: Kenneth Graunke <kenneth@whitecape.org>
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Wed, 7 Feb 2018 00:47:04 +0000 (16:47 -0800)]
i965/icl: Add assertions to check dispatch mode is SIMD8
SIMD4x2 dispatch mode has been removed in GEN11. We're not using
it anyways in Mesa. Adding few asserts to make it explicit.
Use GEN_GEN macro in place of devinfo->gen (Ken)
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Fri, 18 Aug 2017 19:11:38 +0000 (12:11 -0700)]
i965/icl: Update switch statements
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Thu, 20 Jul 2017 23:21:03 +0000 (16:21 -0700)]
i965/icl: Update the assert in brw_memory_barrier()
Nothing is changed here from gen10 to gen11. So, just update
the assert.
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Wed, 10 May 2017 17:49:04 +0000 (10:49 -0700)]
i965/icl: Define and use icl mocs settings
Gen11 MOCS settings are duplicate of Gen10 MOCS settings.
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Fri, 5 May 2017 20:55:10 +0000 (13:55 -0700)]
i965/icl: Update the comment for maximum number of threads per PSD
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Thu, 20 Jul 2017 23:00:36 +0000 (16:00 -0700)]
i965/icl: Build and use gen11 functions for genxml state-upload and blorp
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
Anuj Phogat [Wed, 24 May 2017 20:58:37 +0000 (13:58 -0700)]
i965/icl: Don't set ResetGatewayTimer
This field is removed in gen11+
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Tue, 27 Jun 2017 21:46:26 +0000 (14:46 -0700)]
intel/icl: Do StateCacheInvalidation for indirect clear color
StateCacheInvalidation is required on all gen7+ platforms. We
don't need to update this check for every new gen h/w unless
this requirement is changed. So, dropping the check for latest
gen h/w.
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Thu, 20 Jul 2017 22:59:49 +0000 (15:59 -0700)]
intel/isl/icl: Build and use gen11 surface state emit functions
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
Anuj Phogat [Fri, 19 May 2017 19:13:40 +0000 (12:13 -0700)]
intel/isl/icl: Add the maximum surface size limit
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Tue, 16 May 2017 23:47:07 +0000 (16:47 -0700)]
intel/genxml/icl: Update genx_bits header
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Anuj Phogat [Wed, 10 May 2017 17:50:15 +0000 (10:50 -0700)]
intel/genxml/icl: Generate packing headers
Move build system changes in to one patch (Ken, Emil)
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Dylan Baker <dylan@pnwbakers.com>
Anuj Phogat [Thu, 15 Feb 2018 18:39:00 +0000 (10:39 -0800)]
intel/genxml/icl: Add gen11.xml
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Kenneth Graunke [Mon, 12 Feb 2018 15:14:22 +0000 (07:14 -0800)]
i965: Drop EXEC_OBJECT_CAPTURE defines.
These only existed to avoid making people update libdrm for new uABI
headers. A while ago we imported those headers into the Mesa repo,
so the dependency is gone and these are no longer useful.
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Jan Vesely [Thu, 15 Feb 2018 19:00:38 +0000 (14:00 -0500)]
clover: Fix build after llvm r325155 and r325160
r325155 ("Pass a reference to a module to the bitcode writer.")
and
r325160 ("Pass module reference to CloneModule")
change function interface from pointer to reference.
v2: Fix indentation (tab instead of spaces)
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Bas Nieuwenhuizen [Thu, 15 Feb 2018 20:24:35 +0000 (21:24 +0100)]
radv: Always lower indirect derefs after nir_lower_global_vars_to_local.
Otherwise new local variables can cause hangs on vega.
CC: <mesa-stable@lists.freedesktop.org>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105098
Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Dylan Baker [Wed, 17 Jan 2018 18:20:54 +0000 (10:20 -0800)]
meson: fix xvmc target linkage
This needs to link the state tracker with --whole-archive to expose the
right symbols.
v4: - Always add libswdri and libswkmsdri to the link_with list
Fixes:
22a817af8a89eb3c7 ("meson: build gallium xvmc state tracker")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Wed, 17 Jan 2018 18:12:19 +0000 (10:12 -0800)]
meson: Fix xa target linkage
This needs to use --whole-archive (link_whole in meson) to properly
expose symbols.
v4: - Always add libswdri and libswkmsdri to link_with list
Fixes:
0ba909f0f111824 ("meson: build gallium xa state tracker")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Wed, 17 Jan 2018 18:12:19 +0000 (10:12 -0800)]
meson: Fix omx-bellagio target linkage
This needs to use --whole-archive (link_whole in meson) to properly
expose symbols.
v4: - Always add libswdri and libswkmsdri to link_with
Fixes:
1d36dc674d528b93b ("meson: build gallium omx state tracker")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Wed, 17 Jan 2018 17:49:55 +0000 (09:49 -0800)]
meson: fix va target linkage
The state tracker needs to be linked with whole-archive (like
autotools). As a result there are symbols from libswdri and libswkmsdri
that are needed, so link those as well.
v4: - Always add libswdri and libswkmsdri to link_with list
Fixes:
5a785d51a6d6 ("meson: build gallium va state tracker")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Thu, 11 Jan 2018 17:22:24 +0000 (09:22 -0800)]
meson: fix vdpau target linkage
The VDPAU state tracker needs to be linked with whole-archive (autotools
does this). Because we are linking the whole archive we alos need to
link with libswdri and libswkmsdri if those have been enabled.
v4: - Always add libswdri and libswkmsdri to link_with list
Fixes:
68076b87474e7959 ("meson: build gallium vdpau state tracker")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Fri, 2 Feb 2018 00:09:02 +0000 (16:09 -0800)]
meson: Actually link xvmc target with libxvmc
Unlike vdpau this is required.
Fixes:
22a817af8a89eb3c7 ("meson: build gallium xvmc state tracker")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Fri, 2 Feb 2018 00:03:17 +0000 (16:03 -0800)]
meson: actually link with libomxil-bellagio
This state tracker actually needs to link, unlike vdpau.
Fixes:
1d36dc674d528b93b ("meson: build gallium omx state tracker")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Wed, 17 Jan 2018 18:26:58 +0000 (10:26 -0800)]
meson: link dri3 xcb libs into vlwinsys instead of into each target
This makes the dependencies easier to manage, since each media target
doesn't need to worry about linking to half a dozen libraries.
Fixes:
b1b65397d0c4978e3 ("meson: Build gallium auxiliary")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Thu, 18 Jan 2018 18:03:24 +0000 (10:03 -0800)]
meson: use va-api version reported by pkg-config
Fixes:
5a785d51a6d6 ("meson: build gallium va state tracker")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Mon, 12 Feb 2018 19:03:47 +0000 (11:03 -0800)]
meson: add libswdri and libswkmsdri to dri link_with
Fixes:
b154b44ae342 ("meson: build radeonsi gallium driver")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Mon, 12 Feb 2018 18:58:58 +0000 (10:58 -0800)]
meson: add libswdri and libswkmsdri to d3dadaptor link_with
v5: - Fix libswdi -> libswdri typo
Fixes:
6b4c7047d571 ("meson: build gallium nine state_tracker")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Mon, 12 Feb 2018 18:46:06 +0000 (10:46 -0800)]
meson: define empty variables for libswdri and libswkmsdri
This allows these variables to unconditionally included in `link_with`
lists, even if they're not used. This allows deleting duplicated logic
in nearly every gallium target implemented in meson today. This also
removes the now useless `build_by_default` flag from swdri and swkmsdri.
v4: - add this patch
Fixes:
66c94b9313a697ce8f2b222f4ba353035e4b8726
("meson: build gallium winsys for dri, null, and wrapper")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Eric Engestrom <eric.engestrom@imgtec.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Dylan Baker [Tue, 23 Jan 2018 17:41:30 +0000 (09:41 -0800)]
meson: add convenience variable for anv_extensions.py depdendency
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Dylan Baker [Tue, 23 Jan 2018 17:39:25 +0000 (09:39 -0800)]
meson: use depend_files for adding extra file dependencies
cc: Jason Ekstrand <jason.ekstrand@intel.com>
Fixes:
dd088d4bec74f37ffe4 ("anv/extensions: Generate a header file with extension tables")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Dylan Baker [Tue, 23 Jan 2018 17:37:03 +0000 (09:37 -0800)]
meson: use depend_files to track extra file dependencies
cc: Jason Ekstrand <jason.ekstrand@intel.com>
Fixes:
f93994080993bda ("anv: Split anv_extensions.py into two files")
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Dylan Baker [Tue, 23 Jan 2018 17:34:53 +0000 (09:34 -0800)]
Revert "anv/meson: Make anv_entrypoints_gen.py depend on anv_extensions.py"
This reverts commit
10d1b0be8e9c463dbc35cd66968299f33c76672c.
This is unnecessary, the depend_files argument is for adding
dependencies on files that are not part of the input, which is already
done.
cc: Jason Ekstrand <jason.ekstrand@intel.com>
Fixes:
10d1b0be8e9c463dbc35cd66968299f33c76672c
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Brian Paul [Thu, 15 Feb 2018 16:12:03 +0000 (09:12 -0700)]
svga: replace gotos with else clauses
Simple clean-up.
Reviewed-by: Charmaine Lee <charmainel@vmware.com>
Brian Paul [Wed, 14 Feb 2018 21:53:42 +0000 (14:53 -0700)]
svga: s/unsigned/enum pipe_shader_type/
Reviewed-by: Neha Bhende <bhenden@vmware.com>
Brian Paul [Wed, 14 Feb 2018 17:37:27 +0000 (09:37 -0800)]
svga: move duplicated code for setting fillmode/flatshade state
Move the calls to svga_hwtnl_set_fillmode() and svga_hwtnl_set_flatshade()
out of the two retry_draw_*() functions to the svga_draw_vbo() function.
Reviewed-by: Charmaine Lee <charmainel@vmware.com>
Brian Paul [Wed, 14 Feb 2018 17:33:58 +0000 (09:33 -0800)]
svga: move svga_update_state() call in draw code
This fixes a few Piglit transform feedback regressions caused by
commit
7a1401938b351.
In that change I moved the moved svga_update_state() into the loops,
after the calls to svga_hwtnl_set_flatshade(). But
svga_hwtnl_set_flatshade() actually depends on some derived shader
state. This patch moves the svga_update_state() call into
svga_draw_vbo() so it's not duplicated in two places.
Fixes:
7a1401938b351 ("svga: clean up retry_draw_range_elements(),
retry_draw_arrays()")
Reviewed-by: Charmaine Lee <charmainel@vmware.com>
Brian Paul [Wed, 14 Feb 2018 20:50:00 +0000 (13:50 -0700)]
svga: call tgsi_scan_shader() for dummy shaders
If we fail to compile the normal VS or FS we fall back to a simple/
dummy shader. We need to rescan the the shader to update the shader
info. Otherwise, this can lead to further translations failures
because the shader info doesn't match the actual shader.
Found by adding some extra debug assertions in the state-update code
while debugging something else.
v2: also update shader generic_inputs/outputs, etc. per Charmaine
Reviewed-by: Charmaine Lee <charmainel@vmware.com>
Samuel Pitoiset [Wed, 14 Feb 2018 17:15:23 +0000 (18:15 +0100)]
ac/nir: do not reserve user SGPRs for unused descriptor sets
In theory this might lead to corruption if we bind a descriptor
set which is unused, because LLVM is smart and it can re-use
unused user SGPRs. In practice, this doesn't seem to fix
anything.
As a side effect, this will reduce the number of emitted
SH_REG packets.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Samuel Pitoiset [Wed, 14 Feb 2018 16:52:25 +0000 (17:52 +0100)]
ac/shader: fix gathering of desc_set_used_mask
This was quite wrong.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Samuel Pitoiset [Wed, 14 Feb 2018 11:03:55 +0000 (12:03 +0100)]
ac/shader: be a little smarter when scanning vertex buffers
Although meta shaders don't use any vertex buffers, there is no
behaviour change but I think it's better to do this. Though,
this saves two user SGPRs for push constants inlining or
something else.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Louis-Francis Ratté-Boulianne [Thu, 28 Sep 2017 07:18:33 +0000 (03:18 -0400)]
dri: fromPlanar() can return NULL as a valid result
It was assumed that fromPlanar() could return NULL to mean
that the planar image is the same as the parent DRI image.
That assumption wasn't made everywhere though.
Let's fix things and make sure that all callers understand
a NULL result
Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Emil Velikov [Thu, 15 Feb 2018 11:33:27 +0000 (11:33 +0000)]
docs: correct link to the 17.3.3 release notes
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Emil Velikov [Thu, 15 Feb 2018 11:33:04 +0000 (11:33 +0000)]
docs: update calendar, add news and link release notes to 17.3.4
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
Emil Velikov [Thu, 15 Feb 2018 11:28:00 +0000 (11:28 +0000)]
docs: add sha256 checksums for 17.3.4
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
(cherry picked from commit
26c84b8af9ebdedd2df75596c25173639ed5e4b2)
Emil Velikov [Thu, 15 Feb 2018 11:09:05 +0000 (11:09 +0000)]
docs: add release notes for 17.3.4
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
(cherry picked from commit
2f9820c553c943f776513ddc2887fb6b1cf0f29a)
Karol Herbst [Mon, 5 Feb 2018 14:41:50 +0000 (15:41 +0100)]
nvc0: disable MS Images for sample_count == 1 on Maxwell
fixes KHR-GL45.multi_bind.dispatch_bind_textures on Maxwell
Suggested-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Gurchetan Singh [Wed, 14 Feb 2018 23:40:35 +0000 (15:40 -0800)]
mesa: don't clamp just based on ARB_viewport_array extension
The ARB_viewport_array spec says:
"Dependencies
OpenGL 1.0 is required.
OpenGL 3.2 or the EXT_geometry_shader4 or ARB_geometry_shader4 extensions
are required.
This extension is written against the OpenGL 3.2 (Compatibility)
Specification."
As such, we should ignore it for GLES2 contexts.
Fixes:
dEQP-GLES2.functional.state_query.integers.viewport_getinteger
dEQP-GLES2.functional.state_query.integers.viewport_getfloat
on llvmpipe and virgl.
v2: Use _mesa_has_* (Ilia)
Signed-off-by: Marek Olšák <marek.olsak@amd.com>
Cc: 17.3 18.0 <mesa-stable@lists.freedesktop.org>
Dylan Baker [Mon, 12 Feb 2018 19:53:55 +0000 (11:53 -0800)]
meson: use a custom target instead of a generator for i965 oa
Generators really are never the thing you want. The problem in this case
is that a generator must create a file that contains any file that the
generated target depends on. Since brw_oa.py doesn't generate such a
file the generated sources are not regenerated even if the xml files
they should depend on changes.
While we could change brw_oa.py to write such a file, that's silly, it
depends on itself and the xml file. So we'll just use a custom target
instead, which will have the correct dependency behavior and doesn't
really add that much code.
Fixes:
3218056e0eb3 ("meson: Build i965 and dri stack")
CC: Ian Romanick <idr@freedesktop.org>
Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Anuj Phogat [Fri, 30 Jun 2017 17:29:23 +0000 (10:29 -0700)]
isl: Don't use surface format R32_FLOAT for typed atomic integer operations
From Skylake PRM Surface Formats section:
"The surface format for the typed atomic integer operations must
be R32_UINT or R32_SINT."
Fixes an error and a piglit GPU hang in simulation environment.
Piglit test: gl45-imageAtomicExchange-float.shader_test
Suggested-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Anuj Phogat <anuj.phogat@gmail.co
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Cc: "18.0 17.3" <mesa-stable@lists.freedesktop.org>
Timothy Arceri [Wed, 14 Feb 2018 01:20:56 +0000 (12:20 +1100)]
radeonsi/nir: fix si_nir_load_tcs_varyings() for outputs
We were incorrectly using the input info for outputs.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Timothy Arceri [Tue, 13 Feb 2018 06:00:40 +0000 (17:00 +1100)]
ac: implement nir_intrinsic_image_samples
Fixes cts test:
KHR-GL45.shader_texture_image_samples_tests.image_functional_test
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Timothy Arceri [Tue, 13 Feb 2018 03:25:51 +0000 (14:25 +1100)]
st: add NIR GL_ARB_get_program_binary support
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Timothy Arceri [Tue, 13 Feb 2018 03:23:28 +0000 (14:23 +1100)]
st/shader_cache: add st_{de}serialise_nir_program() helpers
These will be used for NIR GL_ARB_get_program_binary support.
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Timothy Arceri [Mon, 12 Feb 2018 22:42:48 +0000 (09:42 +1100)]
ac/nir_to_llvm: fix image size for arrays of arrays
Fixes cts test:
KHR-GL44.shader_image_size.advanced-changeSize
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Timothy Arceri [Mon, 12 Feb 2018 22:34:16 +0000 (09:34 +1100)]
radeonsi/nir: fix shader ballot return value bitsize
Fixes cts test:
KHR-GL46.shader_ballot_tests.ShaderBallotFunctionBallot
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Jason Ekstrand [Tue, 13 Feb 2018 03:29:59 +0000 (19:29 -0800)]
intel/aubinator: Correctly decode INTERFACE_DESCRIPTOR_DATA
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Jason Ekstrand [Tue, 13 Feb 2018 22:56:28 +0000 (14:56 -0800)]
i965: Add gl_state_index casts for PATCH_VERTICES_IN
This fixes the build in clang
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105088
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Scott D Phillips [Wed, 10 Jan 2018 07:17:00 +0000 (23:17 -0800)]
i965/miptree: Initialize mcs with a linear map
When initializing mcs, map with MAP_RAW and fill in the linear
map. Removes a place where gtt mapping is used.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Scott D Phillips [Wed, 10 Jan 2018 07:16:58 +0000 (23:16 -0800)]
i965/tiled_memcpy: change linear pointer from (0, 0) to (xt1, yt1)
In all current uses, the linear surface is only allocated starting
at (xt1, yt1) anyway, so this improves the calling ergonomics.
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Scott D Phillips [Sat, 27 Jan 2018 00:07:15 +0000 (16:07 -0800)]
i965/tiled_memcpy: linear_to_ytiled a cache line at a time
TileY's low 6 address bits are: v1 v0 u3 u2 u1 u0
Thus a cache line in the tiled surface is composed of a 2d area of
16x4 bytes of the linear surface.
Add a special case where the area being copied is 4-line aligned
and a multiple of 4-lines so that entire cache lines will be
written at a time.
On Apollolake, this increases tiling throughput to wc maps by
84.0103% +/- 0.862818%
v2: Split [y0, y1) and [y2, y3) loops apart for clarity (Jason Ekstrand)
v3: Don't reset src var (Jason), Ensure y0 <= y1 <= y2 <= y3
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Rafael Antognolli [Tue, 13 Feb 2018 21:48:26 +0000 (13:48 -0800)]
docs: Add Cannonlake support to 18.0 release notes.
17.4 is actually 18.0.
Signed-off-by: Rafael Antognolli <rafael.antognolli@intel.com>
Cc: "18.0" mesa-stable@lists.freedesktop.org
Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Rafael Antognolli [Tue, 13 Feb 2018 21:18:08 +0000 (13:18 -0800)]
anv/gen10: Remove warning message.
Gen10 seems pretty stable so far, remove "alpha support" message.
Signed-off-by: Rafael Antognolli <rafael.antognolli@intel.com>
Cc: Jason Ekstrand <jason@jlekstrand.net>
Cc: "18.0" mesa-stable@lists.freedesktop.org
Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Rafael Antognolli [Tue, 13 Feb 2018 21:13:24 +0000 (13:13 -0800)]
i965/gen10: Remove warning message.
Gen10 seems pretty stable so far, so there's no reason to keep this
message.
Signed-off-by: Rafael Antognolli <rafael.antognolli@intel.com>
Cc: Kenneth Graunke <kenneth@whitecape.org>
Cc: "18.0" mesa-stable@lists.freedesktop.org
Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Louis-Francis Ratté-Boulianne [Tue, 13 Feb 2018 03:26:10 +0000 (22:26 -0500)]
egl/x11: Fix leak in dri3_create_image_khr_pixmap
bp_reply wasn't properly free'd
Signed-off-by: Louis-Francis Ratté-Boulianne <lfrb@collabora.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Iago Toral Quiroga [Fri, 19 Jan 2018 08:17:07 +0000 (09:17 +0100)]
i965/compiler: clean up nir_intrinsic_load_input for vertex shaders
This code to re-set the type of the source and destination is not
necessary since we never manipulate the types. Looks like a
left over from a time where we had to retype to float temporarily
to handle 64-bit inputs.
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Iago Toral Quiroga [Fri, 19 Jan 2018 08:17:06 +0000 (09:17 +0100)]
intel/compiler: fix first_component for 64-bit types on vertex inputs
Divide it by two as we do for other stages. This is because the
component layout qualifier is always in 32-bit units.
Fixes issues in a new CTS test (still WIP):
KHR-GL45.enhanced_layouts.varying_double_components
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Samuel Pitoiset [Mon, 12 Feb 2018 11:34:23 +0000 (12:34 +0100)]
ac/nir: rename nir_to_llvm_context to radv_shader_context
There is still more to do in that area, but it's a good start.
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Samuel Pitoiset [Mon, 12 Feb 2018 11:31:59 +0000 (12:31 +0100)]
ac: remove nir_to_llvm_context from ac_nir_translate()
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Samuel Pitoiset [Mon, 12 Feb 2018 11:22:00 +0000 (12:22 +0100)]
ac/nir: remove nir_to_llvm_context::nir link
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Samuel Pitoiset [Mon, 12 Feb 2018 11:16:47 +0000 (12:16 +0100)]
ac: move the outputs array to the ABI
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Samuel Pitoiset [Mon, 12 Feb 2018 14:57:17 +0000 (15:57 +0100)]
ac/shader: scan force_persample
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Dave Airlie [Wed, 14 Feb 2018 03:59:09 +0000 (13:59 +1000)]
r600: fix regression in gl_FragColor drawing
This fixes a regression in the broadcast color to all color bufs case.
Fixes:
6c691081a (r600: fixup sparse color exports.)
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Mon, 12 Feb 2018 04:46:50 +0000 (14:46 +1000)]
r600: fix array spill if temp[0] is before all arrays
I found a shader with
DCL TEMP[0], LOCAL
DCL TEMP[1..256], ARRAY(1), LOCAL
DCL TEMP[257..512], ARRAY(2), LOCAL
DCL TEMP[513..768], ARRAY(3), LOCAL
DCL TEMP[769], LOCAL
This would remap badly, as it would add up all the spilled sizes
and subtract it from the temp for 0. If the current temp is less
than the array start break out.
Fixes:
1d871aa6 (r600g: Implement spilling of temp arrays (v2))
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Tue, 13 Feb 2018 04:08:14 +0000 (14:08 +1000)]
virgl: add ARB_sample_shading support.
This enable ARB_sample_shading if the renderer supports it.
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Tue, 13 Feb 2018 03:57:28 +0000 (13:57 +1000)]
virgl: add ARB_draw_indirect support.
This relies on the renderer code landing first.
Signed-off-by: Dave Airlie <airlied@redhat.com>
Roland Scheidegger [Tue, 13 Feb 2018 17:56:34 +0000 (18:56 +0100)]
tgsi: Recognize RET in main for tgsi_transform
Shaders coming from dx10 state trackers have a RET before the END.
And the epilog needs to be placed before the RET (otherwise it will
get ignored).
Hence figure out if a RET is in main, in this case we'll place
the epilog there rather than before the END.
(At a closer look, there actually seem to be problems with control
flow in general with output redirection, that would need another
look. It's enough however to fix draw's aa line emulation in some
internal bug - lines tend to be drawn with trivial shaders, moving
either a constant color or a vertex color directly to the output).
v2: add assert so buggy handling of RET in main is detected
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Jose Fonseca <jfonseca@vmware.com>
Bas Nieuwenhuizen [Tue, 13 Feb 2018 22:25:30 +0000 (23:25 +0100)]
ac: Use the renumbered const address space for LLVM 7.
The LLVM AMDGPU backend decided to renumber the constant address
space ....
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Dave Airlie [Mon, 12 Feb 2018 19:21:12 +0000 (05:21 +1000)]
gallium: drop all the guard band float caps.
Nobody queries these and nobody sets them to anything useful,
the docs say TODO.
Drop them until a use appears.
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Vadym Shovkoplias [Tue, 13 Feb 2018 18:38:22 +0000 (11:38 -0700)]
mesa: add glsl version query (v4)
Add support for GL_NUM_SHADING_LANGUAGE_VERSIONS
and glGetStringi for GL_SHADING_LANGUAGE_VERSION
v2:
- Combine similar functionality into
_mesa_get_shading_language_version() function.
- Change GLSL version return mechanism.
v3:
- Add return of empty string for GLSL ver 1.10.
- Move _mesa_get_shading_language_version() function
to src/mesa/main/version.c.
v4:
- Add OpenGL version check.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=104915
Signed-off-by: Andriy Khulap <andriy.khulap@globallogic.com>
Signed-off-by: Vadym Shovkoplias <vadym.shovkoplias@globallogic.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
Brian Paul [Tue, 13 Feb 2018 16:21:45 +0000 (09:21 -0700)]
mesa: add missing switch case for EXTRA_VERSION_40 in check_extra()
The EXTRA_VERSION_40 predicate is tested as part of
extra_gl40_ARB_sample_shading but there was no switch case for it.
Fixes:
77b440e42d8e7247c2295 ("mesa: Add new functions and enums required
by GL_ARB_sample_shading")
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
Mark Janes [Tue, 13 Feb 2018 07:19:35 +0000 (23:19 -0800)]
mesa: fix compile failure
Missing header triggered a failure in i965 CI buildtest project.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105067
Fixes:
e149a0253c12d103805230bc7bc0a36887c3b8df
Mark Janes [Tue, 13 Feb 2018 06:15:47 +0000 (22:15 -0800)]
Partially revert "mesa: use GLenum16 in a few more places"
This reverts part of commit
ca721b3d894a49d7342f5aa053ed132017e9352a.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105067
Mark Janes [Tue, 13 Feb 2018 07:47:18 +0000 (23:47 -0800)]
Revert "mesa: reduce the size of gl_texture_image"
This reverts commit
f4ea2b2a9e99d93fbf36c3f0e5f6f384be3cdb89.
Several members reduced in size by the offending commit are not large
enough to store the data needed by the i965 driver.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105067
Dave Airlie [Tue, 13 Feb 2018 02:21:07 +0000 (12:21 +1000)]
i965: fix tessellation regressions with gl_state_index16
Looks like one conversion was missed.
Fixes:
e149a0253 (mesa,glsl,nir: reduce gl_state_index size to 2 bytes)
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105067
Signed-off-by: Dave Airlie <airlied@redhat.com>
Tested-by: Mark Janes <mark.a.janes@intel.com>
Stéphane Marchesin [Sat, 10 Feb 2018 01:21:59 +0000 (17:21 -0800)]
virgl: Support v2 caps struct (v2)
This struct allows us to report:
- accurate max point size/line width.
- accurate texel and texture gather offsets
- vertex/geometry limits.
Signed-off-by: Dave Airlie <airlied@redhat.com>
Timothy Arceri [Thu, 8 Feb 2018 00:10:26 +0000 (11:10 +1100)]
ac/nir: add nir_intrinsic_{load,store}_shared support
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>