Commit graph

85652 commits

Author SHA1 Message Date
Dave Airlie
b3616f1326 nir: only dereference undef after NULL check. (v2)
Pointed out by coverity.

v2: nuke line, Jason pointed out the constructor does it.
Signed-off-by: Dave Airlie <airlied@redhat.com>
2016-04-18 07:37:48 +10:00
Emil Velikov
96b4cfe834 docs: update the sha256 checksums for 11.2.1
Turns out the previous tarballs got corrupted during upload which I
carelessly forgot to check prior to deleting the local ones.
Lesson learned - double check before removing the local ones.

Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
(cherry picked from commit 79b0e13913)
2016-04-17 19:32:20 +01:00
Emil Velikov
2197581816 docs: add news item and link release notes for 11.2.1
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
2016-04-17 18:36:59 +01:00
Emil Velikov
03a234c1d1 docs: add sha256 checksums for 11.2.1
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
(cherry picked from commit c65835d812)
2016-04-17 18:36:59 +01:00
Emil Velikov
c15f457958 docs: add release notes for 11.2.1
Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
(cherry picked from commit 21e6440e82)
2016-04-17 18:36:59 +01:00
Jason Ekstrand
f30f6e2625 i965/fs: Don't allow OOB array access of images
We have had a guard against OOB array access of images on IVB for a long
time, but it can actually cause hangs on any GPU generation.  This can
happen due to getting an untyped SURFACE_STATE for a typed message.  We
didn't used to hit this with the piglit test on anything other than IVB
because the OOB in the test would cause us to go past the top of the pull
constant UBO and we would get a surface index of 0 which is was always a
valid surface.  Now that we're pushing small arrays, we can end up grabbing
garbage from the GRF and going to some random index which causes a hang.
The solution is to just do the bounds check on all hardware.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94944
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Tested-by: Mark Janes <mark.a.janes@intel.com>
2016-04-15 22:47:33 -07:00
Jason Ekstrand
93db828e42 anv/device: Images are only enabled in scalar stages
Reported-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-04-15 16:40:56 -07:00
Marek Olšák
c1a2fe7fd1 gallium/radeon: handle vertex shaders that disable clipping & viewport
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
2016-04-16 00:21:15 +02:00
Nanley Chery
696d8ff5a1 mesa/texstore: Use Driver.CompressedTexSubImage in the default CompressedTexImage
Enable drivers to use their own implementation of this method instead of
the mesa default. Since the drivers that currently overwrite
dd_function_table::CompressedTexSubImage also overwrite
::CompressedTexImage, there should be no behavioral change.

Signed-off-by: Nanley Chery <nanley.g.chery@intel.com>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
2016-04-15 15:06:27 -07:00
Jason Ekstrand
5ec4ecce44 anv: Advertise vertexPipelineStoresAndAtomics based on scalar stages
Previously, we just looked at the hardware generation but this meant that
if you did INTEL_DEBUG=vec4 on BDW or SKL, you would have advertised but
non-working features.
2016-04-15 14:53:16 -07:00
Jason Ekstrand
0166ad6ced i965/vec4: Support full std140 layout for push constants
Up until now, we have been able to assume that all push constants are
vec4-aligned because this is what the GL driver gives us.  In Vulkan, we
need to be able to support full std140 because we get the layout from the
client.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-15 14:04:38 -07:00
Jason Ekstrand
a112391d52 i965/vec4: Handle MOV_INDIRECT in pack_uniform_registers
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-15 14:04:38 -07:00
Jason Ekstrand
aaac8a1890 i965/vec4: Add support for SHADER_OPCODE_MOV_INDIRECT
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-15 14:04:38 -07:00
Jason Ekstrand
61ee5e62a2 i965/vec4: Use can_do_writemask in can_reswizzle
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-15 14:04:38 -07:00
Jason Ekstrand
75b68f9114 i965/vec4: Move can_do_writemask to vec4_instruction
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-15 14:04:37 -07:00
Chad Versace
4a80890177 util: Fix warning of invalid return value
_mesa_libgcrypt_init() returns NULL, but its return type is void.

Reviewed-by: Mark Janes <mark.a.janes@intel.com>
2016-04-15 15:00:58 -07:00
Jason Ekstrand
cab30cc5f9 Merge branch 'vulkan' 2016-04-15 13:52:34 -07:00
Roland Scheidegger
64d3ae09b7 llvmpipe: (trivial) initialize src1_alpha var to NULL
The blend code would do a conditional assignment based on it, causing valgrind
to complain. Since that variable was actually unused in this case, this
doesn't fix anything but the warning.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94955
Cc: "11.1 11.2" <mesa-stable@lists.freedesktop.org>

