summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* gm107/ir: optimize 32-bit CONST load to movSamuel Pitoiset2016-11-262-0/+17
| | | | | | | | | This is not allowed for indirect accesses because the source GPR might be erased by a subsequent instruction (WaR hazard) if we don't emit a read dep bar. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* gm107/ir: do not combine CONST loadsSamuel Pitoiset2016-11-261-2/+7
| | | | | | | | | | | | | | This will allow to use MOV instead of LD. The main advantage is that MOV doesn't require a read dependency barrier while LD does, and so this will both reduce barriers pressure and the number of stall counts needed to read data from constant memory. This is currently only for user uniform accesses. I should do something similar when loading from the driver constant buffer but it seems like a bit tricky to handle for now. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]>
* anv/device: Remove a bogus finishme commentJason Ekstrand2016-11-251-1/+0
| | | | We've been properly detecting bit6 swizzling for a long time now.
* i965: Enable fast clears for multi-lodBen Widawsky2016-11-251-15/+0
| | | | | | | | | | | | | | | | | | | | On SKL (also fast clear is used for level 0, layer 0): Manhattan 3.0: 3.88434% +/- 0.814659% Manhattan 3.0 off: 3.25542% +/- 0.101149% Trex: 3.43501% +/- 0.31223% Trex off: 4.13781% +/- 0.0993569% ON BDW: Manhattan 3.0: 1.37079% +/- 0.571208% Manhattan 3.0 off: 1.74029% +/- 0.267499% v2 (Ben, Matt): Fix rebase error by removing the perf warning v3 (Topi): Rebased on top of revised eligibility logic Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Allow single-sampled miptree to be resolved and sharedTopi Pohjolainen2016-11-251-1/+1
| | | | | Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965/gen8: Relax asserts prohibiting arrayed/mipmapped fast clearsTopi Pohjolainen2016-11-253-14/+18
| | | | | Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Use ISL for CCS layoutsTopi Pohjolainen2016-11-252-104/+38
| | | | | | | | | | One can now also delete intel_get_non_msrt_mcs_alignment(). v2 (Jason): Do not leak aux buf but allocate only after getting ISL surfaces. Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Resolve non-compressed fast clears prior layered renderingTopi Pohjolainen2016-11-251-0/+13
| | | | | Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Restrict fast color clear on first slice onlyTopi Pohjolainen2016-11-251-0/+8
| | | | | Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Track fast color clear state in level/layer granularityTopi Pohjolainen2016-11-253-30/+68
| | | | | | | | | | | | | | | | Note that RESOLVED is not tracked in the map explicitly. Absence of item implicitly means RESOLVED state. v2: Added intel_resolve_map_clear() into intel_miptree_release() v3 (Jason): Properly handle the assumption of resolve map not containing any items with state RESOLVED. Removed unnecessary intel_miptree_set_fast_clear_state() call in brw_blorp_resolve_color() preventing intel_miptree_set_fast_clear_state() from asserting against RESOLVED. Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Move fast clear state enumeration into resolve mapTopi Pohjolainen2016-11-253-65/+68
| | | | | | | | Status is still tracked per miptree. Next patch will switch to resolve map per slice/level. Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Refactor check if color resolve is neededTopi Pohjolainen2016-11-251-15/+28
| | | | | Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Add plumbing for fast clear layer/level detailsTopi Pohjolainen2016-11-252-19/+34
| | | | | | | | | | | | | | | | | | | | | | Until now fast clear has been supported only for non-layered and non-mipmapped buffers. However, from gen8 onwards there is hardware support also for layered/mipmapped. Once this is enabled, fast clear operations target specific layer/level and call for the state to be tracked in the same granularity. This is the first step providing the details from callers to the state tracking. Patch introduces new interface for reading and writing the state hiding the upcoming bookkeeping changes in the call sites. There is bunch of sanity checks added that will be relaxed per hardware generation later on when the actual functionality is enabled. v2: Rebased on top current master setting the state in blorp_surf_for_miptree(). v3: Replace open-coded resolved check in surface state emission with intel_miptree_has_color_unresolved(). Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Add interface for checking multiple slices if any is unresolvedTopi Pohjolainen2016-11-252-0/+13
| | | | | Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Provide slice details to renderbuffer fast clear state trackerTopi Pohjolainen2016-11-254-16/+68
| | | | | | | | This patch also introduces getter and setter for fast clear state preparing for tracking the state per slice. Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Split per miptree and per slice/level fast clear bitsTopi Pohjolainen2016-11-253-16/+16
| | | | | | | | | | | | | | | | Currently the status bits for fast clear include the flag telling if non-multisampled mcs buffer should be used at all. Once the state tracking is changed to follow individual levels/layers one still needs to have the mcs enabling information in the miptree. Therefore simply split it out to its own boolean. Possible follow-up work is to combine disable_aux_buffers and no_ccs into single enum. v2 (Jason): Changed no_msrt_mcs to no_ccs and updated comment Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Provide slice details to color resolverTopi Pohjolainen2016-11-256-18/+51
| | | | | | | | v2: Make intel_miptree_resolve_color() take start layer and layer count. Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Add new interface for full color resolvesTopi Pohjolainen2016-11-258-11/+23
| | | | | | | | | Upcoming patches will introduce fast clear in level/layer granularity like the driver does already for depth/hiz. This patch introduces equivalent full resolve option. Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: Refactor lossless compression state trackingTopi Pohjolainen2016-11-254-15/+7
| | | | | | | | | | | | | | Essentially this moves fast clear state update away from surface state setup into brw_postdraw_set_buffers_need_resolve() that gets called just after draw submission. Calling intel_miptree_used_for_rendering() can be drop for gen6 and earlier as it is no-op. v2: Rebased on top current master setting the state in blorp_surf_for_miptree(). Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* Revert "glsl: allow layout qualifier overrides with ↵Andres Gomez2016-11-251-6/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ARB_shading_language_420pack" This reverts commit aaa69c79cd584db4d9c6ea7794e93d29f3d54572. The commit was erroneous because the ast_layout_expression class is meant to hold a list used for an after check that all the declared values for a layout-qualifier-name are consistent. Therefore, the check for the possibility of duplicated values was previously fixed to happen much sooner, in the GLSL parser and the merge of layout qualifiers, and the process_qualifier_constant method only needs to check that the values are consistent. By now, those layout-qualifier-name represented as a ast_layout_expression are "max_vertices", "invocations", "vertices", "local_size_[x|y|z]" and "xfb_stride". From page 40 (page 46 of the PDF) of the GLSL 1.50 spec: " All geometry shader output layout declarations in a program must declare the same layout and same value for max_vertices." From page 44 (page 50 of the PDF) of the GLSL 4.00 spec: " If an invocation count is declared, all such declarations must specify the same count." From page 47 (page 53 of the PDF) of the GLSL 4.00 spec: " All tessellation control shader layout declarations in a program must specify the same output patch vertex count." From page 60 (page 66 of the PDF) of the GLSL 4.30 spec: " Also, if such a layout qualifier is declared more than once in the same shader, all those declarations must set the same set of local work-group sizes and set them to the same values; otherwise a compile-time error results. If multiple compute shaders attached to a single program object declare local work-group size, the declarations must be identical; otherwise a link-time error results." From page 73 (page 79 of the PDF) of the GLSL 4.40 spec: " While xfb_stride can be declared multiple times for the same buffer, it is a compile-time or link-time error to have different values specified for the stride for the same buffer." Fixes GL44-CTS.enhanced_layouts.xfb_duplicated_stride Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* Revert "glsl: geom shader max_vertices layout must match."Andres Gomez2016-11-253-13/+9
| | | | | | | | | | | | | | | | | | This reverts commit 4c863993780a11cea6f88fa0682796bee5794042. The commit was erroneous because the ast_layout_expression class was created to hold a list of values for a layout-qualifier-name which is allowed to appear in more than one expression in the same shader/program but not to hold different values. In other words, the list is used for an after check that all the declared values for a layout-qualifier-name are consistent. Therefore, the values stored must match always, not just for "max_vertices" or any other eventual layout-qualifier-name. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: push layout-qualifier-name values from variable declarations to globalAndres Gomez2016-11-253-23/+60
| | | | | | | | | | | | | | | | | | | | | | After the previous modifications in the merging of the layout-qualifier-name values, we no longer push the final value in a declaration to the global values. This regression happens because we don't call for merging on the right-most layout qualifier of a declaration which is also the overriding one in case of multiple appearances. Now, we add a new method to push these values to the global ones and we call for this just after all the layout-qualifier collapsing has happened in a declaration. This simplifies how this was working in two ways; we make a clear differentiation of when we are pushing this to the global values since before it was mixed in the merging call and we only run this once all the processing for layout-qualifiers in a declaration has happened. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: simplified error checking for duplicated layout-qualifiersAndres Gomez2016-11-252-24/+6
| | | | | | | | | The GLSL parser has been simplified to check for the needed GL_ARB_shading_language_420pack extension just when merging the qualifiers in the proper cases. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: simplified ast_type_qualifier::merge_into_[in|out]_qualifier APIAndres Gomez2016-11-253-12/+10
| | | | | | | | | | | Since we modified the way in which multiple repetitions of the same layout-qualifier-name in a single declaration collapse into the ast_type_qualifier class, we can simplify the merge_into_[in|out]_qualifier APIs through removing the create_node parameter. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: ignore all but the rightmost layout qualifier name from the rightmost ↵Andres Gomez2016-11-253-77/+84
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | layout qualifier From page 46 (page 52 of the PDF) of the GLSL 4.20 spec: " More than one layout qualifier may appear in a single declaration. If the same layout-qualifier-name occurs in multiple layout qualifiers for the same declaration, the last one overrides the former ones." Consider this example: " #version 150 #extension GL_ARB_shading_language_420pack: enable layout(max_vertices=2) layout(max_vertices=3) out; layout(max_vertices=3) out;" Although different values for "max_vertices" results in a compilation error. The above code is valid because max_vertices=2 is ignored. Hence, when merging qualifiers in an ast_type_qualifier, we now ignore new appearances of a same layout-qualifier-name if the new "is_multiple_layouts_merge" parameter is on, since the GLSL parser works in this case from right to left. In addition, any special treatment for the buffer, uniform, in or out layout defaults has been moved in the GLSL parser to the rule triggered just after any previous processing/merging on the layout-qualifiers has happened in a single declaration since it was run too soon previously. Fixes GL44-CTS.shading_language_420pack.qualifier_override_layout Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: refactor duplicated validations between 2 layout-qualifiersAndres Gomez2016-11-251-50/+76
| | | | | | | | | | | | Several layout-qualifier validations are duplicated in the merge_qualifier and validate_in_qualifier methods. We would rather have them refactored into single calls. Suggested by Timothy. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: assert on incoherent point mode layout-id-qualifier validationAndres Gomez2016-11-251-10/+6
| | | | | | | | | | | | | | | The point mode value in an ast_type_qualifier can only be true if the flag is already set since this layout-id-qualifier can only be or not be present in a shader. Hence, it is useless to check for its value if the flag is already set. Just replaced with an assert. V2: assert instead of checking for coherence and raising a compilation error. Suggested by Timothy. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: remove unneeded check for incompatible primitive types in GSAndres Gomez2016-11-251-10/+3
| | | | | | | | | | | | The validation of the default in layout qualifier already assures that we won't have 2 ast_gs_input_layout objects with different primitive type values. In fact, the validation already assures that we won't have 2 ast_gs_input_layout objects in the AST tree at all. The check for an error in the shader has been replaced by an assert. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: simplifies the merge of the default in layout qualifierAndres Gomez2016-11-251-84/+81
| | | | | | | | | | | | | | The merge into the default in layout qualifier duplicates a lot of code that can be reused from the generic merge method. Now, we use the generic merge method inside the specific merge for the default in layout qualifier. The generic merge method has been completed with some bits that were only present in the merge for the default in layout qualifier and the specific validation bits have been moved to the validation method for the default in layout qualifier. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: split default in layout qualifier mergeAndres Gomez2016-11-253-62/+93
| | | | | | | | | | | | | | | Currently, the default in layout qualifier merge performs specific validation and merge. We want to split out the validation from the merge so they can be done independently. Additionally, for simplification, the direction of the validation and merge is changed so the ast_type_qualifier calling the method is the one validated and merged against the default in qualifier. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: split default out layout qualifier mergeAndres Gomez2016-11-253-37/+72
| | | | | | | | | | | | | | | Currently, the default out layout qualifier merge performs specific validation and merge. We want to split out the validation from the merge so they can be done independently. Additionally, for simplification, the direction of the validation and merge is changed so the ast_type_qualifier calling the method is the one validated and merged against the default out qualifier. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: merge layouts into the default one as the last step in interface blocksAndres Gomez2016-11-254-22/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Consider this example: " #version 150 core #extension GL_ARB_shading_language_420pack: require #extension GL_ARB_explicit_attrib_location: require layout(location=0) out vec4 o; layout(binding=2) layout(binding=3, std140) uniform U { vec4 a; } u[2];" As there is 2 layout-qualifiers for the uniform U and the binding layout-qualifier-id is duplicated, the rules set by the ARB_shading_language_420pack spec state that the rightmost should prevail. Our ast_type_qualifier merges with others in a way that if the value for a layout-qualifier-id is set in both, the object being merged overwrites the value of the object invoking the merge. Hence, the merge has to happen from the left layout towards the right one and this was not happening for interface blocks because we were merging into the default layout qualifier. Now, the merge is done from left to right and, as a last step, we merge into the default layout qualifier if needed, so the values of the explicit layouts prevail over it. V2: added a default_layout variable instead of a layout_helper and make the merge directly over the layout one. Suggested by Timothy. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* glsl: ignore all but the rightmost layout-qualifier-nameAndres Gomez2016-11-251-5/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a layout contains a duplicated layout-qualifier-name in a single declaration, only the last occurrence should be taken into account. From page 59 (page 65 of the PDF) of the GLSL 4.40 spec: " More than one layout qualifier may appear in a single declaration. Additionally, the same layout-qualifier-name can occur multiple times within a layout qualifier or across multiple layout qualifiers in the same declaration. When the same layout-qualifier-name occurs multiple times, in a single declaration, the last occurrence overrides the former occurrence(s)." Consider this example: " #version 150 #extension GL_ARB_enhanced_layouts: enable layout(max_vertices=2, max_vertices=3) out; layout(max_vertices=3) out;" Although different values for "max_vertices" results in a compilation error. The above code is valid because max_vertices=2 is ignored. When merging qualifiers in an ast_type_qualifier, we now simply ignore new appearances of a same layout-qualifier-name if the "is_single_layout_merge" parameter is true, this works because the GLSL parser processes qualifiers from right to left. Reviewed-by: Timothy Arceri <[email protected]> Signed-off-by: Andres Gomez <[email protected]>
* anv/state: if enabled, use anisotropic filtering also with VK_FILTER_NEARESTIago Toral Quiroga2016-11-251-1/+1
| | | | | | | | Fixes multiple Vulkan CTS tests that combine anisotropy and VK_FILTER_NEAREST in dEQP-VK.texture.filtering_anisotropy.* Reviewed-by: Lionel Landwerlin <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* clover: Restore support for LLVM <= 3.9.Vedran Miletić2016-11-242-6/+21
| | | | | | | | | | | | | | | | | | The commit 8e430ff8b060b4e8e922bae24b3c57837da6ea77 broke support for LLVM 3.9 and older versions in Clover. This patch restores it and refactors the support using Clover compatibility layer for LLVM. v2: merged #ifdef blocks v3: added support for LLVM 3.6-3.8 v4: add missing #ifdef around <memory> v5: simplify using templates and lambda Signed-off-by: Vedran Miletić <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98740 Tested-by[v4]: Pierre Moreau <[email protected]> Tested-by: Vinson Lee <[email protected]> Reviewed-by: Francisco Jerez <[email protected]> Reviewed-by: Jan Vesely <[email protected]>
* scons: Recognize LLVM_CONFIG environment variable.Vinson Lee2016-11-243-10/+12
| | | | | | Signed-off-by: Vinson Lee <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Jose Fonseca <[email protected]>
* radv: Don't generate radv_timestamp.hBas Nieuwenhuizen2016-11-242-8/+1
| | | | | | | | Not needed anymore. Signed-off-by: Bas Nieuwenhuizen <[email protected]> Reviewed-by: Dave Airlie <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* radv: fix texel fetch offset with 2d arrays.Dave Airlie2016-11-241-3/+4
| | | | | | | | | | | | The code didn't limit the offsets to the number supplied, so if we expected 3 but only got 2 we were accessing undefined memory. This fixes random failures in: dEQP-VK.glsl.texture_functions.texelfetchoffset.sampler2darray_* Reviewed-by: Bas Nieuwenhuizen <[email protected]> Cc: "13.0" <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* mesa/getteximage: Add validation of target to glGetTextureImageEduardo Lima Mitev2016-11-241-0/+5
| | | | | | | | | | | | | | | | | | | | There is an specific list of texture targets that can be used with glGetTextureImage. From OpenGL 4.5 spec, section '8.11 Texture Queries', page 234 of the PDF: "An INVALID_ENUM error is generated if the effective target is not one of TEXTURE_1D , TEXTURE_2D , TEXTURE_3D , TEXTURE_1D_- ARRAY , TEXTURE_2D_ARRAY , TEXTURE_CUBE_MAP_ARRAY , TEXTURE_- RECTANGLE , one of the targets from table 8.19 (for GetTexImage and GetnTexImage only), or TEXTURE_CUBE_MAP (for GetTextureImage only)." We are currently not validating the target for glGetTextureImage. As an example, calling this function on a texture with target GL_TEXTURE_2D_MULTISAMPLE should return INVALID_ENUM, but instead it hits an assertion down the road in the i965 driver. Reviewed-by: Nicolai Hähnle <[email protected]>
* main/texobj: Check that texture id > 0 before looking it up in hash-tableEduardo Lima Mitev2016-11-241-2/+3
| | | | | | | | | | | | | _mesa_lookup_texture_err() is not currently checking that the texture-id can be zero, but _mesa_HashLookup() doesn't expect the key to be zero, and will fail an assertion. Considering that _mesa_lookup_texture_err() is called from _mesa_GetTextureImage and _mesa_GetTextureSubImage with user provided arguments, we must validate the texture-id before looking it up in the hash-table. Reviewed-by: Nicolai Hähnle <[email protected]>
* util: fix memory leak from the fragment shaders for SINT<->UINT blitsCharmaine Lee2016-11-231-1/+1
| | | | | | This patch deletes those fragment shaders in util_blitter_destroy(). Reviewed-by: Brian Paul <[email protected]>
* i965: Always reserve clip distance VUE slots in SSO mode.Kenneth Graunke2016-11-231-0/+13
| | | | | | | | | | | | | | This fixes rendering in Dolphin on Vulkan since we enabled clip distances. (Dolphin on GL has a similar bug because the linker fails to eliminate unused clip distance built-in arrays, but it isn't using SSO...so that needs more fixing.) Also fixes a Piglit test: spec/glsl-1.50/execution/geometry.clip-distance-vs-gs-out-sso Signed-off-by: Kenneth Graunke <[email protected]> Tested-by: Emmanuel Gil Peyrot <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* anv/gen7: only enable dual-source blending when there are dual-source factorsIlia Mirkin2016-11-231-3/+33
| | | | | | | | Apparently the hw wedges otherwise, as mentioned in i965 comments. Reported-by: Emmanuel Gil Peyrot <[email protected]> Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* swr: clear every layer of the attached surfacesIlia Mirkin2016-11-231-6/+29
| | | | | Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Tim Rowley <[email protected]>
* swr: [rasterizer core] pipe renderTargetArrayIndex through to clearsIlia Mirkin2016-11-237-20/+35
| | | | | | | | | | Currently clears only operate on the 0th array index (ignoring surface layout parameters). Instead normalize to take a RTAI like all the load/store tile logic does, and use ComputeSurfaceAddress to properly take the surface state's lod/array index into account. Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Tim Rowley <[email protected]>
* swr: [rasterizer core] clear data now comes in as floatIlia Mirkin2016-11-231-10/+4
| | | | | | | | The non-fast-clear path was never updated after clear colors were passed in as floats. Remove the now-harmful conversion from unorm8. Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Tim Rowley <[email protected]>
* swr: [rasterizer core] actually perform clear before store in GetHotTileIlia Mirkin2016-11-231-0/+12
| | | | | | | | | When switching render target array indexes (as might happen in a GS, or in a future change, with layered clears), if the previous state is HOTTILE_CLEAR, we should actually clear the tile before saving it off. Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Tim Rowley <[email protected]>
* i965: Fix a mistake from porting the URB allocation code to arrays.Kenneth Graunke2016-11-231-1/+1
| | | | | | | | | | | | | | | | | Commit 6d416bcd846a49414f210cd761789156c37a7b3e (i965: Use arrays in Gen7+ URB code.) introduced a regression which caused us to fail to allocate all of our URB space. - total_wants -= ds_wants; + total_wants -= additional; The new line should have been total_wants -= wants[i]. Fixes a large performance regression in TessMark. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98815 Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* i965: Use 3DSTATE_CLIP's User Clip Distance Enable bitmask on Gen8+.Kenneth Graunke2016-11-235-18/+17
| | | | | | | | | | | | | | | | | | | | | | | | Gen6-7.5 specify the user clip distance enable bitmask in 3DSTATE_CLIP. Gen8+ normally uses the new internal signalling mechanism to select the one specified in the last enabled shader stage (3DSTATE_VS, DS, or GS). This is a pretty good fit for Vulkan, or even newer GL, where the bitmask comes entirely from the shader. But with glClipPlane(), this is dynamic state, and we have to listen to _NEW_TRASNFORM. Clip plane enables are the only reason the VS/DS/GS atoms need to listen to _NEW_TRANSFORM. 3DSTATE_CLIP already has to listen to it in order to support ARB_clip_control settings. Setting the "Use the 3DSTATE_CLIP bitmask" force enable bit allows us to drop _NEW_TRANSFORM from all the shader stage atoms, so we can re-emit them less often. Improves performance of OglBatch7 (version 6) by 2.70773% +/- 0.491257% (n = 38) at 1024x768 on Cherryview. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* radv: fix flipped blitsDave Airlie2016-11-231-57/+111
| | | | | | | | This fixes: dEQP-VK.api.copy_and_blit.blit_image.simple_tests.mirror* Reviewed-by: Bas Nieuwenhuizen <[email protected]> Signed-off-by: Dave Airlie <[email protected]>