summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2019-03-07cherry-ignore: Update the cherry-ignore fileDylan Baker1-1/+12
2019-03-07intel/fs: Fix extract_u8 of an odd byte from a 64-bit integerIan Romanick1-0/+7
In the old code, we would generate the exact same instruction for extract_u8(some_u64, 0) and extract_u8(some_u64, 1). The mask-a-word trick only works for even numbered bytes. This fixes the (new) piglit test tests/spec/arb_gpu_shader_int64/execution/fs-ushr-and-mask.shader_test. v2: Use a SHR instead of an AND. This saves an instruction compared to using two moves. Suggested by Jason. Fixes: 6ac2d169019 ("i965/fs: Fix extract_i8/u8 to a 64-bit destination") Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> (cherry picked from commit 55e6454d5e9dae6f8f29992af83f99217446da38)
2019-03-07intel/fs: nir_op_extract_i8 extracts a byte, not a wordIan Romanick1-2/+4
Fixes: 6ac2d169019 ("i965/fs: Fix extract_i8/u8 to a 64-bit destination") Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> (cherry picked from commit 4aaf139ea4cc7c4703e1906e0074f87f76c8e4cc)
2019-03-07spirv: Pull offset/stride from the pointer for OpArrayLengthJason Ekstrand1-2/+10
We can't pull it from the variable type because it might be an array of blocks and not just the one block. While we're here, throw in some error checking. Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Cc: mesa-stable@lists.freedesktop.org (cherry picked from commit f1dbc7e97d3dcb2104b9438d32cace9529575208)
2019-03-06VERSION: bump version for rc7Dylan Baker1-1/+1
2019-03-05radv: properly align the fence and EOP bug VA on GFX9Samuel Pitoiset1-2/+5
If alignement is 0, offets returned by radv_cmd_buffer_upload_alloc() are always 0. These two virtual addresses were pointing at the same location. Cc: 18.3 19.0 <mesa-stable@lists.freedesktop.org> Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> (cherry picked from commit c2a148692b4d728e481b60a503e21931f9cf43f0)
2019-03-05egl: fix libdrm-less buildsEric Engestrom2-15/+0
This function was never used, and isn't properly guarded by HAVE_LIBDRM, breaking the build on systems that don't have libdrm. Let's just remove it. Fixes: 7552fcb7b9b98392e6a8 "egl: add base EGL_EXT_device_base implementation" Reported-by: Timo Aaltonen <tjaalton@debian.org> Signed-off-by: Eric Engestrom <eric.engestrom@intel.com> Acked-by: Emil Velikov <emil.velikov@collabora.com> (cherry picked from commit bcc4bfc8e80da5dc4c6ee44f791f2112dac208d1)
2019-03-05anv: retain the is_array state in create_plane_tex_instr_implicitTapani Pälli1-0/+1
This does not seem to fix anything ATM but is the right thing todo. Signed-off-by: Tapani Pälli <tapani.palli@intel.com> Fixes: f3e91e78a33775 ("anv: add nir lowering pass for ycbcr textures") Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> (cherry picked from commit 33bf3d510c98a22706eb25815f1214d2e1a0e868)
2019-03-05intel,nir: Lower TXD with min_lod when the sampler index is not < 16Jason Ekstrand3-1/+30
When we have a larger sampler index, we get into the "high sampler" scenario and need an instruction header. Even in SIMD8, this pushes the instruction over the sampler message size maximum of 11 registers. Instead, we have to lower TXD to TXL. Fixes: cb98e0755f8d "intel/fs: Support min_lod parameters on texture..." Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit 5c96120b5ce158fea28d751d8a55b5e4d80df4f3)
2019-03-05spirv: OpImageQueryLod requires a samplerJason Ekstrand1-1/+1
No idea how this fell through the cracks besides the fact that the sampler bound at 0 almost always works and the CTS isn't amazing. In any case, this appears to have been broken for almost forever. Reviewed-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Cc: mesa-stable@lists.freedesktop.org (cherry picked from commit ca295ddbfb414a526d3bab7daf93fffbbc417c6e)
2019-03-05anv: Count surfaces for non-YCbCr images in GetDescriptorSetLayoutSupportJason Ekstrand1-0/+3
We were accidentally not counting those surfaces Fixes: ddc4069122 "anv: Implement VK_KHR_maintenance3" Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> (cherry picked from commit 5049fbddb4687799a10eb585c8789afa0d080535)
2019-03-05st/nine: Ignore multisample quality level if no msAxel Davy1-0/+4
Apparently instead of returning error when passing a quality level different than 0 for D3DMULTISAMPLE_NONE, we should pass. Fixes: https://github.com/iXit/Mesa-3D/issues/340 Cc: mesa-stable@lists.freedesktop.org Signed-off-by: Axel Davy <davyaxel0@gmail.com> (cherry picked from commit 1d363d440f261fbadc1db3c17acc514b7130d505)
2019-03-05st/nine: Ignore window size if errorAxel Davy1-1/+8
Check GetWindowInfo and ignore the computed sizes if there is an error. Fixes a regression caused by earlier commit when using old wine gallium nine patches. Should also address a crash at window destruction. Related issues: https://github.com/iXit/Mesa-3D/issues/331 https://github.com/iXit/Mesa-3D/issues/332 Cc: mesa-stable@lists.freedesktop.org Fixes: 2318ca68bbe ("st/nine: Handle window resize when a presentation buffer is used") Signed-off-by: Axel Davy <davyaxel0@gmail.com> (cherry picked from commit 86666f051e0cae96f2596cac05e3c3f394744149)
2019-03-05android: anv: fix libexpat shared dependencyMauro Rossi1-1/+1
Fixes undefined reference building errors for XML_* functions Signed-off-by: Mauro Rossi <issor.oruam@gmail.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com> Cc: "19.0" <mesa-stable@lists.freedesktop.org> (cherry picked from commit ec0f465bc5f02c93aeb4193db8b5bd90a254b080)
2019-03-05android: anv: fix generated files depedencies (v2)Mauro Rossi1-15/+25
Fix anv_extrypoints.{c,h} and anv_extensions.{c,h} missing dependencies Rename the variable labels according to targets and python scripts Align the building rules as per Automake for simplification Fixes building errors during rebuils due to missing dependencies (v2) Fixed a missing $(VULKAN_API_XML) reference Fixes: 9a508b7 ("android: anv/extensions: fix generated sources build") Fixes: dd088d4bec7 ("anv/extensions: Generate a header file with extension tables") Signed-off-by: Mauro Rossi <issor.oruam@gmail.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com> Reviewed-by: Eric Engestrom <eric.engestrom@intel.com> Cc: "19.0" <mesa-stable@lists.freedesktop.org> (cherry picked from commit 14e7e26a0991e7f9b1d20147f04a43bb4cc3f824)
2019-03-05glsl: fix recording of variables for XFB in TCS shadersIlia Mirkin3-5/+44
This is purely for conformance, since it's not actually possible to do XFB on TCS output varyings. However we do have to make sure we record the names correctly, and this removes an extra level of array-ness from the names in question. Fixes KHR-GL45.tessellation_shader.single.xfb_captures_data_from_correct_stage v2: Add comment to the new program_resource_visitor::process function. (Ilia Mirkin) Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=108457 Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Cc: 19.0 <mesa-stable@lists.freedesktop.org> Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com> (cherry picked from commit 4eec3a2a3652317f8e0fa97e0730c297bde8241a)
2019-03-05glsl: TCS outputs can not be transform feedback candidates on GLESJose Maria Casanova Crespo1-1/+21
Avoids regression on: KHR-GLES*.core.tessellation_shader.single.xfb_captures_data_from_correct_stage that is uncovered by the following patch. "glsl: fix recording of variables for XFB in TCS shaders" v2: Rebased over glsl: fix recording of variables for XFB in TCS shaders v3: Move this patch before "glsl: fix recording of variables for XFB in TCS shaders" to avoid temporal regressions. (Illia Mirkin) Cc: 19.0 <mesa-stable@lists.freedesktop.org> Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com> (cherry picked from commit bf1f49482d677e562993543cd9a9367597ce3ccc)
2019-03-05glx: fix shared memory leak in X11Ray Zhang1-0/+3
call XShmDetach to allow X server to free shared memory Fixes: bcd80be49a8260c2233d "drisw/glx: use XShm if possible" Signed-off-by: Ray Zhang <zhanglei002@gmail.com> Reviewed-by: Dave Airlie <airlied@redhat.com> (cherry picked from commit b344e32cdf7064a1f2ff7ef37027edda6589404f)
2019-03-05glsl: fix shader cache for packed param listTimothy Arceri3-11/+11
Some types of params such as some builtins are always padded. We need to keep track of this so we can restore the list correctly. Here we also remove a couple of cache entries that are not actually required as they get rebuilt by the _mesa_add_parameter() calls. This patch fixes a bunch of arb_texture_multisample and arb_sample_shading piglit tests for the radeonsi NIR backend. Fixes: edded1237607 ("mesa: rework ParameterList to allow packing") Reviewed-by: Marek Olšák <marek.olsak@amd.com> (cherry picked from commit 7536af670b7501228628a8c90f9e8456b5aec9e1)
2019-03-05i965: Fix allow_higher_compat_version workaround limited by OpenGL 3.0Yevhenii Kolesnikov1-6/+12
Added check for higher compat profile being allowed before assigning certain extensions. Fixes: 272fe9494232 (mesa: enable ARB_texture_buffer_* extensions in the Compatibility profile) Signed-off-by: Danylo Piliaiev <danylo.piliaiev@globallogic.com> Signed-off-by: Yevhenii Kolesnikov <yevhenii.kolesnikov@globallogic.com> Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=107052 (cherry picked from commit 07f4b4e4034d6c9f48d136ec39a03e59f65783cb)
2019-03-05intel/compiler: use correct swizzle for replacementLionel Landwerlin1-5/+5
The optimization in 4cd1a0be76883c introduced a replacement of : cmp(8).z.f0.0 vgrf11.y:D, vgrf10.xxxx:D, vgrf2.xyyy:D ... cmp(8).nz.f0.0 null.x:D, vgrf11.yyyy:D, 0D By : cmp(8).z.f0.0 vgrf15.x:D, vgrf10.xxxx:D, vgrf2.yyyy:D ... mov(8) vgrf11.y:D, vgrf15.yyyy:D The first cmp instruction is storing in x while the second mov is sourcing from y. We need to take into account where the replacement on the scan_inst destination is going to store thing so that the replacement mov can source things from the correct location. Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Fixes: 4cd1a0be76883c ("i965/vec4: Propagate conditional modifiers from more compares to other compares") Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=109759 Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> (cherry picked from commit 6e184147ddce11e90c269a47af7d7395f5ed9c12)
2019-03-05freedreno: use renderonly path for buffers allocated with modifiersJonathan Marek1-1/+7
Now that freedreno has create_with_modifiers(), this "hack" is needed to make some cases work. Copied from vc4. Fixes: 41ddf1d1 Signed-off-by: Jonathan Marek <jonathan@marek.ca> (cherry picked from commit e3591b03393402321d24e10b93ec5a827a4b9b6a)
2019-03-05freedreno: a2xx: fix mipmapping for NPOT texturesJonathan Marek1-0/+6
Fixes: 3a273a4a Signed-off-by: Jonathan Marek <jonathan@marek.ca> (cherry picked from commit 6c0fefb448f0b72971c96a60907c77ce0512d590)
2019-03-05freedreno: a2xx: fix fast clear for some gmem configurationsJonathan Marek1-3/+3
In freedreno_gmem.c, gmem_align of 0x8000 is used. Alignment used here should be the same. Fixes: 912a9c8d Signed-off-by: Jonathan Marek <jonathan@marek.ca> (cherry picked from commit 4f23767590d1374c4cf2b5ddeedd9dd375c296f1)
2019-03-05freedreno: a2xx: add use_hw_binning functionJonathan Marek1-2/+24
Fixes: cb2322c7 Signed-off-by: Jonathan Marek <jonathan@marek.ca> (cherry picked from commit 8eca6df5ed5ad6df51a3aad271856d7da56d1292)
2019-03-05freedreno: a2xx: don't write 4th vertex in mem2gmemJonathan Marek1-3/+1
There is only room for 3 vertices now (RECT has 3 vertices). Fixes: 6ef7700a Signed-off-by: Jonathan Marek <jonathan@marek.ca> (cherry picked from commit 357313ab0f123b4e4b1efc74f5e5b1514c421e68)
2019-02-28scons: Workaround failures with MSVC when using SCons 3.0.[2-4].Jose Fonseca1-1/+7
This change applies the workaround suggested by Bill Deegan on the affected SCons versions. It also adds a comment with the URL explaining why we were using customizing the decider and max_drift in the first place, as I had forgotten all about it. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=109443 Tested-by: liviuprodea@yahoo.com Reviewed-by: Roland Scheidegger <sroland@vmware.com> Reviewed-by: Brian Paul <brianp@vmware.com>
2019-02-27mesa: fix display list corner case assertionBrian Paul1-0/+2
This fixes a failed assertion in glDeleteLists() for the following case: list = glGenLists(1); glDeleteLists(list, 1); when those are the first display list commands issued by the application. When we generate display lists, we plug in empty lists created with the make_list() helper. This function uses the OPCODE_END_OF_LIST opcode but does not call dlist_alloc() which would set the InstSize[OPCODE_END_OF_LIST] element to non-zero. When the empty list was deleted, we failed the InstSize[opcode] > 0 assertion. Typically, display lists are created with glNewList/glEndList so we set InstSize[OPCODE_END_OF_LIST] = 1 in dlist_alloc(). That's why this bug wasn't found before. To fix this failure, simply initialize the InstSize[OPCODE_END_OF_LIST] element in make_list(). The game oolite was hitting this. Fixes: https://github.com/OoliteProject/oolite/issues/325 Reviewed-by: Marek Olšák <marek.olsak@amd.com> (cherry picked from commit 6dabcb5bcfd5dc4c62dbdb1cfd1ea95e45a47f8a)
2019-02-27radv: Interpolate less aggressively.Bas Nieuwenhuizen1-9/+12
Seems like dxvk used integer builtins without setting the flat interpolation decoration. I believe in the current spec the app is required to set these, but in the meantime to avoid breaking things in stable releases (and so close to release for 19.0), only expand the interpolation to float16 and struct (which cannot be builtins as our spirv parser lowers the builtin block). Fixes: f3247841040 "radv: Allow interpolation on non-float types." Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> (cherry picked from commit c0110477b5503978adf37f64c65c30c9304e3fe4)
2019-02-26Bump version for rc6Dylan Baker1-1/+1
2019-02-26radv: fix clearing attachments in secondary command buffersSamuel Pitoiset1-10/+46
If no framebuffer is bound, get the number of samples and the image format from the render pass. This fixes new CTS dEQP-VK.geometry.layered.*.secondary_cmd_buffer. Cc: 18.3 19.0 <mesa-stable@lists.freedesktop.org> Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> (cherry picked from commit 5671f38085216caf2cbf221a9fcda08b7571a762) Conflicts resolved by Dylan Conflicts: src/amd/vulkan/radv_meta_clear.c
2019-02-26i965: fixed clamping in set_scissor_bits when the y is flippedEleni Maria Stea1-1/+1
Calculating the scissor rectangle fields with the y flipped (0 on top) can generate negative values that will cause assertion failure later on as the scissor fields are all unsigned. We must clamp the bbox values again to make sure they don't exceed the fb_height. Also fixed a calculation error. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=108999 https://bugs.freedesktop.org/show_bug.cgi?id=109594 v2: - I initially clamped the values inside the if (Y is flipped) case and I made a mistake in the calculation: the clamp of the bbox[2] should be a check if (bbox[2] >= fbheight) bbox[2] = fbheight - 1 instead and I shouldn't have changed the ScissorRectangleYMax calculation. As the fixed code is equivalent with using CLAMP instead of MAX2 at the top of the function when bbox[2] and bbox[3] are calculated, and the 2nd is more clear, I replaced it. (Nanley Chery) v3: - Reversed the CLAMP change in bbox[3] as the API guarantees that the viewport height is positive. (Nanley Chery) v4: - Added nomination for the mesa-stable branch and the link to the second bugzilla bug (Nanley Chery) CC: <mesa-stable@lists.freedesktop.org> Tested-by: Paul Chelombitko <qamonstergl@gmail.com> Reviewed-by: Nanley Chery <nanley.g.chery@intel.com> (cherry picked from commit fd37a19ac4c8b2ebff330b2a06a7f311f7d478e3)
2019-02-26meson: egl: correctly manage loader/xmlconfigEmil Velikov1-6/+5
Earlier commit introduced support for haiku yet did not properly annotate the loader/xmlconfig dependencies. Thus we ended up adding inc_loader for each !haiku platform - see 659910eda01 9a96bf0ecd0 c731508b988 ec6cb01e216. One piece remained though - the wayland platform. Hence the following would fail: meson -Dgallium-drivers=etnaviv -Ddri-drivers=''\ -Dtools=etnaviv -Dplatforms=wayland -Dglx=disabled \ build/ Cc: Alexander von Gluck IV <kallisti5@unixzen.com> Reported-by: Boris Brezillon <boris.brezillon@collabora.com> Fixes: 834d221512f ("meson: Add Haiku platform support v4") Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Tested-by: Boris Brezillon <boris.brezillon@collabora.com> Reviewed-by: Eric Engestrom <eric.engestrom@intel.com> Reviewed-by: Dylan Baker <dylan@pnwbakers.com> (cherry picked from commit f0a7b463b5586972f4b7f5d9d84eb0564087ce3f)
2019-02-26radv: don't copy buffer descriptors list for samplersSamuel Pitoiset1-1/+5
Sampler descriptors don't have a buffer list. This fixes some crashes with new CTS dEQP-VK.binding_model.descriptor_copy.*.sampler_*. Cc: 18.3 19.0 <mesa-stable@lists.freedesktop.org> Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> (cherry picked from commit 4924dfc851e52c383380ae56be4d8606684ead7c)
2019-02-26radv: fix out-of-bounds access when copying descriptors BO listSamuel Pitoiset1-2/+0
We shouldn't increment the buffer list pointers twice. This fixes some crashes with new CTS dEQP-VK.binding_model.descriptor_copy.*. Cc: 18.3 19.0 <mesa-stable@lists.freedesktop.org> Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl> (cherry picked from commit 9256e0a09dfa94fecfef8e250755732ac35689ec)
2019-02-26nir: initialize value in copy_prop_vars_blockTapani Pälli1-1/+1
Fixes following valgrind warning: ==27561== Conditional jump or move depends on uninitialised value(s) ==27561== at 0x667856B: value_set_ssa_components (nir_opt_copy_prop_vars.c:78) ==27561== by 0x667A1C4: copy_prop_vars_block (nir_opt_copy_prop_vars.c:797) Fixes: 62332d139c8 "nir: Add a local variable-based copy propagation pass" Signed-off-by: Tapani Pälli <tapani.palli@intel.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com> (cherry picked from commit 22267feff1a35c4b6f1f0cb9c8e371727f99b5d6)
2019-02-26radeonsi: fix query buffer allocationTimothy Arceri2-25/+32
Fix the logic for buffer full check on alloc. This patch just takes the fix Nicolai attached to the bug report and updates it to work on master. Fixes: e0f0d3675d4 ("radeonsi: factor si_query_buffer logic out of si_query_hw") Reviewed-by: Marek Olšák <marek.olsak@amd.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=109561 (cherry picked from commit 603206d0a61628deba3f0754324d4b7f382effe5)
2019-02-26spirv: Eliminate dead input/output variables after translation.Kenneth Graunke1-5/+20
spirv_to_nir can generate input/output variables which are illegal for the current shader stage, which would cause nir_validate_shader to balk. After my recent commit to start decorating arrays as compact, dEQP-VK.spirv_assembly.instruction.graphics.module.same_module started hitting validation errors due to outputs in a TCS (not intended for the TCS at all) not being per-vertex arrays. Thanks to Jason Ekstrand for suggesting this approach. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=109573 Fixes: ef99f4c8d17 compiler: Mark clip/cull distance arrays as compact before lowering. Reviewed-by: Juan A. Suarez <jasuarez@igalia.com> (cherry picked from commit 6775665e5eec7db3f291508a8b7ba2a792f62ec0)
2019-02-26radv: Fix rebase issue in 19.0 for float16 fix.Bas Nieuwenhuizen1-1/+2
The cherry-pick dropped a chunk. Fixes: e7351739ff2 "radv: Fix float16 interpolation set up." Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
2019-02-26compiler: Mark clip/cull distance arrays as compact before lowering.Kenneth Graunke2-0/+14
nir_lower_clip_cull_distance_arrays() marks the combined clip/cull distance array as compact. However, when translating in from GLSL or SPIR-V, we were not marking the original float[] arrays as compact. We should do so. That way, we can detect these corner cases properly. Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com> (cherry picked from commit ef99f4c8d176f4e854e12afa1545fa53f651d758) Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2019-02-25nir/lower_clip_cull: Fix an incorrect assertJason Ekstrand1-1/+1
Copy+paste error. It was supposed to test cull and not clip. Fixes: 4e69fba534e "nir: Rewrite lower_clip_cull_distance_arrays..." Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=109717 Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> (cherry picked from commit f98fd9d15a9a79ff1b41f1fce27bc285a20aa5bb)
2019-02-25radv: Handle clip+cull distances more generally as compact arrays.Bas Nieuwenhuizen4-99/+83
Needed for https://gitlab.freedesktop.org/mesa/mesa/merge_requests/248 . That MR keeps the clip and cull arrays split. So we have to handle - compact arrays with location_frac != 0 - VARYING_SLOT_CLIP_DIST1 Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> (cherry picked from commit 1ef2855692d53349588fa3a9b425c9ae229e5e14)
2019-02-25nir/xfb: Handle compact arrays in gather_xfb_infoJason Ekstrand1-11/+22
This makes us properly handle gl_ClipDistance and gl_CullDistance. Fixes: 19064b8c "nir: Add a pass for gathering transform feedback info" Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com> (cherry picked from commit 1a93fc382b18ee6d1135952d23f0b6a8aa8cd31f)
2019-02-25nir/xfb: Work in terms of components rather than slotsJason Ekstrand1-5/+5
We needed to better handle cases where a chunk of a variable starts at some non-zero location_frac and rolls over into the next slot but may not be more than 4 dwords. For example, if gl_CullDistance is an array of 3 things and has location_frac = 2, it will span across two vec4s but is not, itself, bigger than a vec4. If you ignore the clip/cull special case, it's not allowed to happen for anything else because the only things that can span more than one slot is dvec3 and dvec4 and they're both bigger than a vec4. The current code uses this attrib_slot thing where we count attribute slots and iterate over them. However, that doesn't work in the case above because gl_CullDistance will have an attrib_slot count of 1 even though it does span two slots. We could fix this by adjusting attrib_slot but we already have comp_mask and it's easier to just handle it that way. Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com> (cherry picked from commit 558c3145045f1c6da8bddb31ed77a418ab27f2f9)
2019-02-25nir: Rewrite lower_clip_cull_distance_arrays to do a lot less loweringJason Ekstrand1-117/+26
Instead of going to all the work of to combine them into one array, just make two arrays and use location_frac to colocate them within CLIP0. Then the back-end can sort things out and stack them on top of each other. Thanks to ef99f4c8, we also don't need to set compact anymore. Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org> (cherry picked from commit 4e69fba534e7377f3bc6c40c73e6bc5c23437d4e) Conflicts resolved by Dylan Conflicts: src/compiler/nir/nir_lower_clip_cull_distance_arrays.c
2019-02-25nir/xfb: Properly align 64-bit valuesJason Ekstrand1-0/+4
Fixes: 19064b8c "nir: Add a pass for gathering transform feedback info" Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com> (cherry picked from commit 8f0fe71cc5658728adc273daa03400aab7ec6d93)
2019-02-25compiler/types: Add a contains_64bit helperJason Ekstrand4-0/+29
Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com> (cherry picked from commit 30b548fc6258e9a72722f511e377cf4716fd443c)
2019-02-25configure: fix test portabilityMaya Rashish1-2/+2
From the bash manual: string1 == string2 string1 = string2 True if the strings are equal. = should be used with the test command for POSIX conformance. (cherry picked from commit 021c4961356c4b56b35d34b566e6f5f87d21fe34)
2019-02-25radv: Allow interpolation on non-float types.Bas Nieuwenhuizen1-10/+9
In particular structs containing floats and 16-bit floating point types. Fixes: 62024fa7750 "radv: enable VK_KHR_16bit_storage extension / 16bit storage features" Fixes: da295946361 "spirv: Only split blocks" Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=109735 Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> (cherry picked from commit f3247841040a202faffe4709c07da9bd41693580)
2019-02-25radv: Fix float16 interpolation set up.Bas Nieuwenhuizen6-15/+92
float16 types can have non-flat interpolation so set up the HW correctly for that. Fixes: 62024fa7750 "radv: enable VK_KHR_16bit_storage extension / 16bit storage features" Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> (cherry picked from commit a1fdd4a4a73604469b6204a56457b08f8ae4a948) Conflicts resolved by Dylan Conflicts: src/amd/vulkan/radv_nir_to_llvm.c