Reviewed-by: Brian Paul <brianp@vmware.com>
2016-04-15 22:51:28 +02:00
Jason Ekstrand
d8b85c96d1 Merge remote-tracking branch 'public/master' into vulkan 2016-04-15 13:35:16 -07:00
Jason Ekstrand
1a100d4f28 configure: Add support for the Intel Vulkan driver
This adds a --with-vulkan-drivers option with one driver, "intel".  In the
future, we may add more drivers to this list.

v2: Don't enable any drivers by default.  This should prevent this patch
    from breaking anyone's build.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-15 13:29:29 -07:00
Jason Ekstrand
ce7e82fb6f i965/surface_formats: Update some formats for more recent gens
The surface format table hasn't entirely been kept up-to-date.  This commit
marks a couple more compressed formats as sampleable on gen8+ and adds the
A4B4G4R4 format as renderable on gen9.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-15 13:29:29 -07:00
Jason Ekstrand
7dac4a2889 util/list: Add list splicing functions
This adds functions for splicing one list into another.  These have
more-or-less the same API as the kernel list splicing functions.  The
implementation, however, was stolen from the Wayland list implementation.

Reviewed-by: Mark Janes <mark.a.janes@intel.com>
Reviewed-by: Rob Clark <robclark@freedesktop.org>
2016-04-15 13:29:09 -07:00
Jason Ekstrand
17a181bfa6 Remove the Intel Vulkan readme 2016-04-15 13:17:08 -07:00
Tim Rowley
082f6d75ae gallium/swr: confine c++11 flag to swr driver
On the philosophy that a driver shouldn't change the compile flags
for the entire tree, take the clove approach of moving the c++11 flag
to the swr driver directory.

Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2016-04-15 14:43:01 -05:00
Tim Rowley
ee72fec9cf gallium/swr: allow swr use as a swrast dri driver
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Tested-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-04-15 14:21:50 -05:00
Eric Anholt
f6d21bcd6b vc4: Fix subimage accesses to LT textures.
This code started out like the T case, iterating over utile offsets, but I
had partially switched it to iterating over pixel offsets.  I hadn't
caught this before because it's unusual to do piecemeal uploads to small
textures.

Fixes bad text rendering in QT5 apps, which use a 256x16 glyph cache.
Also fixes 6 piglit tests related to glTexSubImage() and
glGetTexSubImage().

Cc: "11.1 11.2" <mesa-stable@lists.freedesktop.org>
2016-04-15 11:57:17 -07:00
Mark Janes
ade3108bb5 util: Fix race condition on libgcrypt initialization
Fixes intermittent Vulkan CTS failures within the test groups:
dEQP-VK.api.object_management.multithreaded_per_thread_device
dEQP-VK.api.object_management.multithreaded_per_thread_resources
dEQP-VK.api.object_management.multithreaded_shared_resources

Signed-off-by: Mark Janes <mark.a.janes@intel.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94904

Reviewed-by: Edward O'Callaghan <eocallaghan@alterapraxis.com>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-04-15 10:24:40 -07:00
Jason Ekstrand
8403e6de9f i965: Default to scalar GS 2016-04-15 09:54:42 -07:00
Jason Ekstrand
17d9a2b011 i965/surface_formats: Mark A4B4G4R4_UNORM as SKL+ only
This is what is indicated by the bspec.
2016-04-15 09:53:55 -07:00
Jason Ekstrand
d7189bdeee Revert "i965/fs: Properly write-mask spills"
This reverts commit 9c0109a1f6.
2016-04-15 09:53:55 -07:00
Jason Ekstrand
c3362453f9 Revert "i965/fs: Feel free to spill partial reads/writes"
This reverts commit 2434ceabf4.
2016-04-15 09:53:55 -07:00
Jason Ekstrand
2d5bd66e4f configure: Add support for detecting valgrind headers
We have several places where the Vulkan driver explicitly hooks into
valgrind when it's available.  We need to be able to detect it.

Reviewed-by: Matt Turner <mattst88@gmail.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
2016-04-15 09:41:15 -07:00
Eduardo Lima Mitev
7e4628da48 nir/print: Fix printing variable mode
nir_variable_mode is currently a bitflag enum, while
nir_print::print_var_decl() assumes is still a numbered list.

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-04-15 16:41:41 +02:00
John Sheu
f8752e0d95 xlib: remove MESA_GLX_VISUAL_HACK
This removes a hack introduced in 1999 in the first version of
fakeglx.c, with the comment:

  /* XXX revisit this after 3.0 is finished. */

