Find a file
Lionel Landwerlin b49b18f0b7 anv: reduce BT emissions & surface state writes with push descriptors
Zink on Anv running Gfxbench gl_driver2 is significantly slower than
Iris.

The reason is simple, whereas Iris implements uniform updates using
push constants and only has to emit 3DSTATE_CONSTANT_* packets, Zink
uses push descriptors with a uniform buffer, which on our
implementation use both push constants & binding tables.

Anv ends up doing the following for each uniform update :
   - allocate 2 surface states :
      - one for the uniform buffer as the offset specify by zink
      - one for the descriptor set buffer
   - pack the 2 RENDER_SURFACE_STATE
   - re-emit binding tables
   - re-emit push constants

Of all of those operations, only the last one ends up being useful in
this benchmark because all the uniforms have been promoted to push
constants.

This change defers the 3 first operations at draw time and executes
them only if the pipeline needs them.

Vkoverhead before / after :
  descriptor_template_1ubo_push:                      40670 / 85786
  descriptor_template_12ubo_push:                      4050 / 13820
  descriptor_template_1combined_sampler_push,         34410 / 34043
  descriptor_template_16combined_sampler_push,         2746 / 2711
  descriptor_template_1sampled_image_push,            34765 / 34089
  descriptor_template_16sampled_image_push,            2794 / 2649
  descriptor_template_1texelbuffer_push,             108537 / 111342
  descriptor_template_16texelbuffer_push,             20619 / 20166
  descriptor_template_1ssbo_push,                     41506 / 85976
  descriptor_template_8ssbo_push,                      6036 / 18703
  descriptor_template_1image_push,                    88932 / 89610
  descriptor_template_16image_push,                   20937 / 20959
  descriptor_template_1imagebuffer_push,             108407 / 113240
  descriptor_template_16imagebuffer_push,             32661 / 34651

Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Reviewed-by: Emma Anholt <emma@anholt.net>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/19050>
2022-10-14 23:03:16 +00:00
.github/workflows ci: rename GitHub CI workflow from ci to macos to be a bit more explicit about what it covers 2022-08-16 16:54:13 +00:00
.gitlab/issue_templates gitlab: ask that reporters don't include long logs in descriptions 2022-06-08 15:06:51 +00:00
.gitlab-ci ci/bin: Remove whitespace from token files 2022-10-14 01:46:52 +00:00
android Android: Use libgbm_mesa name for SDK30+ 2022-09-12 07:37:27 +00:00
bin bin/perf-annotate-jit.py: Update to Python 3. 2022-08-21 22:14:43 -07:00
build-support configure: commit test files 2017-10-16 16:32:43 -07:00
docs docs: update calendar and link releases notes for 22.2.1 2022-10-11 21:30:02 +00:00
include EGL: sync headers with Khronos 2022-10-12 19:26:01 +00:00
src anv: reduce BT emissions & surface state writes with push descriptors 2022-10-14 23:03:16 +00:00
subprojects meson,amd: Remove Windows libelf wrap 2022-09-19 12:51:12 +00:00
.dir-locals.el dir-locals.el: Adds White Space support 2016-11-14 19:17:49 +02:00
.editorconfig rusticl: added 2022-09-12 05:58:12 +00:00
.gitattributes Add new rules to .gitattributes 2022-01-19 15:17:17 +00:00
.gitignore .gitignore: Qualify the path for the ignored build directory. 2022-06-09 22:53:37 +00:00
.gitlab-ci.yml CI: Re-enable Collabora devices 2022-10-07 18:38:45 +00:00
.graphqlrc.yml ci/bin: Add utility to find jobs dependencies 2022-08-03 23:10:37 +00:00
.mailmap .mailmap: change spelling for Constantine Kharlamov 2022-08-12 13:11:03 +00:00
CODEOWNERS CODEOWNERS: evelikov renamed to xexaxo 2022-06-24 12:28:59 +00:00
meson.build meson: remove unused EGL_NO_X11 definition 2022-10-12 19:26:01 +00:00
meson_options.txt remove xvmc 2022-10-01 03:17:33 +00:00
README.rst docs: promote #dri-devel on oftc over freenode 2021-05-24 09:21:48 +00:00
VERSION VERSION: bump 22.3.0-devel 2022-08-03 17:16:14 +00:00

`Mesa <https://mesa3d.org>`_ - The 3D Graphics Library
======================================================


Source
------

This repository lives at https://gitlab.freedesktop.org/mesa/mesa.
Other repositories are likely forks, and code found there is not supported.


Build & install
---------------

You can find more information in our documentation (`docs/install.rst
<https://mesa3d.org/install.html>`_), but the recommended way is to use
Meson (`docs/meson.rst <https://mesa3d.org/meson.html>`_):

.. code-block:: sh

  $ mkdir build
  $ cd build
  $ meson ..
  $ sudo ninja install


Support
-------

Many Mesa devs hang on IRC; if you're not sure which channel is
appropriate, you should ask your question on `OFTC's #dri-devel
<irc://irc.oftc.net/dri-devel>`_, someone will redirect you if
necessary.
Remember that not everyone is in the same timezone as you, so it might
take a while before someone qualified sees your question.
To figure out who you're talking to, or which nick to ping for your
question, check out `Who's Who on IRC
<https://dri.freedesktop.org/wiki/WhosWho/>`_.

The next best option is to ask your question in an email to the
mailing lists: `mesa-dev\@lists.freedesktop.org
<https://lists.freedesktop.org/mailman/listinfo/mesa-dev>`_


Bug reports
-----------

If you think something isn't working properly, please file a bug report
(`docs/bugs.rst <https://mesa3d.org/bugs.html>`_).


Contributing
------------

Contributions are welcome, and step-by-step instructions can be found in our
documentation (`docs/submittingpatches.rst
<https://mesa3d.org/submittingpatches.html>`_).

Note that Mesa uses gitlab for patches submission, review and discussions.