anv: Pre-compute push ranges for graphics pipelines
authorJason Ekstrand <jason@jlekstrand.net>
Fri, 8 Nov 2019 15:42:30 +0000 (09:42 -0600)
committerJason Ekstrand <jason@jlekstrand.net>
Mon, 18 Nov 2019 18:35:14 +0000 (18:35 +0000)
commitaecde235198f6c8dccb0d26b6397f1efb5e22bfe
tree73b21bce0fcd669a58af96290d759d1b148add39
parent4b392ced2d744fccffe95490ff57e6b41033c266
anv: Pre-compute push ranges for graphics pipelines

It turns off that emitting push constants is one of the hottest paths in
the driver and ANY work we do there costs us.  By pre-computing things a
bit ahead of time, we shave 5% off the runtime of a CPU-limited example
running with the Dawn WebGPU implementation.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
src/intel/Makefile.sources
src/intel/vulkan/anv_nir.h
src/intel/vulkan/anv_nir_compute_push_layout.c [new file with mode: 0644]
src/intel/vulkan/anv_pipeline.c
src/intel/vulkan/anv_pipeline_cache.c
src/intel/vulkan/anv_private.h
src/intel/vulkan/genX_cmd_buffer.c
src/intel/vulkan/meson.build