Mesa 4.0 was released in 2001.  It is now 2016, and Mesa 11.0 was
released last year.

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
2016-04-15 07:46:00 +02:00
John Sheu
8a9c0f1025 xlib: fix leaks of returned values from XGetVisualInfo
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
2016-04-15 07:45:46 +02:00
John Sheu
781232e0ac xlib: fix memory leak of and remove vishandle from XMesaVisualInfo
The vishandle member of XMesaVisualInfo is used to support the
comparison of XVisualInfo instances by pointer value, in
find_glx_visual().  The comparison however will always be false, as in
every case the comparison is made, the VisualInfo instance being
compared to is a new allocation passed in through a GLX API call.

In addition, the XVisualInfo instance pointed to by vishandle is itself
never freed, causing a memory leak.  Since vishandle is essentially
useless, we just remove it and thereby also fix the leak.

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
2016-04-15 07:45:28 +02:00
John Sheu
fe9d8cd79e xlib: do not cache return value of glXChooseVisual/glXGetVisualFromFBConfig
The returned XVisualInfo from glXChooseVisual/glXGetVisualFromFBConfig
is being cached in XMesaVisual.vishandle (and unconditionally
overwritten on subsequent calls).  However, these entry points are
specified to return XVisualInfo instances to be owned by the caller and
freed with XFree(), so the return values should not be retained.

With this change, XMesaVisual.vishandle is essentially unused and will
be removed in a subsequent change.

v2: update commit message

Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com>
2016-04-15 07:44:34 +02:00
Jason Ekstrand
76fa7b16f4 Merge remote-tracking branch 'public/master' into vulkan 2016-04-14 18:30:52 -07:00
Jason Ekstrand
547032c56a main/mtypes: Remove the "set" parameter from gl_uniform_block
This is a left-over from the early days of the Vulkan driver
2016-04-14 18:27:09 -07:00
Jason Ekstrand
f0bbb34e49 Revert "i965/vec4: Add support for SHADER_OPCODE_MOV_INDIRECT"
This reverts commit 4115648a6b.  This commit
was half-baked and probably never should have been committed.  We'll add
this back in properly later when we need it.
2016-04-14 18:22:08 -07:00
Jason Ekstrand
eeff133158 i965: Expose the surface format table
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-14 18:07:48 -07:00
Jason Ekstrand
d7cddbd6d6 nir/lower_io: Add UBOs and SSBOs to get_io_offset_src
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-14 18:07:40 -07:00
Jason Ekstrand
c825e29a82 nir/intrinsics: Add a vulkan_resource_index intrinsic
This is used to facilitate the Vulkan binding model where each resource is
described by a (descriptor set, binding, array index) tuple.

Reviewed-by: Rob Clark <robdclark@gmail.com>
2016-04-14 17:20:05 -07:00
Jason Ekstrand
1e0012e3e4 nir: Add a descriptor_set field to nir_variable
This is needed for supporting the Vulkan binding model

Reviewed-by: Rob Clark <robdclark@gmail.com>
2016-04-14 17:20:05 -07:00
Chad Versace
7a835b3fd9 dri: Fix robust context creation via EGL attribute
driCreateContextAttribs() emits an error if bit
__DRI_CTX_FLAG_ROBUST_BUFFER_ACCESS is set for an ES context.  But,
EGL_EXT_create_context_robustness and EGL 1.5 both allow creation of
robust ES contexts. One requests a robust ES context by setting the
EGL_CONTEXT_OPENGL_ROBUST_ACCESS *attribute*, which Mesa's EGL layer
translates into the __DRI_CTX_FLAG_ROBUST_BUFFER_ACCESS *bit*.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-04-14 17:38:41 -07:00
Jason Ekstrand
5567ae0547 Merge remote-tracking branch 'public/master' into vulkan 2016-04-14 17:14:28 -07:00
Leo Liu
8f4340c5e6 radeon/uvd: fix tonga feedback buffer size
This only applies to tonga

Signed-off-by: Leo Liu <leo.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Cc: "11.1 11.2" <mesa-stable@lists.freedesktop.org>
2016-04-14 19:33:44 -04:00
Jason Ekstrand
f1d29099b4 i965: Push everything if pull_param == NULL
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-14 16:00:18 -07:00
Jason Ekstrand
963513bb24 i965/fs: Push small uniform arrays
Unfortunately, this also means that we need to use a slightly different
algorithm for assign_constant_locations.  The old algorithm worked based on
the assumption that each read of a uniform value read exactly one float.
If it encountered a MOV_INDIRECT, it would immediately bail and push the
whole thing.  Since we can now read ranges using MOV_INDIRECT, we need to
be able to push a series of floats without breaking them up.  To do this,
we use an algorithm similar to the on in split_virtual_grfs.

Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
Acked-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-14 15:59:33 -07:00
Jason Ekstrand
71f8039f72 i965/fs: Rename demote_pull_constants to lower_constant_loads
Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-04-14 15:59:33 -07:00