summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* mesa/compiler: copy early fragment tests to shader_info in ↵Timothy Arceri2016-10-262-4/+1
| | | | | | _mesa_copy_linked_program_data() Reviewed-by: Jason Ekstrand <[email protected]>
* meta: remove remaining tabs in meta.cTimothy Arceri2016-10-261-49/+49
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* i965: replace brw_compute_program with brw_programTimothy Arceri2016-10-264-35/+8
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* i965: replace brw_fragment_program with brw_programTimothy Arceri2016-10-266-36/+13
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* i965: replace brw_tess_{eval,ctrl}_program with brw_programTimothy Arceri2016-10-268-74/+18
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* i965: replace brw_geomerty_program with brw_programTimothy Arceri2016-10-267-37/+10
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* i965: replace brw_vertex_program with new generic brw_programTimothy Arceri2016-10-266-23/+20
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* st/mesa/r200/i915/i965: eliminate gl_fragment_programTimothy Arceri2016-10-2660-361/+281
| | | | | | | | | | Here we move OriginUpperLeft and PixelCenterInteger into gl_program all other fields have been replace by shader_info. V2: Don't use anonymous union/structs to hold vertex/fragment fields suggested by Ian. Reviewed-by: Jason Ekstrand <[email protected]>
* i965/mesa/st/swrast: set fs shader_info directly and switch to using itTimothy Arceri2016-10-2617-54/+30
| | | | | | | Note we access shader_info from the program struct rather than the nir_shader pointer because shader cache won't create a nir_shader. Reviewed-by: Jason Ekstrand <[email protected]>
* mesa: remove now unused IsCentroid from gl_fragment_programTimothy Arceri2016-10-262-11/+1
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* st/mesa: get interpolation location at translation timeTimothy Arceri2016-10-263-15/+18
| | | | | | | | Rather then messing around creating bitfields and arrays to store the interpolation location just translate it on the fly. Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: remove unused debug paramTimothy Arceri2016-10-262-17/+17
| | | | | | | | | This was accidently disabled in 832bcc3613 not long after it was added. Since it's only for gen5 and lower we might as well just remove it rather than fixing it. Reviewed-by: Jason Ekstrand <[email protected]>
* compiler: update the comment for enum glsl_interp_modeTimothy Arceri2016-10-261-1/+1
| | | | | | We no longer store the interp mode with the program metadata. Reviewed-by: Jason Ekstrand <[email protected]>
* glsl: remove now unused InterpQualifierTimothy Arceri2016-10-262-12/+2
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* i965: remove unused BRW_STATE_INTERPOLATION_MAP flagTimothy Arceri2016-10-262-3/+0
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* i965: rewrite brw_setup_vue_interpolation()Timothy Arceri2016-10-2622-129/+149
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Here brw_setup_vue_interpolation() is rewritten not to use the InterpQualifier array in gl_fragment_program which will allow us to remove it. This change also makes the code which is only used by gen4/5 more self contained as it now has its own gen5_fragment_program struct rather than storing the map in brw_context. This means the interpolation map will only get processed once and will get stored in the in memory cache rather than being processed everytime the fs changes. Also by calling this from the fs compile code rather than from the upload code and using the interpolation assigned there we can get rid of the BRW_NEW_INTERPOLATION_MAP flag. It might not seem ideal to add a gen5_fragment_program struct however by the end of this series we will have gotten rid of all the brw_{shader_stage}_program structs and replaced them with a generic brw_program struct so there will only be two program structs which is better than what we have now. V2: Don't remove BRW_NEW_INTERPOLATION_MAP from dirty_bit_map until the following patch to fix build error. V3 - Suggestions by Jason: - name struct gen4_fragment_program rather than gen5_fragment_program - don't use enum with memset() - create interp mode set helper and simplify logic to call it - add assert when calling function to show prog will never be NULL for gen4/5 i.e. no Vulkan Reviewed-by: Jason Ekstrand <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* st/mesa: stop making use of InterpQualifier arrayTimothy Arceri2016-10-262-31/+41
| | | | | | | | | | | A following patch is going to merge the gl_fragment_program struct into a common gl_program and we want to avoid all stages having this array. V2: use TGSI_INTERPOLATE_COUNT as the temporary placeholder. Suggested by Marek. Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* mesa: remove unrequired codeTimothy Arceri2016-10-261-2/+0
| | | | | | InterpQualifier is never set for ARB programs so this will do nothing. Reviewed-by: Jason Ekstrand <[email protected]>
* i965/mesa/st: eliminate gl_compute_programTimothy Arceri2016-10-2616-80/+37
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* mesa: set cs shader_info metadata directlyTimothy Arceri2016-10-262-14/+3
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* st/mesa: switch cs over to shared shader_infoTimothy Arceri2016-10-262-8/+5
| | | | | Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* compiler: add additional cs metadata fields to shader infoTimothy Arceri2016-10-262-0/+6
| | | | | | And copy values from GLSL. Reviewed-by: Jason Ekstrand <[email protected]>
* mesa/i965/i915/r200: eliminate gl_vertex_programTimothy Arceri2016-10-2646-310/+268
| | | | | | | Here we move the only field in gl_vertex_program to the ARB program fields in gl_program. Reviewed-by: Jason Ekstrand <[email protected]>
* i965: switch vs over to shared shader_infoTimothy Arceri2016-10-262-4/+3
| | | | | | | Note we access shader_info from the program struct rather than the nir_shader pointer because shader cache won't create a nir_shader. Reviewed-by: Jason Ekstrand <[email protected]>
* i965/mesa/st: eliminate gl_geometry_programTimothy Arceri2016-10-2620-90/+45
| | | | | | We now get all the gs metadata from shader_info. Reviewed-by: Jason Ekstrand <[email protected]>
* mesa: set gs shader_info metadata directlyTimothy Arceri2016-10-262-19/+7
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* st/mesa: switch gs over to shared shader_infoTimothy Arceri2016-10-261-4/+7
| | | | | Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: switch gs over to shared shader_infoTimothy Arceri2016-10-261-1/+1
| | | | | | | Note we access shader_info from the program struct rather than the nir_shader pointer because shader cache won't create a nir_shader. Reviewed-by: Jason Ekstrand <[email protected]>
* compiler: add input primative field for gs in shader infoTimothy Arceri2016-10-262-0/+4
| | | | | | And copy the value from GLSL. Reviewed-by: Jason Ekstrand <[email protected]>
* i965/mesa/st: eliminate gl_tess_eval_programTimothy Arceri2016-10-2621-93/+53
| | | | | | We now get all the tes metadata from shader_info. Reviewed-by: Jason Ekstrand <[email protected]>
* mesa: copy tes metadata directly to shared shader infoTimothy Arceri2016-10-262-18/+4
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* st/mesa: switch tes over to shared shader_infoTimothy Arceri2016-10-261-5/+7
| | | | | Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: switch tes over to shared shader_infoTimothy Arceri2016-10-262-8/+8
| | | | | | | Note we access shader_info from the program struct rather than the nir_shader pointer because shader cache won't create a nir_shader. Reviewed-by: Jason Ekstrand <[email protected]>
* compiler: add fields for tes metadata to shader infoTimothy Arceri2016-10-262-0/+18
| | | | | | And copy the values from gl_tess_eval_program struct. Reviewed-by: Jason Ekstrand <[email protected]>
* i965/mesa/st: eliminate gl_tess_ctrl_programTimothy Arceri2016-10-2621-76/+41
| | | | | | We now get all the tcs metadata from shader_info. Reviewed-by: Jason Ekstrand <[email protected]>
* mesa: set tcs shader_info metadata directlyTimothy Arceri2016-10-262-7/+1
| | | | Reviewed-by: Jason Ekstrand <[email protected]>
* st/mesa: switch tcs over to shared shader_infoTimothy Arceri2016-10-262-2/+2
| | | | | Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
* i965: switch tcs over to shared shader_infoTimothy Arceri2016-10-262-22/+17
| | | | | | | Note we access shader_info from the program struct rather than the nir_shader pointer because shader cache won't create a nir_shader. Reviewed-by: Jason Ekstrand <[email protected]>
* glsl: add temporary copy_shader_info() functionTimothy Arceri2016-10-268-53/+97
| | | | | | | | | | | | | This function is added here to ease refactoring towards using the new shared shader_info. Once refactoring is complete and values are set directly it will be removed. We call it from _mesa_copy_linked_program_data() rather than glsl_to_nir() so that the values will be set for all drivers. In order to do this some calls need to be moved around so that we make sure to call do_set_program_inouts() before _mesa_copy_linked_program_data() Reviewed-by: Jason Ekstrand <[email protected]>
* glsl: add a shader info field to the gl_program typeTimothy Arceri2016-10-263-1/+11
| | | | | | | | | | And use this field as the source for shader info in the nir_shader this will allow us to set some of these fields from GLSL directly. It will also simplify restoring from shader cache and allow the removal of duplicate fields from GLSL. Reviewed-by: Jason Ekstrand <[email protected]>
* nir/i965/anv/radv/gallium: make shader info a pointerTimothy Arceri2016-10-2665-358/+372
| | | | | | | | | | When restoring something from shader cache we won't have and don't want to create a nir_shader this change detaches the two. There are other advantages such as being able to reuse the shader info populated by GLSL IR. Reviewed-by: Jason Ekstrand <[email protected]>
* nir: move nir_shader_info to a common compiler headerTimothy Arceri2016-10-263-97/+134
| | | | | | | This will allow use to stop copying values between structs and will also simplify handling handling these values in the shader cache. Reviewed-by: Jason Ekstrand <[email protected]>
* mesa: modify _mesa_copy_linked_program_data() to take gl_linked_shaderTimothy Arceri2016-10-266-32/+34
| | | | | | | | | | This allows us to do some small tidy ups, but will also allow us to call a new function that copies values to a shared shader info from here. In order to make this change this function now requires _mesa_reference_program() to have previously been called. Reviewed-by: Jason Ekstrand <[email protected]>
* vulkan/wsi/wayland: fix ARGB window supportFredrik Höglund2016-10-261-1/+4
| | | | | | | | | | Use an ARGB format for the DRM buffer when the compositeAlpha field in VkSwapchainCreateInfoKHR is set to VK_COMPOSITE_ALPHA_PRE_MULTIPLIED_BIT_KHR. Cc: "13.0" <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* vulkan/wsi/x11: fix ARGB window supportFredrik Höglund2016-10-261-4/+15
| | | | | | | | | Pass the correct depth to xcb_dri3_pixmap_from_buffer_checked(). Otherwise xcb_present_pixmap() fails with a BadMatch error. Cc: "13.0" <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* radv: mark the fence as submitted and signalled in vkAcquireNextImageKHRFredrik Höglund2016-10-263-9/+18
| | | | | | | | This stops the debug layers from complaining when fences are used to throttle image acquisition. Cc: "13.0" <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* radv: Replace "abi_versions" with correct "api_version".Matt Turner2016-10-252-2/+2
| | | | | | | | git history shows "abi_versions" was used from the outset. Cc: <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98415 Reviewed-by: Dave Airlie <[email protected]>
* anv: Replace "abi_versions" with correct "api_version".Matt Turner2016-10-252-2/+2
| | | | | | | | git history shows "abi_versions" was used from the outset. Cc: <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98415 Reviewed-by: Dave Airlie <[email protected]>
* nv50/ir: start LocalCSE with getFirst to merge PHI instructionsKarol Herbst2016-10-251-1/+1
| | | | | | | | | | | | | | | total instructions in shared programs : 3499888 -> 3499445 (-0.01%) total gprs used in shared programs : 453866 -> 453803 (-0.01%) total local used in shared programs : 21621 -> 21621 (0.00%) total bytes used in shared programs : 32078952 -> 32074936 (-0.01%) local gpr inst bytes helped 0 39 119 119 hurt 0 0 0 0 Signed-off-by: Karol Herbst <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]> Reviewed-by: Samuel Pitoiset <[email protected]>
* nvc0: use correct bufctx when invalidating CP texturesSamuel Pitoiset2016-10-251-1/+1
| | | | | | Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Ilia Mirkin <[email protected]> Cc: "12.0 13.0" <[email protected]>