summaryrefslogtreecommitdiffstats
path: root/src/gallium/include/pipe
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/include/pipe')
-rw-r--r--src/gallium/include/pipe/p_screen.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/gallium/include/pipe/p_screen.h b/src/gallium/include/pipe/p_screen.h
index 9a1fc37280e..0f2831b6eda 100644
--- a/src/gallium/include/pipe/p_screen.h
+++ b/src/gallium/include/pipe/p_screen.h
@@ -500,6 +500,17 @@ struct pipe_screen {
struct pipe_resource *resource,
unsigned int nrects,
const struct pipe_box *rects);
+
+ /**
+ * Run driver-specific NIR lowering and optimization passes.
+ *
+ * State trackers should call this before passing shaders to drivers,
+ * and ideally also before shader caching.
+ *
+ * \param optimize Whether the input shader hasn't been optimized and
+ * should be.
+ */
+ void (*finalize_nir)(struct pipe_screen *screen, void *nir, bool optimize);
};