summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* mesa: add support for AlphaToCoverageDitherControlNVIndrajit Kumar Das2020-04-2313-0/+79
| | | | | Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4543>
* gallium: prepare framework for supporting AlphaToCoverageDitherControlNVIndrajit Kumar Das2020-04-233-0/+3
| | | | | Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4543>
* turnip: Fix crashes when geometry shader constants aren't usedHyunjun Ko2020-04-231-0/+2
| | | | | | | | | Fixes dEQP-VK.transform_feedback.fuzz.2_level_array.float.geometry, for example. Signed-off-by: Hyunjun Ko <[email protected]> Reviewed-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4693>
* gallium: add # of MRT to blend stateRob Clark2020-04-238-2/+14
| | | | | | | | | | | | To make it possible for drivers to avoid unnecessary blend state change for unused MRTs. Otherwise the driver would have to manage different blend CSOs for different potential #s of render targets. Signed-off-by: Rob Clark <[email protected]> Reviewed-by: Kristian H. Kristensen <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4619>
* mesa/st: avoid u_vbuf for GLESRob Clark2020-04-235-5/+25
| | | | | | | | | | | 64b VBO types are not required for GLES. So avoid u_vbuf if that was otherwise the only reason it was used. Signed-off-by: Rob Clark <[email protected]> Reviewed-by: Kristian H. Kristensen <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4619>
* mesa: avoid redundant VBO updatesRob Clark2020-04-232-15/+15
| | | | | | | | | | | Avoids re-emitting unchanged VBO state, which is a big chunk of the state updates in gfxbench driver2 Signed-off-by: Rob Clark <[email protected]> Reviewed-by: Kristian H. Kristensen <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4619>
* nir: Actually do load/store vectorization beyond vec2Kenneth Graunke2020-04-221-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | nir_opt_load_store_vectorize has an is_strided_vector() function that looks for types with weird explicit strides. It does so by comparing the explicit stride against the type-size-derived typical stride. This had a subtle bug. Simple vector types (vec2/3/4) have no explicit stride, so glsl_get_explicit_stride() returns 0. This never matches the typical stride for a vector, so is_strided_vector() would return true for basically any vector type, causing the vectorizer to bail. I found this by looking at a compute shader with scalar SSBO loads at offsets 0x220, 0x224, 0x228, 0x22c. nir_opt_load_store_vectorize would properly vectorize the first two into a vec2 load, but would refuse to extend it to a vec3 and ultimately vec4 load because is_strided_vector() saw a vec2 and freaked out. Neither ACO nor ANV do load/store vectorization before lowering derefs, so this shouldn't affect them. However, I'd like to fix this bug to avoid the trap for anyone who decides to in the future. In a branch where anv used this lowering, this cut an additional 38% of the send messages in the shader by properly vectorizing more things. Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4255>
* mesa: enable GL_EXT_draw_instanced for gles2Simon Zeni2020-04-235-1/+10
| | | | | | Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Tapani Pälli <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3204>
* turnip: Skip unused regs when setting up streamout buffersHyunjun Ko2020-04-231-0/+4
| | | | | | | | Fixes: 374406a7c420d266f920461f904864a94dc1b8c8 Signed-off-by: Hyunjun Ko <[email protected]> Reviewed-by: Brian Ho <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4604>
* turnip : Fix wrong offset calculation for xfb buffer.Hyunjun Ko2020-04-231-2/+0
| | | | | | | | | | | | In vulkan, offsets are already provided through the api vkCmdBindTransformFeedbackBuffersEXT, so this is duplicated calculation. Fixes : 9ff1959ca5d24afe48bec20edf7e3d059d254134 Signed-off-by: Hyunjun Ko <[email protected]> Reviewed-by: Brian Ho <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4604>
* turnip: Implement and enable VK_QUERY_TYPE_TRANSFORM_FEEDBACK_STREAM_EXTHyunjun Ko2020-04-232-2/+133
| | | | | | | | | Tested by dEQP-VK.transform_feedback.simple.query* Signed-off-by: Hyunjun Ko <[email protected]> Reviewed-by: Brian Ho <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4604>
* turnip: make the struct slot_value of queries get 2 valuesHyunjun Ko2020-04-231-57/+86
| | | | | | | | | | | | | | | | | | | | | | In case of transform feedback query, it writes two integer values, which one is for primitives written and another is for primitives generated. To handle this, the second member of the struct slot_value is worth to be presented not as a padding. In addition, we also need to modify get/copy_result to access both values. This patch is the prep work for the transform feedback query support. Tested with dEQP-VK.pipeline.timestamp.* dEQP-VK.query_pool.occlusion_query.* Signed-off-by: Hyunjun Ko <[email protected]> Reviewed-by: Brian Ho <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4604>
* intel/compiler: Don't create 64-bit src1 immediates in opt_peephole_selKenneth Graunke2020-04-231-2/+8
| | | | | | | | | | | | | | 64-bit immediates are only allowed as src0. Long ago, we decided to avoid constructing such illegal situations in the IR, rather than allowing them in the IR but then promoting bogus immediates to GRFs later. So, we need to fix opt_peephole_sel to not put 64-bit immediates as src1 of the new SEL instruction. Fixes: a4b36cd3dd3 ("intel/fs: Coalesce when the src live range is contained in the dst") Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/2816 Reviewed-by: Matt Turner <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4692>
* intel/compiler: Delete abs/neg handling in fsign codeKenneth Graunke2020-04-222-40/+2
| | | | | | | | | | | This should have gone away when removing source modifiers. They won't be set any longer, so this is simply dead code. Fixes: b7c47c4f7cf ("intel/compiler: Drop nir_lower_to_source_mods() and related handling.") Reviewed-by: Jason Ekstrand <[email protected]> Reviewed-by: Alyssa Rosenzweig <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4691>
* intel/compiler: Don't copy prop source mods into PICK_HIGH_32BITKenneth Graunke2020-04-221-1/+2
| | | | | | | | | | | | | | | | | | VEC4_OPCODE_PICK_HIGH_32BIT performs 32-bit UD access on a 64-bit DF value. abs and negate make sense on DF, but break entirely when trying to access pieces of the value as unsigned integer dwords. Fixes an fsign Piglit test on Ivybridge: tests/spec/arb_gpu_shader_fp64/execution/built-in-functions/vs-sign-neg-abs It had regressed when I removed nir_lower_to_source_modifiers, as that caused us to start generating different code which provoked this bug. Fixes: b7c47c4f7cf ("intel/compiler: Drop nir_lower_to_source_mods() and related handling.") Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/2817 Reviewed-by: Jason Ekstrand <[email protected]> Reviewed-by: Alyssa Rosenzweig <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4691>
* docs: update calendar, add news item, and link releases notes for 20.0.5Dylan Baker2020-04-223-7/+4
| | | | Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4688>
* docs: Add sha256 sums for 20.0.5Dylan Baker2020-04-221-1/+1
| | | | Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4688>
* docs: Add relnotes for 20.0.5Dylan Baker2020-04-221-0/+213
| | | | Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4688>
* v3d: support for textureQueryLODAlejandro Piñeiro2020-04-222-27/+21
| | | | | | | | | | | | | | | | | | | Fixes all the ARB_texture_query_lod piglit tests, and needed to get the Vulkan CTS textureQueryLOD passing with the ongoing Vulkan driver. Note that LOD Query bit flag became only available on V42 of the hw, but the v3d40_tex is using V41 as reference. In order to avoid setting up the infrastructure to support both v41 and v42, we manually set the bit if the device version is the correct one. We also fix how the ARB_texture_query_lod (so EXT_texture_query_lod) is exposed. Before this commit it was always exposed (wrongly as it was not really supported). Now it is exposed for devinfo.ver >= 42. v2: move _need_sampler helper to nir.h (Eric Anholt) Reviewed-by: Eric Anholt <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4677>
* nir: add nir_tex_instr_need_sampler helperAlejandro Piñeiro2020-04-221-0/+24
| | | | | | | | That is basically nir_tex_instr sampler_index documentation comment expressed as a helper. Reviewed-by: Eric Anholt <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4677>
* v3d/packet: fixing TMU_Config_Parameter_2 definitionAlejandro Piñeiro2020-04-221-3/+3
| | | | | | | | v41 interchanged the size and start values for the Padding, and it seems that v42 inherited it when adding the LOD Query bit. Reviewed-by: Eric Anholt <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4677>
* v3d/tex: Configuration Parameter 1 can be only skipped if P2 can be skipped tooAlejandro Piñeiro2020-04-221-2/+9
| | | | | | | | | | | | | Configuration Parameter packets 1 and 2 are pointed as optional, but it is not clearly stated if you can skip only P1 when P2 is needed. In the practice, it seems that the situation P0 - non-P1 - P2 can causes problems, and at least on the simulator, it seems that sampler info are attempted to be accessed. So let's just be conservative, and only skip P1 configuration if we can skip P2 configuration too. Reviewed-by: Eric Anholt <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4677>
* v3d/tex: don't configure tmu config 1 if not neededAlejandro Piñeiro2020-04-221-27/+66
| | | | | | | | | | | | | | | | | | | TMU configuration parameter 1 configures the sampler for the texture operation. But there are some texture operations that doesn't need a sampler. Skipping the configuration could provide a small perf improvement on OpenGL. On the incoming Vulkan driver, would allow us to avoid to set up an unneeded sampler. Note that we still need to add the sampler configuration parameter if the output is a 32bit, as it is on the sampler where we configure that info. Also, note that for images this is done comparing against a unpacked p1 default. But in order to do that it is needed to go through the code that fills up the unpacked p1. We can skip that too. Reviewed-by: Eric Anholt <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4677>
* turnip: implement VK_EXT_sampler_filter_minmaxJonathan Marek2020-04-224-2/+26
| | | | | | | Passes dEQP-VK.pipeline.sampler.view_type.* Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4662>
* turnip: enable cube arraysJonathan Marek2020-04-221-1/+1
| | | | | | | Passes dEQP-VK.pipeline.sampler.view_type.cube_array.* Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4663>
* turnip: implement VK_EXT_filter_cubicJonathan Marek2020-04-224-6/+40
| | | | | Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4672>
* turnip: implement VK_EXT_sample_locationsJonathan Marek2020-04-229-48/+135
| | | | | | | | | | | | | Passes tests in: dEQP-VK.pipeline.multisample.sample_locations_ext.* Note that these tests fail because of gl_PrimitiveID not working correctly: dEQP-VK.pipeline.multisample.sample_locations_ext.verify_location.* Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4665>
* turnip: set shader key msaa fieldJonathan Marek2020-04-221-0/+6
| | | | | | | Fixes per-sample interpolation. Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4665>
* aco: coalesce v_mad's accumulator with definition's affinitiesDaniel Schürmann2020-04-221-15/+13
| | | | | | | | Totals from affected shaders: Code Size: 8922676 -> 8915192 (-0.08 %) bytes Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: use upper part of gap in register file if it is beneficial for stridingDaniel Schürmann2020-04-221-5/+16
| | | | | | | | | | | Totals from affected shaders: SGPRS: 1717288 -> 1716984 (-0.02 %) VGPRS: 1305924 -> 1304904 (-0.08 %) Code Size: 138508892 -> 138420144 (-0.06 %) bytes Max Waves: 115726 -> 115735 (0.01 %) Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: try to always find a register with stride for even sizesDaniel Schürmann2020-04-221-2/+4
| | | | | | | | | | | Totals from affected shaders: SGPRS: 1162400 -> 1162400 (0.00 %) VGPRS: 947364 -> 946960 (-0.04 %) Code Size: 98399300 -> 98399004 (-0.00 %) bytes Max Waves: 74665 -> 74682 (0.02 %) Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: stop get_reg_simple after reaching max_used_gprDaniel Schürmann2020-04-221-1/+7
| | | | | Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: refactor get_reg_simple() to return early on exact matchesDaniel Schürmann2020-04-221-25/+22
| | | | | | | in the best fit algorithm Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: don't create vector affinities for operands which are not killed or are ↵Daniel Schürmann2020-04-221-1/+1
| | | | | | | | | | | | | duplicates Totals from affected shaders: SGPRS: 825184 -> 825184 (0.00 %) VGPRS: 697640 -> 697240 (-0.06 %) Code Size: 79244104 -> 79201072 (-0.05 %) bytes Max Waves: 42388 -> 42386 (-0.00 %) Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: allocate full register for subdword definitions if HW doesn't support itDaniel Schürmann2020-04-222-5/+26
| | | | | Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: move attempt to find strided register into get_reg_simple()Daniel Schürmann2020-04-221-8/+9
| | | | | | | | | | | This simplifies code and helps some shaders Totals from affected shaders: Code Size: 51227172 -> 51202216 (-0.05 %) bytes Max Waves: 19955 -> 19948 (-0.04 %) Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: use DefInfo in more places to simplify RADaniel Schürmann2020-04-221-42/+19
| | | | | Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: create and use DefInfo struct in RADaniel Schürmann2020-04-221-45/+71
| | | | | | | for maintaining all information necessary to find a register. Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: create pseudo dummy instruction in RA to be used for live-range splitsDaniel Schürmann2020-04-221-2/+6
| | | | | Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: refactor get_reg() to also handle affinitiesDaniel Schürmann2020-04-221-60/+51
| | | | | | | | | | | This simplifies definition handling and helps a few shaders Totals from affected shaders: Code Size: 659540 -> 659376 (-0.02 %) bytes Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: refactor get_reg() to take Temp instead of RegClassDaniel Schürmann2020-04-221-85/+84
| | | | | | | | This patch also moves get_reg_specified() and get_reg_vec() before get_reg() to make use of it later. Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* aco: simplify operand handling in RADaniel Schürmann2020-04-221-72/+53
| | | | | Reviewed-by: Rhys Perry <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4573>
* turnip: enable VK_FORMAT_S8_UINT as stencil formatJonathan Marek2020-04-224-20/+33
| | | | | Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4588>
* turnip: improve GMEM load/store logicJonathan Marek2020-04-224-59/+89
| | | | | | | | | Determine load/store at renderpass creation time. This also fixes behavior with S8_UINT. Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4588>
* turnip: disable depth test for S8_UINT attachmentJonathan Marek2020-04-221-6/+13
| | | | | Signed-off-by: Jonathan Marek <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4588>
* aco: implement 64-bit sgpr swapsRhys Perry2020-04-221-1/+10
| | | | | | | | | | | | | | | In our pipeline-db, helps almost exclusively Detroit: Become Human. Totals from 6726 (5.36% of 125503) affected shaders: CodeSize: 74680952 -> 74102228 (-0.77%) Instrs: 14551507 -> 14406001 (-1.00%) Cycles: 1748272436 -> 1690173104 (-3.32%) VMEM: 964671 -> 964058 (-0.06%) Copies: 1993312 -> 1847806 (-7.30%) Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4469>
* aco: implement sub-dword swapsRhys Perry2020-04-223-140/+320
| | | | | | Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4469>
* aco: add VOP3P_instructionRhys Perry2020-04-224-19/+85
| | | | | | | | | The optimizer isn't yet updated to handle this, since lower_to_hw_instr will be the only user for now. Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4469>
* aco: fix copy statistic for 64-bit vgpr constant copyRhys Perry2020-04-221-0/+1
| | | | | | | | The statistic is in units of instructions. Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4469>
* ir3: Fix bug with shaders that only exit via discardConnor Abbott2020-04-222-0/+71
| | | | | | | | | | | | | | | | discard is supposed to be a terminator, killing the thread, so that it's possible to exit main solely by a discard e.g. inside of an infinite loop. However, it currently isn't treated as a terminator in NIR due to workarounds turning it into demote (d3d-style kill) and even if that were fixed, we probably wouldn't want to treat discard_if as a jump since otherwise the scheduler wouldn't be able to schedule things around it. So, add this workaround which inserts jump instructions as necessary to guarantee that the program always terminates. This fixes a hang in dEQP-VK.graphicsfuzz.while-inside-switch, which conditionally does a discard inside an infinite loop. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4658>