void iris_init_flush_functions(struct pipe_context *ctx);
-/* iris_blorp.c */
-void gen8_init_blorp(struct iris_context *ice);
-void gen9_init_blorp(struct iris_context *ice);
-void gen10_init_blorp(struct iris_context *ice);
-void gen11_init_blorp(struct iris_context *ice);
-
/* iris_border_color.c */
void iris_init_border_color_pool(struct iris_context *ice);
uint32_t iris_upload_border_color(struct iris_context *ice,
union pipe_color_union *color);
-/* iris_state.c */
-void gen8_init_state(struct iris_context *ice);
-void gen9_init_state(struct iris_context *ice);
-void gen10_init_state(struct iris_context *ice);
-void gen11_init_state(struct iris_context *ice);
-void gen8_emit_urb_setup(struct iris_context *ice,
- struct iris_batch *batch,
- const unsigned size[4],
- bool tess_present, bool gs_present);
-void gen9_emit_urb_setup(struct iris_context *ice,
- struct iris_batch *batch,
- const unsigned size[4],
- bool tess_present, bool gs_present);
-void gen10_emit_urb_setup(struct iris_context *ice,
- struct iris_batch *batch,
- const unsigned size[4],
- bool tess_present, bool gs_present);
-void gen11_emit_urb_setup(struct iris_context *ice,
- struct iris_batch *batch,
- const unsigned size[4],
- bool tess_present, bool gs_present);
-
/* iris_program.c */
void iris_upload_ubo_ssbo_surf_state(struct iris_context *ice,
struct pipe_shader_buffer *buf,
void gen9_toggle_preemption(struct iris_context *ice,
struct iris_batch *batch,
const struct pipe_draw_info *draw);
+
+#ifdef genX
+# include "iris_genx_protos.h"
+#else
+# define genX(x) gen4_##x
+# include "iris_genx_protos.h"
+# undef genX
+# define genX(x) gen5_##x
+# include "iris_genx_protos.h"
+# undef genX
+# define genX(x) gen6_##x
+# include "iris_genx_protos.h"
+# undef genX
+# define genX(x) gen7_##x
+# include "iris_genx_protos.h"
+# undef genX
+# define genX(x) gen75_##x
+# include "iris_genx_protos.h"
+# undef genX
+# define genX(x) gen8_##x
+# include "iris_genx_protos.h"
+# undef genX
+# define genX(x) gen9_##x
+# include "iris_genx_protos.h"
+# undef genX
+# define genX(x) gen10_##x
+# include "iris_genx_protos.h"
+# undef genX
+# define genX(x) gen11_##x
+# include "iris_genx_protos.h"
+# undef genX
+#endif
+
#endif
--- /dev/null
+/*
+ * Copyright © 2019 Intel Corporation
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the "Software"),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+ * DEALINGS IN THE SOFTWARE.
+ */
+
+/* GenX-specific function declarations.
+ *
+ * Don't include this directly, it will be included by iris_context.h.
+ *
+ * NOTE: This header can be included multiple times, from the same file.
+ */
+
+/* iris_state.c */
+void genX(init_state)(struct iris_context *ice);
+void genX(emit_urb_setup)(struct iris_context *ice,
+ struct iris_batch *batch,
+ const unsigned size[4],
+ bool tess_present, bool gs_present);
+
+/* iris_blorp.c */
+void genX(init_blorp)(struct iris_context *ice);
+