[igt-dev] [PATCH i-g-t v2] lib/gen6_render: Refactoring lib
Katarzyna Dec
katarzyna.dec at intel.com
Tue Apr 10 14:19:04 UTC 2018
From: Lukasz Kalamarz <lukasz.kalamarz at intel.com>
This patch is starting a series of refactoring changes for *render*
libs. A lot of code in those libraries is copy/pasted and renamed for
different gen.
Changes made in this patch:
- removal of duplicated registers definitions
- move field definitions above it register definition
- move definitions of register into ascending order
- unify spaces between register name and it's address/value
v2:
- Fix warnings from check_patch script.
Signed-off-by: Lukasz Kalamarz <lukasz.kalamarz at intel.com>
Cc: Katarzyna Dec <katarzyna.dec at intel.com>
Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio at intel.com>
---
lib/gen6_render.h | 1600 ++++++++++++++++++++++-------------------------------
1 file changed, 668 insertions(+), 932 deletions(-)
diff --git a/lib/gen6_render.h b/lib/gen6_render.h
index 8a4ec53..82e3f92 100644
--- a/lib/gen6_render.h
+++ b/lib/gen6_render.h
@@ -9,23 +9,94 @@
((Subopcode) << 16))
#define GEN6_STATE_BASE_ADDRESS GEN6_3D(0, 1, 1)
-#define GEN6_STATE_SIP GEN6_3D(0, 1, 2)
+# define BUFFER_SIZE_MODIFY (1 << 0)
+# define BASE_ADDRESS_MODIFY (1 << 0)
+#define GEN6_STATE_SIP GEN6_3D(0, 1, 2)
#define GEN6_PIPELINE_SELECT GEN6_3D(1, 1, 4)
+# define PIPELINE_SELECT_3D 0
+# define PIPELINE_SELECT_MEDIA 1
#define GEN6_MEDIA_STATE_POINTERS GEN6_3D(2, 0, 0)
#define GEN6_MEDIA_OBJECT GEN6_3D(2, 1, 0)
#define GEN6_3DSTATE_BINDING_TABLE_POINTERS GEN6_3D(3, 0, 1)
-# define GEN6_3DSTATE_BINDING_TABLE_MODIFY_PS (1 << 12)/* for GEN6 */
-# define GEN6_3DSTATE_BINDING_TABLE_MODIFY_GS (1 << 9) /* for GEN6 */
-# define GEN6_3DSTATE_BINDING_TABLE_MODIFY_VS (1 << 8) /* for GEN6 */
+# define GEN6_3DSTATE_BINDING_TABLE_MODIFY_PS (1 << 12)/* for GEN6 */
+# define GEN6_3DSTATE_BINDING_TABLE_MODIFY_GS (1 << 9) /* for GEN6 */
+# define GEN6_3DSTATE_BINDING_TABLE_MODIFY_VS (1 << 8) /* for GEN6 */
+
+#define GEN6_3DSTATE_SAMPLER_STATE_POINTERS GEN6_3D(3, 0, 2)
+# define GEN6_3DSTATE_SAMPLER_STATE_MODIFY_PS (1 << 12)
+# define GEN6_3DSTATE_SAMPLER_STATE_MODIFY_GS (1 << 9)
+# define GEN6_3DSTATE_SAMPLER_STATE_MODIFY_VS (1 << 8)
+
+#define GEN6_3DSTATE_URB GEN6_3D(3, 0, 5)
+/* DW1 */
+# define GEN6_3DSTATE_URB_VS_SIZE_SHIFT 16
+# define GEN6_3DSTATE_URB_VS_ENTRIES_SHIFT 0
+/* DW2 */
+# define GEN6_3DSTATE_URB_GS_ENTRIES_SHIFT 8
+# define GEN6_3DSTATE_URB_GS_SIZE_SHIFT 0
#define GEN6_3DSTATE_VERTEX_BUFFERS GEN6_3D(3, 0, 8)
#define GEN6_3DSTATE_VERTEX_ELEMENTS GEN6_3D(3, 0, 9)
#define GEN6_3DSTATE_INDEX_BUFFER GEN6_3D(3, 0, 0xa)
#define GEN6_3DSTATE_VF_STATISTICS GEN6_3D(1, 0, 0xb)
+#define GEN6_3DSTATE_VIEWPORT_STATE_POINTERS GEN6_3D(3, 0, 0xd)
+# define GEN6_3DSTATE_VIEWPORT_STATE_MODIFY_CC (1 << 12)
+# define GEN6_3DSTATE_VIEWPORT_STATE_MODIFY_SF (1 << 11)
+# define GEN6_3DSTATE_VIEWPORT_STATE_MODIFY_CLIP (1 << 10)
+
+#define GEN6_3DSTATE_CC_STATE_POINTERS GEN6_3D(3, 0, 0xe)
+#define GEN6_3DSTATE_VS GEN6_3D(3, 0, 0x10)
+#define GEN6_3DSTATE_GS GEN6_3D(3, 0, 0x11)
+/* DW4 */
+# define GEN6_3DSTATE_GS_DISPATCH_START_GRF_SHIFT 0
+
+#define GEN6_3DSTATE_CLIP GEN6_3D(3, 0, 0x12)
+#define GEN6_3DSTATE_SF GEN6_3D(3, 0, 0x13)
+/* DW1 */
+# define GEN6_3DSTATE_SF_NUM_OUTPUTS_SHIFT 22
+# define GEN6_3DSTATE_SF_URB_ENTRY_READ_LENGTH_SHIFT 11
+# define GEN6_3DSTATE_SF_URB_ENTRY_READ_OFFSET_SHIFT 4
+/* DW2 */
+/* DW3 */
+# define GEN6_3DSTATE_SF_CULL_BOTH (0 << 29)
+# define GEN6_3DSTATE_SF_CULL_NONE (1 << 29)
+# define GEN6_3DSTATE_SF_CULL_FRONT (2 << 29)
+# define GEN6_3DSTATE_SF_CULL_BACK (3 << 29)
+/* DW4 */
+# define GEN6_3DSTATE_SF_TRI_PROVOKE_SHIFT 29
+# define GEN6_3DSTATE_SF_LINE_PROVOKE_SHIFT 27
+# define GEN6_3DSTATE_SF_TRIFAN_PROVOKE_SHIFT 25
+# define GEN6_3DSTATE_SF_VERTEX_SUB_PIXEL_PRECISION_SHIFT 12
+
+#define GEN6_3DSTATE_WM GEN6_3D(3, 0, 0x14)
+/* DW2 */
+# define GEN6_3DSTATE_WM_SAMPLER_COUNT_SHIFT 27
+# define GEN6_3DSTATE_WM_BINDING_TABLE_ENTRY_COUNT_SHIFT 18
+/* DW4 */
+# define GEN6_3DSTATE_WM_DISPATCH_START_GRF_0_SHIFT 16
+/* DW5 */
+# define GEN6_3DSTATE_WM_MAX_THREADS_SHIFT 25
+# define GEN6_3DSTATE_WM_DISPATCH_ENABLE (1 << 19)
+# define GEN6_3DSTATE_WM_16_DISPATCH_ENABLE (1 << 1)
+# define GEN6_3DSTATE_WM_8_DISPATCH_ENABLE (1 << 0)
+/* DW6 */
+# define GEN6_3DSTATE_WM_NUM_SF_OUTPUTS_SHIFT 20
+# define GEN6_3DSTATE_WM_NONPERSPECTIVE_SAMPLE_BARYCENTRIC (1 << 15)
+# define GEN6_3DSTATE_WM_NONPERSPECTIVE_CENTROID_BARYCENTRIC (1 << 14)
+# define GEN6_3DSTATE_WM_NONPERSPECTIVE_PIXEL_BARYCENTRIC (1 << 13)
+# define GEN6_3DSTATE_WM_PERSPECTIVE_SAMPLE_BARYCENTRIC (1 << 12)
+# define GEN6_3DSTATE_WM_PERSPECTIVE_CENTROID_BARYCENTRIC (1 << 11)
+# define GEN6_3DSTATE_WM_PERSPECTIVE_PIXEL_BARYCENTRIC (1 << 10)
+
+#define GEN6_3DSTATE_CONSTANT_VS GEN6_3D(3, 0, 0x15)
+#define GEN6_3DSTATE_CONSTANT_GS GEN6_3D(3, 0, 0x16)
+#define GEN6_3DSTATE_CONSTANT_PS GEN6_3D(3, 0, 0x17)
+#define GEN6_3DSTATE_SAMPLE_MASK GEN6_3D(3, 0, 0x18)
+
#define GEN6_3DSTATE_DRAWING_RECTANGLE GEN6_3D(3, 1, 0)
#define GEN6_3DSTATE_CONSTANT_COLOR GEN6_3D(3, 1, 1)
#define GEN6_3DSTATE_SAMPLER_PALETTE_LOAD GEN6_3D(3, 1, 2)
@@ -34,93 +105,14 @@
# define GEN6_3DSTATE_DEPTH_BUFFER_TYPE_SHIFT 29
# define GEN6_3DSTATE_DEPTH_BUFFER_FORMAT_SHIFT 18
-#define GEN6_3DSTATE_POLY_STIPPLE_OFFSET GEN6_3D(3, 1, 6)
+#define GEN6_3DSTATE_POLY_STIPPLE_OFFSET GEN6_3D(3, 1, 6)
#define GEN6_3DSTATE_POLY_STIPPLE_PATTERN GEN6_3D(3, 1, 7)
#define GEN6_3DSTATE_LINE_STIPPLE GEN6_3D(3, 1, 8)
#define GEN6_3DSTATE_GLOBAL_DEPTH_OFFSET_CLAMP GEN6_3D(3, 1, 9)
/* These two are BLC and CTG only, not BW or CL */
#define GEN6_3DSTATE_AA_LINE_PARAMS GEN6_3D(3, 1, 0xa)
#define GEN6_3DSTATE_GS_SVB_INDEX GEN6_3D(3, 1, 0xb)
-#define GEN6_3DSTATE_MONOFILTER_SIZE GEN6_3D(3, 1, 0x11)
-#define GEN6_3DPRIMITIVE GEN6_3D(3, 3, 0)
-
-#define GEN6_3DSTATE_CLEAR_PARAMS GEN6_3D(3, 1, 0x10)
-/* DW1 */
-# define GEN6_3DSTATE_DEPTH_CLEAR_VALID (1 << 15)
-
-#define GEN6_3DSTATE_SAMPLER_STATE_POINTERS GEN6_3D(3, 0, 0x02)
-# define GEN6_3DSTATE_SAMPLER_STATE_MODIFY_PS (1 << 12)
-# define GEN6_3DSTATE_SAMPLER_STATE_MODIFY_GS (1 << 9)
-# define GEN6_3DSTATE_SAMPLER_STATE_MODIFY_VS (1 << 8)
-
-#define GEN6_3DSTATE_URB GEN6_3D(3, 0, 0x05)
-/* DW1 */
-# define GEN6_3DSTATE_URB_VS_SIZE_SHIFT 16
-# define GEN6_3DSTATE_URB_VS_ENTRIES_SHIFT 0
-/* DW2 */
-# define GEN6_3DSTATE_URB_GS_ENTRIES_SHIFT 8
-# define GEN6_3DSTATE_URB_GS_SIZE_SHIFT 0
-
-#define GEN6_3DSTATE_VIEWPORT_STATE_POINTERS GEN6_3D(3, 0, 0x0d)
-# define GEN6_3DSTATE_VIEWPORT_STATE_MODIFY_CC (1 << 12)
-# define GEN6_3DSTATE_VIEWPORT_STATE_MODIFY_SF (1 << 11)
-# define GEN6_3DSTATE_VIEWPORT_STATE_MODIFY_CLIP (1 << 10)
-
-#define GEN6_3DSTATE_CC_STATE_POINTERS GEN6_3D(3, 0, 0x0e)
-
-#define GEN6_3DSTATE_VS GEN6_3D(3, 0, 0x10)
-
-#define GEN6_3DSTATE_GS GEN6_3D(3, 0, 0x11)
-/* DW4 */
-# define GEN6_3DSTATE_GS_DISPATCH_START_GRF_SHIFT 0
-
-#define GEN6_3DSTATE_CLIP GEN6_3D(3, 0, 0x12)
-
-#define GEN6_3DSTATE_SF GEN6_3D(3, 0, 0x13)
-/* DW1 */
-# define GEN6_3DSTATE_SF_NUM_OUTPUTS_SHIFT 22
-# define GEN6_3DSTATE_SF_URB_ENTRY_READ_LENGTH_SHIFT 11
-# define GEN6_3DSTATE_SF_URB_ENTRY_READ_OFFSET_SHIFT 4
-/* DW2 */
-/* DW3 */
-# define GEN6_3DSTATE_SF_CULL_BOTH (0 << 29)
-# define GEN6_3DSTATE_SF_CULL_NONE (1 << 29)
-# define GEN6_3DSTATE_SF_CULL_FRONT (2 << 29)
-# define GEN6_3DSTATE_SF_CULL_BACK (3 << 29)
-/* DW4 */
-# define GEN6_3DSTATE_SF_TRI_PROVOKE_SHIFT 29
-# define GEN6_3DSTATE_SF_LINE_PROVOKE_SHIFT 27
-# define GEN6_3DSTATE_SF_TRIFAN_PROVOKE_SHIFT 25
-# define GEN6_3DSTATE_SF_VERTEX_SUB_PIXEL_PRECISION_SHIFT 12
-
-#define GEN6_3DSTATE_WM GEN6_3D(3, 0, 0x14)
-/* DW2 */
-# define GEN6_3DSTATE_WM_SAMPLER_COUNT_SHIFT 27
-# define GEN6_3DSTATE_WM_BINDING_TABLE_ENTRY_COUNT_SHIFT 18
-/* DW4 */
-# define GEN6_3DSTATE_WM_DISPATCH_START_GRF_0_SHIFT 16
-/* DW5 */
-# define GEN6_3DSTATE_WM_MAX_THREADS_SHIFT 25
-# define GEN6_3DSTATE_WM_DISPATCH_ENABLE (1 << 19)
-# define GEN6_3DSTATE_WM_16_DISPATCH_ENABLE (1 << 1)
-# define GEN6_3DSTATE_WM_8_DISPATCH_ENABLE (1 << 0)
-/* DW6 */
-# define GEN6_3DSTATE_WM_NUM_SF_OUTPUTS_SHIFT 20
-# define GEN6_3DSTATE_WM_NONPERSPECTIVE_SAMPLE_BARYCENTRIC (1 << 15)
-# define GEN6_3DSTATE_WM_NONPERSPECTIVE_CENTROID_BARYCENTRIC (1 << 14)
-# define GEN6_3DSTATE_WM_NONPERSPECTIVE_PIXEL_BARYCENTRIC (1 << 13)
-# define GEN6_3DSTATE_WM_PERSPECTIVE_SAMPLE_BARYCENTRIC (1 << 12)
-# define GEN6_3DSTATE_WM_PERSPECTIVE_CENTROID_BARYCENTRIC (1 << 11)
-# define GEN6_3DSTATE_WM_PERSPECTIVE_PIXEL_BARYCENTRIC (1 << 10)
-
-
-#define GEN6_3DSTATE_CONSTANT_VS GEN6_3D(3, 0, 0x15)
-#define GEN6_3DSTATE_CONSTANT_GS GEN6_3D(3, 0, 0x16)
-#define GEN6_3DSTATE_CONSTANT_PS GEN6_3D(3, 0, 0x17)
-
-#define GEN6_3DSTATE_SAMPLE_MASK GEN6_3D(3, 0, 0x18)
-
-#define GEN6_3DSTATE_MULTISAMPLE GEN6_3D(3, 1, 0x0d)
+#define GEN6_3DSTATE_MULTISAMPLE GEN6_3D(3, 1, 0xd)
/* DW1 */
# define GEN6_3DSTATE_MULTISAMPLE_PIXEL_LOCATION_CENTER (0 << 4)
# define GEN6_3DSTATE_MULTISAMPLE_PIXEL_LOCATION_UPPER_LEFT (1 << 4)
@@ -128,648 +120,394 @@
# define GEN6_3DSTATE_MULTISAMPLE_NUMSAMPLES_4 (2 << 1)
# define GEN6_3DSTATE_MULTISAMPLE_NUMSAMPLES_8 (3 << 1)
-#define PIPELINE_SELECT_3D 0
-#define PIPELINE_SELECT_MEDIA 1
+#define GEN6_3DSTATE_CLEAR_PARAMS GEN6_3D(3, 1, 0x10)
+/* DW1 */
+# define GEN6_3DSTATE_DEPTH_CLEAR_VALID (1 << 15)
-/* for GEN6_STATE_BASE_ADDRESS */
-#define BASE_ADDRESS_MODIFY (1 << 0)
-
-/* for GEN6_PIPE_CONTROL */
-#define GEN6_PIPE_CONTROL_NOWRITE (0 << 14)
-#define GEN6_PIPE_CONTROL_WRITE_QWORD (1 << 14)
-#define GEN6_PIPE_CONTROL_WRITE_DEPTH (2 << 14)
-#define GEN6_PIPE_CONTROL_WRITE_TIME (3 << 14)
-#define GEN6_PIPE_CONTROL_DEPTH_STALL (1 << 13)
-#define GEN6_PIPE_CONTROL_WC_FLUSH (1 << 12)
-#define GEN6_PIPE_CONTROL_IS_FLUSH (1 << 11)
-#define GEN6_PIPE_CONTROL_TC_FLUSH (1 << 10)
-#define GEN6_PIPE_CONTROL_NOTIFY_ENABLE (1 << 8)
-#define GEN6_PIPE_CONTROL_GLOBAL_GTT (1 << 2)
-#define GEN6_PIPE_CONTROL_LOCAL_PGTT (0 << 2)
-#define GEN6_PIPE_CONTROL_DEPTH_CACHE_FLUSH (1 << 0)
-
-/* VERTEX_BUFFER_STATE Structure */
-#define VB0_BUFFER_INDEX_SHIFT 26
-#define VB0_VERTEXDATA (0 << 20)
-#define VB0_INSTANCEDATA (1 << 20)
-#define VB0_BUFFER_PITCH_SHIFT 0
-#define VB0_NULL_VERTEX_BUFFER (1 << 13)
-
-/* VERTEX_ELEMENT_STATE Structure */
-#define VE0_VERTEX_BUFFER_INDEX_SHIFT 26 /* for GEN6 */
-#define VE0_VALID (1 << 25) /* for GEN6 */
-#define VE0_FORMAT_SHIFT 16
-#define VE0_OFFSET_SHIFT 0
-#define VE1_VFCOMPONENT_0_SHIFT 28
-#define VE1_VFCOMPONENT_1_SHIFT 24
-#define VE1_VFCOMPONENT_2_SHIFT 20
-#define VE1_VFCOMPONENT_3_SHIFT 16
-#define VE1_DESTINATION_ELEMENT_OFFSET_SHIFT 0
-
-/* 3DPRIMITIVE bits */
-#define GEN6_3DPRIMITIVE_VERTEX_SEQUENTIAL (0 << 15)
-#define GEN6_3DPRIMITIVE_VERTEX_RANDOM (1 << 15)
-/* Primitive types are in gen6_defines.h */
-#define GEN6_3DPRIMITIVE_TOPOLOGY_SHIFT 10
-
-#define GEN6_SVG_CTL 0x7400
-
-#define GEN6_SVG_CTL_GS_BA (0 << 8)
-#define GEN6_SVG_CTL_SS_BA (1 << 8)
-#define GEN6_SVG_CTL_IO_BA (2 << 8)
-#define GEN6_SVG_CTL_GS_AUB (3 << 8)
-#define GEN6_SVG_CTL_IO_AUB (4 << 8)
-#define GEN6_SVG_CTL_SIP (5 << 8)
-
-#define GEN6_SVG_RDATA 0x7404
-#define GEN6_SVG_WORK_CTL 0x7408
-
-#define GEN6_VF_CTL 0x7500
-
-#define GEN6_VF_CTL_SNAPSHOT_COMPLETE (1 << 31)
-#define GEN6_VF_CTL_SNAPSHOT_MUX_SELECT_THREADID (0 << 8)
-#define GEN6_VF_CTL_SNAPSHOT_MUX_SELECT_VF_DEBUG (1 << 8)
-#define GEN6_VF_CTL_SNAPSHOT_TYPE_VERTEX_SEQUENCE (0 << 4)
-#define GEN6_VF_CTL_SNAPSHOT_TYPE_VERTEX_INDEX (1 << 4)
-#define GEN6_VF_CTL_SKIP_INITIAL_PRIMITIVES (1 << 3)
-#define GEN6_VF_CTL_MAX_PRIMITIVES_LIMIT_ENABLE (1 << 2)
-#define GEN6_VF_CTL_VERTEX_RANGE_LIMIT_ENABLE (1 << 1)
-#define GEN6_VF_CTL_SNAPSHOT_ENABLE (1 << 0)
-
-#define GEN6_VF_STRG_VAL 0x7504
-#define GEN6_VF_STR_VL_OVR 0x7508
-#define GEN6_VF_VC_OVR 0x750c
-#define GEN6_VF_STR_PSKIP 0x7510
-#define GEN6_VF_MAX_PRIM 0x7514
-#define GEN6_VF_RDATA 0x7518
-
-#define GEN6_VS_CTL 0x7600
-#define GEN6_VS_CTL_SNAPSHOT_COMPLETE (1 << 31)
-#define GEN6_VS_CTL_SNAPSHOT_MUX_VERTEX_0 (0 << 8)
-#define GEN6_VS_CTL_SNAPSHOT_MUX_VERTEX_1 (1 << 8)
-#define GEN6_VS_CTL_SNAPSHOT_MUX_VALID_COUNT (2 << 8)
-#define GEN6_VS_CTL_SNAPSHOT_MUX_VS_KERNEL_POINTER (3 << 8)
-#define GEN6_VS_CTL_SNAPSHOT_ALL_THREADS (1 << 2)
-#define GEN6_VS_CTL_THREAD_SNAPSHOT_ENABLE (1 << 1)
-#define GEN6_VS_CTL_SNAPSHOT_ENABLE (1 << 0)
-
-#define GEN6_VS_STRG_VAL 0x7604
-#define GEN6_VS_RDATA 0x7608
-
-#define GEN6_SF_CTL 0x7b00
-#define GEN6_SF_CTL_SNAPSHOT_COMPLETE (1 << 31)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_0_FF_ID (0 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_0_REL_COUNT (1 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_1_FF_ID (2 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_1_REL_COUNT (3 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_2_FF_ID (4 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_2_REL_COUNT (5 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_COUNT (6 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_SF_KERNEL_POINTER (7 << 8)
-#define GEN6_SF_CTL_MIN_MAX_PRIMITIVE_RANGE_ENABLE (1 << 4)
-#define GEN6_SF_CTL_DEBUG_CLIP_RECTANGLE_ENABLE (1 << 3)
-#define GEN6_SF_CTL_SNAPSHOT_ALL_THREADS (1 << 2)
-#define GEN6_SF_CTL_THREAD_SNAPSHOT_ENABLE (1 << 1)
-#define GEN6_SF_CTL_SNAPSHOT_ENABLE (1 << 0)
-
-#define GEN6_SF_STRG_VAL 0x7b04
-#define GEN6_SF_RDATA 0x7b18
-
-#define GEN6_WIZ_CTL 0x7c00
-#define GEN6_WIZ_CTL_SNAPSHOT_COMPLETE (1 << 31)
-#define GEN6_WIZ_CTL_SUBSPAN_INSTANCE_SHIFT 16
-#define GEN6_WIZ_CTL_SNAPSHOT_MUX_WIZ_KERNEL_POINTER (0 << 8)
-#define GEN6_WIZ_CTL_SNAPSHOT_MUX_SUBSPAN_INSTANCE (1 << 8)
-#define GEN6_WIZ_CTL_SNAPSHOT_MUX_PRIMITIVE_SEQUENCE (2 << 8)
-#define GEN6_WIZ_CTL_SINGLE_SUBSPAN_DISPATCH (1 << 6)
-#define GEN6_WIZ_CTL_IGNORE_COLOR_SCOREBOARD_STALLS (1 << 5)
-#define GEN6_WIZ_CTL_ENABLE_SUBSPAN_INSTANCE_COMPARE (1 << 4)
-#define GEN6_WIZ_CTL_USE_UPSTREAM_SNAPSHOT_FLAG (1 << 3)
-#define GEN6_WIZ_CTL_SNAPSHOT_ALL_THREADS (1 << 2)
-#define GEN6_WIZ_CTL_THREAD_SNAPSHOT_ENABLE (1 << 1)
-#define GEN6_WIZ_CTL_SNAPSHOT_ENABLE (1 << 0)
-
-#define GEN6_WIZ_STRG_VAL 0x7c04
-#define GEN6_WIZ_RDATA 0x7c18
-
-#define GEN6_TS_CTL 0x7e00
-#define GEN6_TS_CTL_SNAPSHOT_COMPLETE (1 << 31)
-#define GEN6_TS_CTL_SNAPSHOT_MESSAGE_ERROR (0 << 8)
-#define GEN6_TS_CTL_SNAPSHOT_INTERFACE_DESCRIPTOR (3 << 8)
-#define GEN6_TS_CTL_SNAPSHOT_ALL_CHILD_THREADS (1 << 2)
-#define GEN6_TS_CTL_SNAPSHOT_ALL_ROOT_THREADS (1 << 1)
-#define GEN6_TS_CTL_SNAPSHOT_ENABLE (1 << 0)
-
-#define GEN6_TS_STRG_VAL 0x7e04
-#define GEN6_TS_RDATA 0x7e08
-
-#define GEN6_TD_CTL_MUX_SHIFT 8
-#define GEN6_TD_CTL_EXTERNAL_HALT_R0_DEBUG_MATCH (1 << 7)
-#define GEN6_TD_CTL_FORCE_EXTERNAL_HALT (1 << 6)
-#define GEN6_TD_CTL_EXCEPTION_MASK_OVERRIDE (1 << 5)
-#define GEN6_TD_CTL_FORCE_THREAD_BREAKPOINT_ENABLE (1 << 4)
-#define GEN6_TD_CTL_BREAKPOINT_ENABLE (1 << 2)
-#define GEN6_TD_CTL2 0x8004
-#define GEN6_TD_CTL2_ILLEGAL_OPCODE_EXCEPTION_OVERRIDE (1 << 28)
-#define GEN6_TD_CTL2_MASKSTACK_EXCEPTION_OVERRIDE (1 << 26)
-#define GEN6_TD_CTL2_SOFTWARE_EXCEPTION_OVERRIDE (1 << 25)
-#define GEN6_TD_CTL2_ACTIVE_THREAD_LIMIT_SHIFT 16
-#define GEN6_TD_CTL2_ACTIVE_THREAD_LIMIT_ENABLE (1 << 8)
-#define GEN6_TD_CTL2_THREAD_SPAWNER_EXECUTION_MASK_ENABLE (1 << 7)
-#define GEN6_TD_CTL2_WIZ_EXECUTION_MASK_ENABLE (1 << 6)
-#define GEN6_TD_CTL2_SF_EXECUTION_MASK_ENABLE (1 << 5)
-#define GEN6_TD_CTL2_CLIPPER_EXECUTION_MASK_ENABLE (1 << 4)
-#define GEN6_TD_CTL2_GS_EXECUTION_MASK_ENABLE (1 << 3)
-#define GEN6_TD_CTL2_VS_EXECUTION_MASK_ENABLE (1 << 0)
-#define GEN6_TD_VF_VS_EMSK 0x8008
-#define GEN6_TD_GS_EMSK 0x800c
-#define GEN6_TD_CLIP_EMSK 0x8010
-#define GEN6_TD_SF_EMSK 0x8014
-#define GEN6_TD_WIZ_EMSK 0x8018
-#define GEN6_TD_0_6_EHTRG_VAL 0x801c
-#define GEN6_TD_0_7_EHTRG_VAL 0x8020
-#define GEN6_TD_0_6_EHTRG_MSK 0x8024
-#define GEN6_TD_0_7_EHTRG_MSK 0x8028
-#define GEN6_TD_RDATA 0x802c
-#define GEN6_TD_TS_EMSK 0x8030
-
-#define GEN6_EU_CTL 0x8800
-#define GEN6_EU_CTL_SELECT_SHIFT 16
-#define GEN6_EU_CTL_DATA_MUX_SHIFT 8
-#define GEN6_EU_ATT_0 0x8810
-#define GEN6_EU_ATT_1 0x8814
-#define GEN6_EU_ATT_DATA_0 0x8820
-#define GEN6_EU_ATT_DATA_1 0x8824
-#define GEN6_EU_ATT_CLR_0 0x8830
-#define GEN6_EU_ATT_CLR_1 0x8834
-#define GEN6_EU_RDATA 0x8840
+#define GEN6_3DSTATE_MONOFILTER_SIZE GEN6_3D(3, 1, 0x11)
#define GEN6_PIPE_CONTROL GEN6_3D(3, 2, 0)
+# define GEN6_PIPE_CONTROL_NOWRITE (0 << 14)
+# define GEN6_PIPE_CONTROL_WRITE_QWORD (1 << 14)
+# define GEN6_PIPE_CONTROL_WRITE_DEPTH (2 << 14)
+# define GEN6_PIPE_CONTROL_WRITE_TIME (3 << 14)
+# define GEN6_PIPE_CONTROL_DEPTH_STALL (1 << 13)
+# define GEN6_PIPE_CONTROL_WC_FLUSH (1 << 12)
+# define GEN6_PIPE_CONTROL_IS_FLUSH (1 << 11)
+# define GEN6_PIPE_CONTROL_TC_FLUSH (1 << 10)
+# define GEN6_PIPE_CONTROL_NOTIFY_ENABLE (1 << 8)
+# define GEN6_PIPE_CONTROL_GLOBAL_GTT (1 << 2)
+# define GEN6_PIPE_CONTROL_LOCAL_PGTT (0 << 2)
+# define GEN6_PIPE_CONTROL_DEPTH_CACHE_FLUSH (1 << 0)
-#define GEN6_3DPRIMITIVE GEN6_3D(3, 3, 0)
+#define GEN6_3DPRIMITIVE GEN6_3D(3, 3, 0)
+# define GEN6_3DPRIMITIVE_VERTEX_SEQUENTIAL (0 << 15)
+# define GEN6_3DPRIMITIVE_VERTEX_RANDOM (1 << 15)
+/* Primitive types are in gen6_defines.h */
+# define GEN6_3DPRIMITIVE_TOPOLOGY_SHIFT 10
-#define GEN6_3DSTATE_CLEAR_PARAMS GEN6_3D(3, 1, 0x10)
-/* DW1 */
-# define GEN6_3DSTATE_DEPTH_CLEAR_VALID (1 << 15)
+/* VERTEX_BUFFER_STATE Structure */
+# define VB0_BUFFER_INDEX_SHIFT 26
+# define VB0_VERTEXDATA (0 << 20)
+# define VB0_INSTANCEDATA (1 << 20)
+# define VB0_BUFFER_PITCH_SHIFT 0
+# define VB0_NULL_VERTEX_BUFFER (1 << 13)
-/* for GEN6+ */
-#define GEN6_3DSTATE_SAMPLER_STATE_POINTERS GEN6_3D(3, 0, 0x02)
-# define GEN6_3DSTATE_SAMPLER_STATE_MODIFY_PS (1 << 12)
-# define GEN6_3DSTATE_SAMPLER_STATE_MODIFY_GS (1 << 9)
-# define GEN6_3DSTATE_SAMPLER_STATE_MODIFY_VS (1 << 8)
+/* VERTEX_ELEMENT_STATE Structure */
+# define VE0_VERTEX_BUFFER_INDEX_SHIFT 26 /* for GEN6 */
+# define VE0_VALID (1 << 25) /* for GEN6 */
+# define VE0_FORMAT_SHIFT 16
+# define VE0_OFFSET_SHIFT 0
+# define VE1_VFCOMPONENT_0_SHIFT 28
+# define VE1_VFCOMPONENT_1_SHIFT 24
+# define VE1_VFCOMPONENT_2_SHIFT 20
+# define VE1_VFCOMPONENT_3_SHIFT 16
+# define VE1_DESTINATION_ELEMENT_OFFSET_SHIFT 0
-#define GEN6_3DSTATE_URB GEN6_3D(3, 0, 0x05)
-/* DW1 */
-# define GEN6_3DSTATE_URB_VS_SIZE_SHIFT 16
-# define GEN6_3DSTATE_URB_VS_ENTRIES_SHIFT 0
-/* DW2 */
-# define GEN6_3DSTATE_URB_GS_ENTRIES_SHIFT 8
-# define GEN6_3DSTATE_URB_GS_SIZE_SHIFT 0
+#define GEN6_SVG_CTL 0x7400
+# define GEN6_SVG_CTL_GS_BA (0 << 8)
+# define GEN6_SVG_CTL_SS_BA (1 << 8)
+# define GEN6_SVG_CTL_IO_BA (2 << 8)
+# define GEN6_SVG_CTL_GS_AUB (3 << 8)
+# define GEN6_SVG_CTL_IO_AUB (4 << 8)
+# define GEN6_SVG_CTL_SIP (5 << 8)
-#define GEN6_3DSTATE_VIEWPORT_STATE_POINTERS GEN6_3D(3, 0, 0x0d)
-# define GEN6_3DSTATE_VIEWPORT_STATE_MODIFY_CC (1 << 12)
-# define GEN6_3DSTATE_VIEWPORT_STATE_MODIFY_SF (1 << 11)
-# define GEN6_3DSTATE_VIEWPORT_STATE_MODIFY_CLIP (1 << 10)
+#define GEN6_SVG_RDATA 0x7404
+#define GEN6_SVG_WORK_CTL 0x7408
+#define GEN6_VF_CTL 0x7500
+# define GEN6_VF_CTL_SNAPSHOT_COMPLETE (1 << 31)
+# define GEN6_VF_CTL_SNAPSHOT_MUX_SELECT_THREADID (0 << 8)
+# define GEN6_VF_CTL_SNAPSHOT_MUX_SELECT_VF_DEBUG (1 << 8)
+# define GEN6_VF_CTL_SNAPSHOT_TYPE_VERTEX_SEQUENCE (0 << 4)
+# define GEN6_VF_CTL_SNAPSHOT_TYPE_VERTEX_INDEX (1 << 4)
+# define GEN6_VF_CTL_SKIP_INITIAL_PRIMITIVES (1 << 3)
+# define GEN6_VF_CTL_MAX_PRIMITIVES_LIMIT_ENABLE (1 << 2)
+# define GEN6_VF_CTL_VERTEX_RANGE_LIMIT_ENABLE (1 << 1)
+# define GEN6_VF_CTL_SNAPSHOT_ENABLE (1 << 0)
-#define GEN6_3DSTATE_CC_STATE_POINTERS GEN6_3D(3, 0, 0x0e)
+#define GEN6_VF_STRG_VAL 0x7504
+#define GEN6_VF_STR_VL_OVR 0x7508
+#define GEN6_VF_VC_OVR 0x750c
+#define GEN6_VF_STR_PSKIP 0x7510
+#define GEN6_VF_MAX_PRIM 0x7514
+#define GEN6_VF_RDATA 0x7518
+#define GEN6_VS_CTL 0x7600
+# define GEN6_VS_CTL_SNAPSHOT_COMPLETE (1 << 31)
+# define GEN6_VS_CTL_SNAPSHOT_MUX_VERTEX_0 (0 << 8)
+# define GEN6_VS_CTL_SNAPSHOT_MUX_VERTEX_1 (1 << 8)
+# define GEN6_VS_CTL_SNAPSHOT_MUX_VALID_COUNT (2 << 8)
+# define GEN6_VS_CTL_SNAPSHOT_MUX_VS_KERNEL_POINTER (3 << 8)
+# define GEN6_VS_CTL_SNAPSHOT_ALL_THREADS (1 << 2)
+# define GEN6_VS_CTL_THREAD_SNAPSHOT_ENABLE (1 << 1)
+# define GEN6_VS_CTL_SNAPSHOT_ENABLE (1 << 0)
-#define GEN6_3DSTATE_VS GEN6_3D(3, 0, 0x10)
+#define GEN6_VS_STRG_VAL 0x7604
+#define GEN6_VS_RDATA 0x7608
+#define GEN6_SF_CTL 0x7b00
+# define GEN6_SF_CTL_SNAPSHOT_COMPLETE (1 << 31)
+# define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_0_FF_ID (0 << 8)
+# define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_0_REL_COUNT (1 << 8)
+# define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_1_FF_ID (2 << 8)
+# define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_1_REL_COUNT (3 << 8)
+# define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_2_FF_ID (4 << 8)
+# define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_2_REL_COUNT (5 << 8)
+# define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_COUNT (6 << 8)
+# define GEN6_SF_CTL_SNAPSHOT_MUX_SF_KERNEL_POINTER (7 << 8)
+# define GEN6_SF_CTL_MIN_MAX_PRIMITIVE_RANGE_ENABLE (1 << 4)
+# define GEN6_SF_CTL_DEBUG_CLIP_RECTANGLE_ENABLE (1 << 3)
+# define GEN6_SF_CTL_SNAPSHOT_ALL_THREADS (1 << 2)
+# define GEN6_SF_CTL_THREAD_SNAPSHOT_ENABLE (1 << 1)
+# define GEN6_SF_CTL_SNAPSHOT_ENABLE (1 << 0)
-#define GEN6_3DSTATE_GS GEN6_3D(3, 0, 0x11)
-/* DW4 */
-# define GEN6_3DSTATE_GS_DISPATCH_START_GRF_SHIFT 0
+#define GEN6_SF_STRG_VAL 0x7b04
+#define GEN6_SF_RDATA 0x7b18
+#define GEN6_WIZ_CTL 0x7c00
+# define GEN6_WIZ_CTL_SNAPSHOT_COMPLETE (1 << 31)
+# define GEN6_WIZ_CTL_SUBSPAN_INSTANCE_SHIFT 16
+# define GEN6_WIZ_CTL_SNAPSHOT_MUX_WIZ_KERNEL_POINTER (0 << 8)
+# define GEN6_WIZ_CTL_SNAPSHOT_MUX_SUBSPAN_INSTANCE (1 << 8)
+# define GEN6_WIZ_CTL_SNAPSHOT_MUX_PRIMITIVE_SEQUENCE (2 << 8)
+# define GEN6_WIZ_CTL_SINGLE_SUBSPAN_DISPATCH (1 << 6)
+# define GEN6_WIZ_CTL_IGNORE_COLOR_SCOREBOARD_STALLS (1 << 5)
+# define GEN6_WIZ_CTL_ENABLE_SUBSPAN_INSTANCE_COMPARE (1 << 4)
+# define GEN6_WIZ_CTL_USE_UPSTREAM_SNAPSHOT_FLAG (1 << 3)
+# define GEN6_WIZ_CTL_SNAPSHOT_ALL_THREADS (1 << 2)
+# define GEN6_WIZ_CTL_THREAD_SNAPSHOT_ENABLE (1 << 1)
+# define GEN6_WIZ_CTL_SNAPSHOT_ENABLE (1 << 0)
-#define GEN6_3DSTATE_CLIP GEN6_3D(3, 0, 0x12)
+#define GEN6_WIZ_STRG_VAL 0x7c04
+#define GEN6_WIZ_RDATA 0x7c18
+#define GEN6_TS_CTL 0x7e00
+# define GEN6_TS_CTL_SNAPSHOT_COMPLETE (1 << 31)
+# define GEN6_TS_CTL_SNAPSHOT_MESSAGE_ERROR (0 << 8)
+# define GEN6_TS_CTL_SNAPSHOT_INTERFACE_DESCRIPTOR (3 << 8)
+# define GEN6_TS_CTL_SNAPSHOT_ALL_CHILD_THREADS (1 << 2)
+# define GEN6_TS_CTL_SNAPSHOT_ALL_ROOT_THREADS (1 << 1)
+# define GEN6_TS_CTL_SNAPSHOT_ENABLE (1 << 0)
-#define GEN6_3DSTATE_SF GEN6_3D(3, 0, 0x13)
-/* DW1 */
-# define GEN6_3DSTATE_SF_NUM_OUTPUTS_SHIFT 22
-# define GEN6_3DSTATE_SF_URB_ENTRY_READ_LENGTH_SHIFT 11
-# define GEN6_3DSTATE_SF_URB_ENTRY_READ_OFFSET_SHIFT 4
-/* DW2 */
-/* DW3 */
-# define GEN6_3DSTATE_SF_CULL_BOTH (0 << 29)
-# define GEN6_3DSTATE_SF_CULL_NONE (1 << 29)
-# define GEN6_3DSTATE_SF_CULL_FRONT (2 << 29)
-# define GEN6_3DSTATE_SF_CULL_BACK (3 << 29)
-/* DW4 */
-# define GEN6_3DSTATE_SF_TRI_PROVOKE_SHIFT 29
-# define GEN6_3DSTATE_SF_LINE_PROVOKE_SHIFT 27
-# define GEN6_3DSTATE_SF_TRIFAN_PROVOKE_SHIFT 25
+#define GEN6_TS_STRG_VAL 0x7e04
+#define GEN6_TS_RDATA 0x7e08
+# define GEN6_TD_CTL_MUX_SHIFT 8
+# define GEN6_TD_CTL_EXTERNAL_HALT_R0_DEBUG_MATCH (1 << 7)
+# define GEN6_TD_CTL_FORCE_EXTERNAL_HALT (1 << 6)
+# define GEN6_TD_CTL_EXCEPTION_MASK_OVERRIDE (1 << 5)
+# define GEN6_TD_CTL_FORCE_THREAD_BREAKPOINT_ENABLE (1 << 4)
+# define GEN6_TD_CTL_BREAKPOINT_ENABLE (1 << 2)
-#define GEN6_3DSTATE_WM GEN6_3D(3, 0, 0x14)
-/* DW2 */
-# define GEN6_3DSTATE_WM_SAMPLER_COUNT_SHIFT 27
-# define GEN6_3DSTATE_WM_BINDING_TABLE_ENTRY_COUNT_SHIFT 18
-/* DW4 */
-# define GEN6_3DSTATE_WM_DISPATCH_START_GRF_0_SHIFT 16
-/* DW5 */
-# define GEN6_3DSTATE_WM_MAX_THREADS_SHIFT 25
-# define GEN6_3DSTATE_WM_DISPATCH_ENABLE (1 << 19)
-# define GEN6_3DSTATE_WM_16_DISPATCH_ENABLE (1 << 1)
-# define GEN6_3DSTATE_WM_8_DISPATCH_ENABLE (1 << 0)
-/* DW6 */
-# define GEN6_3DSTATE_WM_NUM_SF_OUTPUTS_SHIFT 20
-# define GEN6_3DSTATE_WM_NONPERSPECTIVE_SAMPLE_BARYCENTRIC (1 << 15)
-# define GEN6_3DSTATE_WM_NONPERSPECTIVE_CENTROID_BARYCENTRIC (1 << 14)
-# define GEN6_3DSTATE_WM_NONPERSPECTIVE_PIXEL_BARYCENTRIC (1 << 13)
-# define GEN6_3DSTATE_WM_PERSPECTIVE_SAMPLE_BARYCENTRIC (1 << 12)
-# define GEN6_3DSTATE_WM_PERSPECTIVE_CENTROID_BARYCENTRIC (1 << 11)
-# define GEN6_3DSTATE_WM_PERSPECTIVE_PIXEL_BARYCENTRIC (1 << 10)
+# define GEN6_TD_CTL2 0x8004
+# define GEN6_TD_CTL2_ILLEGAL_OPCODE_EXCEPTION_OVERRIDE (1 << 28)
+# define GEN6_TD_CTL2_MASKSTACK_EXCEPTION_OVERRIDE (1 << 26)
+# define GEN6_TD_CTL2_SOFTWARE_EXCEPTION_OVERRIDE (1 << 25)
+# define GEN6_TD_CTL2_ACTIVE_THREAD_LIMIT_SHIFT 16
+# define GEN6_TD_CTL2_ACTIVE_THREAD_LIMIT_ENABLE (1 << 8)
+# define GEN6_TD_CTL2_THREAD_SPAWNER_EXECUTION_MASK_ENABLE (1 << 7)
+# define GEN6_TD_CTL2_WIZ_EXECUTION_MASK_ENABLE (1 << 6)
+# define GEN6_TD_CTL2_SF_EXECUTION_MASK_ENABLE (1 << 5)
+# define GEN6_TD_CTL2_CLIPPER_EXECUTION_MASK_ENABLE (1 << 4)
+# define GEN6_TD_CTL2_GS_EXECUTION_MASK_ENABLE (1 << 3)
+# define GEN6_TD_CTL2_VS_EXECUTION_MASK_ENABLE (1 << 0)
+#define GEN6_TD_VF_VS_EMSK 0x8008
+#define GEN6_TD_GS_EMSK 0x800c
+#define GEN6_TD_CLIP_EMSK 0x8010
+#define GEN6_TD_SF_EMSK 0x8014
+#define GEN6_TD_WIZ_EMSK 0x8018
+#define GEN6_TD_0_6_EHTRG_VAL 0x801c
+#define GEN6_TD_0_7_EHTRG_VAL 0x8020
+#define GEN6_TD_0_6_EHTRG_MSK 0x8024
+#define GEN6_TD_0_7_EHTRG_MSK 0x8028
+#define GEN6_TD_RDATA 0x802c
+#define GEN6_TD_TS_EMSK 0x8030
+#define GEN6_EU_CTL 0x8800
+# define GEN6_EU_CTL_SELECT_SHIFT 16
+# define GEN6_EU_CTL_DATA_MUX_SHIFT 8
-#define GEN6_3DSTATE_CONSTANT_VS GEN6_3D(3, 0, 0x15)
-#define GEN6_3DSTATE_CONSTANT_GS GEN6_3D(3, 0, 0x16)
-#define GEN6_3DSTATE_CONSTANT_PS GEN6_3D(3, 0, 0x17)
+#define GEN6_EU_ATT_0 0x8810
+#define GEN6_EU_ATT_1 0x8814
+#define GEN6_EU_ATT_DATA_0 0x8820
+#define GEN6_EU_ATT_DATA_1 0x8824
+#define GEN6_EU_ATT_CLR_0 0x8830
+#define GEN6_EU_ATT_CLR_1 0x8834
+#define GEN6_EU_RDATA 0x8840
-#define GEN6_3DSTATE_SAMPLE_MASK GEN6_3D(3, 0, 0x18)
-
-#define GEN6_3DSTATE_MULTISAMPLE GEN6_3D(3, 1, 0x0d)
-/* DW1 */
-# define GEN6_3DSTATE_MULTISAMPLE_PIXEL_LOCATION_CENTER (0 << 4)
-# define GEN6_3DSTATE_MULTISAMPLE_PIXEL_LOCATION_UPPER_LEFT (1 << 4)
-# define GEN6_3DSTATE_MULTISAMPLE_NUMSAMPLES_1 (0 << 1)
-# define GEN6_3DSTATE_MULTISAMPLE_NUMSAMPLES_4 (2 << 1)
-# define GEN6_3DSTATE_MULTISAMPLE_NUMSAMPLES_8 (3 << 1)
-
-#define PIPELINE_SELECT_3D 0
-#define PIPELINE_SELECT_MEDIA 1
-
-#define UF0_CS_REALLOC (1 << 13)
-#define UF0_VFE_REALLOC (1 << 12)
-#define UF0_SF_REALLOC (1 << 11)
-#define UF0_CLIP_REALLOC (1 << 10)
-#define UF0_GS_REALLOC (1 << 9)
-#define UF0_VS_REALLOC (1 << 8)
-#define UF1_CLIP_FENCE_SHIFT 20
-#define UF1_GS_FENCE_SHIFT 10
-#define UF1_VS_FENCE_SHIFT 0
-#define UF2_CS_FENCE_SHIFT 20
-#define UF2_VFE_FENCE_SHIFT 10
-#define UF2_SF_FENCE_SHIFT 0
-
-/* for GEN6_STATE_BASE_ADDRESS */
-#define BASE_ADDRESS_MODIFY (1 << 0)
-#define BUFFER_SIZE_MODIFY (1 << 0)
+#define UF0_CS_REALLOC (1 << 13)
+#define UF0_VFE_REALLOC (1 << 12)
+#define UF0_SF_REALLOC (1 << 11)
+#define UF0_CLIP_REALLOC (1 << 10)
+#define UF0_GS_REALLOC (1 << 9)
+#define UF0_VS_REALLOC (1 << 8)
+#define UF1_CLIP_FENCE_SHIFT 20
+#define UF1_GS_FENCE_SHIFT 10
+#define UF1_VS_FENCE_SHIFT 0
+#define UF2_CS_FENCE_SHIFT 20
+#define UF2_VFE_FENCE_SHIFT 10
+#define UF2_SF_FENCE_SHIFT 0
/* for GEN6_3DSTATE_PIPELINED_POINTERS */
-#define GEN6_GS_DISABLE 0
-#define GEN6_GS_ENABLE 1
-#define GEN6_CLIP_DISABLE 0
-#define GEN6_CLIP_ENABLE 1
+#define GEN6_GS_DISABLE 0
+#define GEN6_GS_ENABLE 1
+#define GEN6_CLIP_DISABLE 0
+#define GEN6_CLIP_ENABLE 1
-/* for GEN6_PIPE_CONTROL */
-#define GEN6_PIPE_CONTROL_NOWRITE (0 << 14)
-#define GEN6_PIPE_CONTROL_WRITE_QWORD (1 << 14)
-#define GEN6_PIPE_CONTROL_WRITE_DEPTH (2 << 14)
-#define GEN6_PIPE_CONTROL_WRITE_TIME (3 << 14)
-#define GEN6_PIPE_CONTROL_DEPTH_STALL (1 << 13)
-#define GEN6_PIPE_CONTROL_WC_FLUSH (1 << 12)
-#define GEN6_PIPE_CONTROL_IS_FLUSH (1 << 11)
-#define GEN6_PIPE_CONTROL_TC_FLUSH (1 << 10)
-#define GEN6_PIPE_CONTROL_NOTIFY_ENABLE (1 << 8)
-#define GEN6_PIPE_CONTROL_GLOBAL_GTT (1 << 2)
-#define GEN6_PIPE_CONTROL_LOCAL_PGTT (0 << 2)
-#define GEN6_PIPE_CONTROL_DEPTH_CACHE_FLUSH (1 << 0)
+/* 3D state */
+#define _3DOP_3DSTATE_PIPELINED 0x0
+#define _3DOP_3DSTATE_NONPIPELINED 0x1
+#define _3DOP_3DCONTROL 0x2
+#define _3DOP_3DPRIMITIVE 0x3
-/* 3DPRIMITIVE bits */
-#define GEN6_3DPRIMITIVE_VERTEX_SEQUENTIAL (0 << 15)
-#define GEN6_3DPRIMITIVE_VERTEX_RANDOM (1 << 15)
-/* Primitive types are in gen6_defines.h */
-#define GEN6_3DPRIMITIVE_TOPOLOGY_SHIFT 10
+#define _3DSTATE_PIPELINED_POINTERS 0x00
+#define _3DSTATE_BINDING_TABLE_POINTERS 0x01
+#define _3DSTATE_VERTEX_BUFFERS 0x08
+#define _3DSTATE_VERTEX_ELEMENTS 0x09
+#define _3DSTATE_INDEX_BUFFER 0x0A
+#define _3DSTATE_VF_STATISTICS 0x0B
+#define _3DSTATE_DRAWING_RECTANGLE 0x00
+#define _3DSTATE_CONSTANT_COLOR 0x01
+#define _3DSTATE_SAMPLER_PALETTE_LOAD 0x02
+#define _3DSTATE_CHROMA_KEY 0x04
+#define _3DSTATE_DEPTH_BUFFER 0x05
+#define _3DSTATE_POLY_STIPPLE_OFFSET 0x06
+#define _3DSTATE_POLY_STIPPLE_PATTERN 0x07
+#define _3DSTATE_LINE_STIPPLE 0x08
+#define _3DSTATE_GLOBAL_DEPTH_OFFSET_CLAMP 0x09
+#define _3DCONTROL 0x00
+#define _3DPRIMITIVE 0x00
-#define GEN6_SVG_CTL 0x7400
+#define _3DPRIM_POINTLIST 0x01
+#define _3DPRIM_LINELIST 0x02
+#define _3DPRIM_LINESTRIP 0x03
+#define _3DPRIM_TRILIST 0x04
+#define _3DPRIM_TRISTRIP 0x05
+#define _3DPRIM_TRIFAN 0x06
+#define _3DPRIM_QUADLIST 0x07
+#define _3DPRIM_QUADSTRIP 0x08
+#define _3DPRIM_LINELIST_ADJ 0x09
+#define _3DPRIM_LINESTRIP_ADJ 0x0A
+#define _3DPRIM_TRILIST_ADJ 0x0B
+#define _3DPRIM_TRISTRIP_ADJ 0x0C
+#define _3DPRIM_TRISTRIP_REVERSE 0x0D
+#define _3DPRIM_POLYGON 0x0E
+#define _3DPRIM_RECTLIST 0x0F
+#define _3DPRIM_LINELOOP 0x10
+#define _3DPRIM_POINTLIST_BF 0x11
+#define _3DPRIM_LINESTRIP_CONT 0x12
+#define _3DPRIM_LINESTRIP_BF 0x13
+#define _3DPRIM_LINESTRIP_CONT_BF 0x14
+#define _3DPRIM_TRIFAN_NOSTIPPLE 0x15
-#define GEN6_SVG_CTL_GS_BA (0 << 8)
-#define GEN6_SVG_CTL_SS_BA (1 << 8)
-#define GEN6_SVG_CTL_IO_BA (2 << 8)
-#define GEN6_SVG_CTL_GS_AUB (3 << 8)
-#define GEN6_SVG_CTL_IO_AUB (4 << 8)
-#define GEN6_SVG_CTL_SIP (5 << 8)
+#define _3DPRIM_VERTEXBUFFER_ACCESS_SEQUENTIAL 0
+#define _3DPRIM_VERTEXBUFFER_ACCESS_RANDOM 1
-#define GEN6_SVG_RDATA 0x7404
-#define GEN6_SVG_WORK_CTL 0x7408
+#define GEN6_ANISORATIO_2 0
+#define GEN6_ANISORATIO_4 1
+#define GEN6_ANISORATIO_6 2
+#define GEN6_ANISORATIO_8 3
+#define GEN6_ANISORATIO_10 4
+#define GEN6_ANISORATIO_12 5
+#define GEN6_ANISORATIO_14 6
+#define GEN6_ANISORATIO_16 7
-#define GEN6_VF_CTL 0x7500
+#define GEN6_BLENDFACTOR_ONE 0x1
+#define GEN6_BLENDFACTOR_SRC_COLOR 0x2
+#define GEN6_BLENDFACTOR_SRC_ALPHA 0x3
+#define GEN6_BLENDFACTOR_DST_ALPHA 0x4
+#define GEN6_BLENDFACTOR_DST_COLOR 0x5
+#define GEN6_BLENDFACTOR_SRC_ALPHA_SATURATE 0x6
+#define GEN6_BLENDFACTOR_CONST_COLOR 0x7
+#define GEN6_BLENDFACTOR_CONST_ALPHA 0x8
+#define GEN6_BLENDFACTOR_SRC1_COLOR 0x9
+#define GEN6_BLENDFACTOR_SRC1_ALPHA 0x0A
+#define GEN6_BLENDFACTOR_ZERO 0x11
+#define GEN6_BLENDFACTOR_INV_SRC_COLOR 0x12
+#define GEN6_BLENDFACTOR_INV_SRC_ALPHA 0x13
+#define GEN6_BLENDFACTOR_INV_DST_ALPHA 0x14
+#define GEN6_BLENDFACTOR_INV_DST_COLOR 0x15
+#define GEN6_BLENDFACTOR_INV_CONST_COLOR 0x17
+#define GEN6_BLENDFACTOR_INV_CONST_ALPHA 0x18
+#define GEN6_BLENDFACTOR_INV_SRC1_COLOR 0x19
+#define GEN6_BLENDFACTOR_INV_SRC1_ALPHA 0x1A
-#define GEN6_VF_CTL_SNAPSHOT_COMPLETE (1 << 31)
-#define GEN6_VF_CTL_SNAPSHOT_MUX_SELECT_THREADID (0 << 8)
-#define GEN6_VF_CTL_SNAPSHOT_MUX_SELECT_VF_DEBUG (1 << 8)
-#define GEN6_VF_CTL_SNAPSHOT_TYPE_VERTEX_SEQUENCE (0 << 4)
-#define GEN6_VF_CTL_SNAPSHOT_TYPE_VERTEX_INDEX (1 << 4)
-#define GEN6_VF_CTL_SKIP_INITIAL_PRIMITIVES (1 << 3)
-#define GEN6_VF_CTL_MAX_PRIMITIVES_LIMIT_ENABLE (1 << 2)
-#define GEN6_VF_CTL_VERTEX_RANGE_LIMIT_ENABLE (1 << 1)
-#define GEN6_VF_CTL_SNAPSHOT_ENABLE (1 << 0)
+#define GEN6_BLENDFUNCTION_ADD 0
+#define GEN6_BLENDFUNCTION_SUBTRACT 1
+#define GEN6_BLENDFUNCTION_REVERSE_SUBTRACT 2
+#define GEN6_BLENDFUNCTION_MIN 3
+#define GEN6_BLENDFUNCTION_MAX 4
-#define GEN6_VF_STRG_VAL 0x7504
-#define GEN6_VF_STR_VL_OVR 0x7508
-#define GEN6_VF_VC_OVR 0x750c
-#define GEN6_VF_STR_PSKIP 0x7510
-#define GEN6_VF_MAX_PRIM 0x7514
-#define GEN6_VF_RDATA 0x7518
+#define GEN6_ALPHATEST_FORMAT_UNORM8 0
+#define GEN6_ALPHATEST_FORMAT_FLOAT32 1
-#define GEN6_VS_CTL 0x7600
-#define GEN6_VS_CTL_SNAPSHOT_COMPLETE (1 << 31)
-#define GEN6_VS_CTL_SNAPSHOT_MUX_VERTEX_0 (0 << 8)
-#define GEN6_VS_CTL_SNAPSHOT_MUX_VERTEX_1 (1 << 8)
-#define GEN6_VS_CTL_SNAPSHOT_MUX_VALID_COUNT (2 << 8)
-#define GEN6_VS_CTL_SNAPSHOT_MUX_VS_KERNEL_POINTER (3 << 8)
-#define GEN6_VS_CTL_SNAPSHOT_ALL_THREADS (1 << 2)
-#define GEN6_VS_CTL_THREAD_SNAPSHOT_ENABLE (1 << 1)
-#define GEN6_VS_CTL_SNAPSHOT_ENABLE (1 << 0)
+#define GEN6_CHROMAKEY_KILL_ON_ANY_MATCH 0
+#define GEN6_CHROMAKEY_REPLACE_BLACK 1
-#define GEN6_VS_STRG_VAL 0x7604
-#define GEN6_VS_RDATA 0x7608
+#define GEN6_CLIP_API_OGL 0
+#define GEN6_CLIP_API_DX 1
-#define GEN6_SF_CTL 0x7b00
-#define GEN6_SF_CTL_SNAPSHOT_COMPLETE (1 << 31)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_0_FF_ID (0 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_0_REL_COUNT (1 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_1_FF_ID (2 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_1_REL_COUNT (3 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_2_FF_ID (4 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_2_REL_COUNT (5 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_VERTEX_COUNT (6 << 8)
-#define GEN6_SF_CTL_SNAPSHOT_MUX_SF_KERNEL_POINTER (7 << 8)
-#define GEN6_SF_CTL_MIN_MAX_PRIMITIVE_RANGE_ENABLE (1 << 4)
-#define GEN6_SF_CTL_DEBUG_CLIP_RECTANGLE_ENABLE (1 << 3)
-#define GEN6_SF_CTL_SNAPSHOT_ALL_THREADS (1 << 2)
-#define GEN6_SF_CTL_THREAD_SNAPSHOT_ENABLE (1 << 1)
-#define GEN6_SF_CTL_SNAPSHOT_ENABLE (1 << 0)
+#define GEN6_CLIPMODE_NORMAL 0
+#define GEN6_CLIPMODE_CLIP_ALL 1
+#define GEN6_CLIPMODE_CLIP_NON_REJECTED 2
+#define GEN6_CLIPMODE_REJECT_ALL 3
+#define GEN6_CLIPMODE_ACCEPT_ALL 4
-#define GEN6_SF_STRG_VAL 0x7b04
-#define GEN6_SF_RDATA 0x7b18
+#define GEN6_CLIP_NDCSPACE 0
+#define GEN6_CLIP_SCREENSPACE 1
-#define GEN6_WIZ_CTL 0x7c00
-#define GEN6_WIZ_CTL_SNAPSHOT_COMPLETE (1 << 31)
-#define GEN6_WIZ_CTL_SUBSPAN_INSTANCE_SHIFT 16
-#define GEN6_WIZ_CTL_SNAPSHOT_MUX_WIZ_KERNEL_POINTER (0 << 8)
-#define GEN6_WIZ_CTL_SNAPSHOT_MUX_SUBSPAN_INSTANCE (1 << 8)
-#define GEN6_WIZ_CTL_SNAPSHOT_MUX_PRIMITIVE_SEQUENCE (2 << 8)
-#define GEN6_WIZ_CTL_SINGLE_SUBSPAN_DISPATCH (1 << 6)
-#define GEN6_WIZ_CTL_IGNORE_COLOR_SCOREBOARD_STALLS (1 << 5)
-#define GEN6_WIZ_CTL_ENABLE_SUBSPAN_INSTANCE_COMPARE (1 << 4)
-#define GEN6_WIZ_CTL_USE_UPSTREAM_SNAPSHOT_FLAG (1 << 3)
-#define GEN6_WIZ_CTL_SNAPSHOT_ALL_THREADS (1 << 2)
-#define GEN6_WIZ_CTL_THREAD_SNAPSHOT_ENABLE (1 << 1)
-#define GEN6_WIZ_CTL_SNAPSHOT_ENABLE (1 << 0)
+#define GEN6_COMPAREFUNCTION_ALWAYS 0
+#define GEN6_COMPAREFUNCTION_NEVER 1
+#define GEN6_COMPAREFUNCTION_LESS 2
+#define GEN6_COMPAREFUNCTION_EQUAL 3
+#define GEN6_COMPAREFUNCTION_LEQUAL 4
+#define GEN6_COMPAREFUNCTION_GREATER 5
+#define GEN6_COMPAREFUNCTION_NOTEQUAL 6
+#define GEN6_COMPAREFUNCTION_GEQUAL 7
-#define GEN6_WIZ_STRG_VAL 0x7c04
-#define GEN6_WIZ_RDATA 0x7c18
+#define GEN6_COVERAGE_PIXELS_HALF 0
+#define GEN6_COVERAGE_PIXELS_1 1
+#define GEN6_COVERAGE_PIXELS_2 2
+#define GEN6_COVERAGE_PIXELS_4 3
-#define GEN6_TS_CTL 0x7e00
-#define GEN6_TS_CTL_SNAPSHOT_COMPLETE (1 << 31)
-#define GEN6_TS_CTL_SNAPSHOT_MESSAGE_ERROR (0 << 8)
-#define GEN6_TS_CTL_SNAPSHOT_INTERFACE_DESCRIPTOR (3 << 8)
-#define GEN6_TS_CTL_SNAPSHOT_ALL_CHILD_THREADS (1 << 2)
-#define GEN6_TS_CTL_SNAPSHOT_ALL_ROOT_THREADS (1 << 1)
-#define GEN6_TS_CTL_SNAPSHOT_ENABLE (1 << 0)
+#define GEN6_CULLMODE_BOTH 0
+#define GEN6_CULLMODE_NONE 1
+#define GEN6_CULLMODE_FRONT 2
+#define GEN6_CULLMODE_BACK 3
-#define GEN6_TS_STRG_VAL 0x7e04
-#define GEN6_TS_RDATA 0x7e08
+#define GEN6_DEFAULTCOLOR_R8G8B8A8_UNORM 0
+#define GEN6_DEFAULTCOLOR_R32G32B32A32_FLOAT 1
-#define GEN6_TD_CTL_MUX_SHIFT 8
-#define GEN6_TD_CTL_EXTERNAL_HALT_R0_DEBUG_MATCH (1 << 7)
-#define GEN6_TD_CTL_FORCE_EXTERNAL_HALT (1 << 6)
-#define GEN6_TD_CTL_EXCEPTION_MASK_OVERRIDE (1 << 5)
-#define GEN6_TD_CTL_FORCE_THREAD_BREAKPOINT_ENABLE (1 << 4)
-#define GEN6_TD_CTL_BREAKPOINT_ENABLE (1 << 2)
-#define GEN6_TD_CTL2 0x8004
-#define GEN6_TD_CTL2_ILLEGAL_OPCODE_EXCEPTION_OVERRIDE (1 << 28)
-#define GEN6_TD_CTL2_MASKSTACK_EXCEPTION_OVERRIDE (1 << 26)
-#define GEN6_TD_CTL2_SOFTWARE_EXCEPTION_OVERRIDE (1 << 25)
-#define GEN6_TD_CTL2_ACTIVE_THREAD_LIMIT_SHIFT 16
-#define GEN6_TD_CTL2_ACTIVE_THREAD_LIMIT_ENABLE (1 << 8)
-#define GEN6_TD_CTL2_THREAD_SPAWNER_EXECUTION_MASK_ENABLE (1 << 7)
-#define GEN6_TD_CTL2_WIZ_EXECUTION_MASK_ENABLE (1 << 6)
-#define GEN6_TD_CTL2_SF_EXECUTION_MASK_ENABLE (1 << 5)
-#define GEN6_TD_CTL2_CLIPPER_EXECUTION_MASK_ENABLE (1 << 4)
-#define GEN6_TD_CTL2_GS_EXECUTION_MASK_ENABLE (1 << 3)
-#define GEN6_TD_CTL2_VS_EXECUTION_MASK_ENABLE (1 << 0)
-#define GEN6_TD_VF_VS_EMSK 0x8008
-#define GEN6_TD_GS_EMSK 0x800c
-#define GEN6_TD_CLIP_EMSK 0x8010
-#define GEN6_TD_SF_EMSK 0x8014
-#define GEN6_TD_WIZ_EMSK 0x8018
-#define GEN6_TD_0_6_EHTRG_VAL 0x801c
-#define GEN6_TD_0_7_EHTRG_VAL 0x8020
-#define GEN6_TD_0_6_EHTRG_MSK 0x8024
-#define GEN6_TD_0_7_EHTRG_MSK 0x8028
-#define GEN6_TD_RDATA 0x802c
-#define GEN6_TD_TS_EMSK 0x8030
+#define GEN6_DEPTHFORMAT_D32_FLOAT_S8X24_UINT 0
+#define GEN6_DEPTHFORMAT_D32_FLOAT 1
+#define GEN6_DEPTHFORMAT_D24_UNORM_S8_UINT 2
+#define GEN6_DEPTHFORMAT_D16_UNORM 5
-#define GEN6_EU_CTL 0x8800
-#define GEN6_EU_CTL_SELECT_SHIFT 16
-#define GEN6_EU_CTL_DATA_MUX_SHIFT 8
-#define GEN6_EU_ATT_0 0x8810
-#define GEN6_EU_ATT_1 0x8814
-#define GEN6_EU_ATT_DATA_0 0x8820
-#define GEN6_EU_ATT_DATA_1 0x8824
-#define GEN6_EU_ATT_CLR_0 0x8830
-#define GEN6_EU_ATT_CLR_1 0x8834
-#define GEN6_EU_RDATA 0x8840
+#define GEN6_FLOATING_POINT_IEEE_754 0
+#define GEN6_FLOATING_POINT_NON_IEEE_754 1
-/* 3D state:
- */
-#define _3DOP_3DSTATE_PIPELINED 0x0
-#define _3DOP_3DSTATE_NONPIPELINED 0x1
-#define _3DOP_3DCONTROL 0x2
-#define _3DOP_3DPRIMITIVE 0x3
+#define GEN6_FRONTWINDING_CW 0
+#define GEN6_FRONTWINDING_CCW 1
-#define _3DSTATE_PIPELINED_POINTERS 0x00
-#define _3DSTATE_BINDING_TABLE_POINTERS 0x01
-#define _3DSTATE_VERTEX_BUFFERS 0x08
-#define _3DSTATE_VERTEX_ELEMENTS 0x09
-#define _3DSTATE_INDEX_BUFFER 0x0A
-#define _3DSTATE_VF_STATISTICS 0x0B
-#define _3DSTATE_DRAWING_RECTANGLE 0x00
-#define _3DSTATE_CONSTANT_COLOR 0x01
-#define _3DSTATE_SAMPLER_PALETTE_LOAD 0x02
-#define _3DSTATE_CHROMA_KEY 0x04
-#define _3DSTATE_DEPTH_BUFFER 0x05
-#define _3DSTATE_POLY_STIPPLE_OFFSET 0x06
-#define _3DSTATE_POLY_STIPPLE_PATTERN 0x07
-#define _3DSTATE_LINE_STIPPLE 0x08
-#define _3DSTATE_GLOBAL_DEPTH_OFFSET_CLAMP 0x09
-#define _3DCONTROL 0x00
-#define _3DPRIMITIVE 0x00
+#define GEN6_INDEX_BYTE 0
+#define GEN6_INDEX_WORD 1
+#define GEN6_INDEX_DWORD 2
-#define _3DPRIM_POINTLIST 0x01
-#define _3DPRIM_LINELIST 0x02
-#define _3DPRIM_LINESTRIP 0x03
-#define _3DPRIM_TRILIST 0x04
-#define _3DPRIM_TRISTRIP 0x05
-#define _3DPRIM_TRIFAN 0x06
-#define _3DPRIM_QUADLIST 0x07
-#define _3DPRIM_QUADSTRIP 0x08
-#define _3DPRIM_LINELIST_ADJ 0x09
-#define _3DPRIM_LINESTRIP_ADJ 0x0A
-#define _3DPRIM_TRILIST_ADJ 0x0B
-#define _3DPRIM_TRISTRIP_ADJ 0x0C
-#define _3DPRIM_TRISTRIP_REVERSE 0x0D
-#define _3DPRIM_POLYGON 0x0E
-#define _3DPRIM_RECTLIST 0x0F
-#define _3DPRIM_LINELOOP 0x10
-#define _3DPRIM_POINTLIST_BF 0x11
-#define _3DPRIM_LINESTRIP_CONT 0x12
-#define _3DPRIM_LINESTRIP_BF 0x13
-#define _3DPRIM_LINESTRIP_CONT_BF 0x14
-#define _3DPRIM_TRIFAN_NOSTIPPLE 0x15
+#define GEN6_LOGICOPFUNCTION_CLEAR 0
+#define GEN6_LOGICOPFUNCTION_NOR 1
+#define GEN6_LOGICOPFUNCTION_AND_INVERTED 2
+#define GEN6_LOGICOPFUNCTION_COPY_INVERTED 3
+#define GEN6_LOGICOPFUNCTION_AND_REVERSE 4
+#define GEN6_LOGICOPFUNCTION_INVERT 5
+#define GEN6_LOGICOPFUNCTION_XOR 6
+#define GEN6_LOGICOPFUNCTION_NAND 7
+#define GEN6_LOGICOPFUNCTION_AND 8
+#define GEN6_LOGICOPFUNCTION_EQUIV 9
+#define GEN6_LOGICOPFUNCTION_NOOP 10
+#define GEN6_LOGICOPFUNCTION_OR_INVERTED 11
+#define GEN6_LOGICOPFUNCTION_COPY 12
+#define GEN6_LOGICOPFUNCTION_OR_REVERSE 13
+#define GEN6_LOGICOPFUNCTION_OR 14
+#define GEN6_LOGICOPFUNCTION_SET 15
-#define _3DPRIM_VERTEXBUFFER_ACCESS_SEQUENTIAL 0
-#define _3DPRIM_VERTEXBUFFER_ACCESS_RANDOM 1
+#define GEN6_MAPFILTER_NEAREST 0x0
+#define GEN6_MAPFILTER_LINEAR 0x1
+#define GEN6_MAPFILTER_ANISOTROPIC 0x2
-#define GEN6_ANISORATIO_2 0
-#define GEN6_ANISORATIO_4 1
-#define GEN6_ANISORATIO_6 2
-#define GEN6_ANISORATIO_8 3
-#define GEN6_ANISORATIO_10 4
-#define GEN6_ANISORATIO_12 5
-#define GEN6_ANISORATIO_14 6
-#define GEN6_ANISORATIO_16 7
+#define GEN6_MIPFILTER_NONE 0
+#define GEN6_MIPFILTER_NEAREST 1
+#define GEN6_MIPFILTER_LINEAR 3
-#define GEN6_BLENDFACTOR_ONE 0x1
-#define GEN6_BLENDFACTOR_SRC_COLOR 0x2
-#define GEN6_BLENDFACTOR_SRC_ALPHA 0x3
-#define GEN6_BLENDFACTOR_DST_ALPHA 0x4
-#define GEN6_BLENDFACTOR_DST_COLOR 0x5
-#define GEN6_BLENDFACTOR_SRC_ALPHA_SATURATE 0x6
-#define GEN6_BLENDFACTOR_CONST_COLOR 0x7
-#define GEN6_BLENDFACTOR_CONST_ALPHA 0x8
-#define GEN6_BLENDFACTOR_SRC1_COLOR 0x9
-#define GEN6_BLENDFACTOR_SRC1_ALPHA 0x0A
-#define GEN6_BLENDFACTOR_ZERO 0x11
-#define GEN6_BLENDFACTOR_INV_SRC_COLOR 0x12
-#define GEN6_BLENDFACTOR_INV_SRC_ALPHA 0x13
-#define GEN6_BLENDFACTOR_INV_DST_ALPHA 0x14
-#define GEN6_BLENDFACTOR_INV_DST_COLOR 0x15
-#define GEN6_BLENDFACTOR_INV_CONST_COLOR 0x17
-#define GEN6_BLENDFACTOR_INV_CONST_ALPHA 0x18
-#define GEN6_BLENDFACTOR_INV_SRC1_COLOR 0x19
-#define GEN6_BLENDFACTOR_INV_SRC1_ALPHA 0x1A
+#define GEN6_POLYGON_FRONT_FACING 0
+#define GEN6_POLYGON_BACK_FACING 1
-#define GEN6_BLENDFUNCTION_ADD 0
-#define GEN6_BLENDFUNCTION_SUBTRACT 1
-#define GEN6_BLENDFUNCTION_REVERSE_SUBTRACT 2
-#define GEN6_BLENDFUNCTION_MIN 3
-#define GEN6_BLENDFUNCTION_MAX 4
+#define GEN6_PREFILTER_ALWAYS 0x0
+#define GEN6_PREFILTER_NEVER 0x1
+#define GEN6_PREFILTER_LESS 0x2
+#define GEN6_PREFILTER_EQUAL 0x3
+#define GEN6_PREFILTER_LEQUAL 0x4
+#define GEN6_PREFILTER_GREATER 0x5
+#define GEN6_PREFILTER_NOTEQUAL 0x6
+#define GEN6_PREFILTER_GEQUAL 0x7
-#define GEN6_ALPHATEST_FORMAT_UNORM8 0
-#define GEN6_ALPHATEST_FORMAT_FLOAT32 1
+#define GEN6_PROVOKING_VERTEX_0 0
+#define GEN6_PROVOKING_VERTEX_1 1
+#define GEN6_PROVOKING_VERTEX_2 2
-#define GEN6_CHROMAKEY_KILL_ON_ANY_MATCH 0
-#define GEN6_CHROMAKEY_REPLACE_BLACK 1
+#define GEN6_RASTRULE_UPPER_LEFT 0
+#define GEN6_RASTRULE_UPPER_RIGHT 1
-#define GEN6_CLIP_API_OGL 0
-#define GEN6_CLIP_API_DX 1
+#define GEN6_RENDERTARGET_CLAMPRANGE_UNORM 0
+#define GEN6_RENDERTARGET_CLAMPRANGE_SNORM 1
+#define GEN6_RENDERTARGET_CLAMPRANGE_FORMAT 2
-#define GEN6_CLIPMODE_NORMAL 0
-#define GEN6_CLIPMODE_CLIP_ALL 1
-#define GEN6_CLIPMODE_CLIP_NON_REJECTED 2
-#define GEN6_CLIPMODE_REJECT_ALL 3
-#define GEN6_CLIPMODE_ACCEPT_ALL 4
+#define GEN6_STENCILOP_KEEP 0
+#define GEN6_STENCILOP_ZERO 1
+#define GEN6_STENCILOP_REPLACE 2
+#define GEN6_STENCILOP_INCRSAT 3
+#define GEN6_STENCILOP_DECRSAT 4
+#define GEN6_STENCILOP_INCR 5
+#define GEN6_STENCILOP_DECR 6
+#define GEN6_STENCILOP_INVERT 7
-#define GEN6_CLIP_NDCSPACE 0
-#define GEN6_CLIP_SCREENSPACE 1
-
-#define GEN6_COMPAREFUNCTION_ALWAYS 0
-#define GEN6_COMPAREFUNCTION_NEVER 1
-#define GEN6_COMPAREFUNCTION_LESS 2
-#define GEN6_COMPAREFUNCTION_EQUAL 3
-#define GEN6_COMPAREFUNCTION_LEQUAL 4
-#define GEN6_COMPAREFUNCTION_GREATER 5
-#define GEN6_COMPAREFUNCTION_NOTEQUAL 6
-#define GEN6_COMPAREFUNCTION_GEQUAL 7
-
-#define GEN6_COVERAGE_PIXELS_HALF 0
-#define GEN6_COVERAGE_PIXELS_1 1
-#define GEN6_COVERAGE_PIXELS_2 2
-#define GEN6_COVERAGE_PIXELS_4 3
-
-#define GEN6_CULLMODE_BOTH 0
-#define GEN6_CULLMODE_NONE 1
-#define GEN6_CULLMODE_FRONT 2
-#define GEN6_CULLMODE_BACK 3
-
-#define GEN6_DEFAULTCOLOR_R8G8B8A8_UNORM 0
-#define GEN6_DEFAULTCOLOR_R32G32B32A32_FLOAT 1
-
-#define GEN6_DEPTHFORMAT_D32_FLOAT_S8X24_UINT 0
-#define GEN6_DEPTHFORMAT_D32_FLOAT 1
-#define GEN6_DEPTHFORMAT_D24_UNORM_S8_UINT 2
-#define GEN6_DEPTHFORMAT_D16_UNORM 5
-
-#define GEN6_FLOATING_POINT_IEEE_754 0
-#define GEN6_FLOATING_POINT_NON_IEEE_754 1
-
-#define GEN6_FRONTWINDING_CW 0
-#define GEN6_FRONTWINDING_CCW 1
-
-#define GEN6_INDEX_BYTE 0
-#define GEN6_INDEX_WORD 1
-#define GEN6_INDEX_DWORD 2
-
-#define GEN6_LOGICOPFUNCTION_CLEAR 0
-#define GEN6_LOGICOPFUNCTION_NOR 1
-#define GEN6_LOGICOPFUNCTION_AND_INVERTED 2
-#define GEN6_LOGICOPFUNCTION_COPY_INVERTED 3
-#define GEN6_LOGICOPFUNCTION_AND_REVERSE 4
-#define GEN6_LOGICOPFUNCTION_INVERT 5
-#define GEN6_LOGICOPFUNCTION_XOR 6
-#define GEN6_LOGICOPFUNCTION_NAND 7
-#define GEN6_LOGICOPFUNCTION_AND 8
-#define GEN6_LOGICOPFUNCTION_EQUIV 9
-#define GEN6_LOGICOPFUNCTION_NOOP 10
-#define GEN6_LOGICOPFUNCTION_OR_INVERTED 11
-#define GEN6_LOGICOPFUNCTION_COPY 12
-#define GEN6_LOGICOPFUNCTION_OR_REVERSE 13
-#define GEN6_LOGICOPFUNCTION_OR 14
-#define GEN6_LOGICOPFUNCTION_SET 15
-
-#define GEN6_MAPFILTER_NEAREST 0x0
-#define GEN6_MAPFILTER_LINEAR 0x1
-#define GEN6_MAPFILTER_ANISOTROPIC 0x2
-
-#define GEN6_MIPFILTER_NONE 0
-#define GEN6_MIPFILTER_NEAREST 1
-#define GEN6_MIPFILTER_LINEAR 3
-
-#define GEN6_POLYGON_FRONT_FACING 0
-#define GEN6_POLYGON_BACK_FACING 1
-
-#define GEN6_PREFILTER_ALWAYS 0x0
-#define GEN6_PREFILTER_NEVER 0x1
-#define GEN6_PREFILTER_LESS 0x2
-#define GEN6_PREFILTER_EQUAL 0x3
-#define GEN6_PREFILTER_LEQUAL 0x4
-#define GEN6_PREFILTER_GREATER 0x5
-#define GEN6_PREFILTER_NOTEQUAL 0x6
-#define GEN6_PREFILTER_GEQUAL 0x7
-
-#define GEN6_PROVOKING_VERTEX_0 0
-#define GEN6_PROVOKING_VERTEX_1 1
-#define GEN6_PROVOKING_VERTEX_2 2
-
-#define GEN6_RASTRULE_UPPER_LEFT 0
-#define GEN6_RASTRULE_UPPER_RIGHT 1
-
-#define GEN6_RENDERTARGET_CLAMPRANGE_UNORM 0
-#define GEN6_RENDERTARGET_CLAMPRANGE_SNORM 1
-#define GEN6_RENDERTARGET_CLAMPRANGE_FORMAT 2
-
-#define GEN6_STENCILOP_KEEP 0
-#define GEN6_STENCILOP_ZERO 1
-#define GEN6_STENCILOP_REPLACE 2
-#define GEN6_STENCILOP_INCRSAT 3
-#define GEN6_STENCILOP_DECRSAT 4
-#define GEN6_STENCILOP_INCR 5
-#define GEN6_STENCILOP_DECR 6
-#define GEN6_STENCILOP_INVERT 7
-
-#define GEN6_SURFACE_MIPMAPLAYOUT_BELOW 0
-#define GEN6_SURFACE_MIPMAPLAYOUT_RIGHT 1
+#define GEN6_SURFACE_MIPMAPLAYOUT_BELOW 0
+#define GEN6_SURFACE_MIPMAPLAYOUT_RIGHT 1
#define GEN6_SURFACEFORMAT_R32G32B32A32_FLOAT 0x000
#define GEN6_SURFACEFORMAT_R32G32B32A32_SINT 0x001
@@ -926,258 +664,256 @@
#define GEN6_SURFACEFORMAT_R16G16B16_SSCALED 0x19E
#define GEN6_SURFACEFORMAT_R16G16B16_USCALED 0x19F
-#define GEN6_SURFACERETURNFORMAT_FLOAT32 0
-#define GEN6_SURFACERETURNFORMAT_S1 1
+#define GEN6_SURFACERETURNFORMAT_FLOAT32 0
+#define GEN6_SURFACERETURNFORMAT_S1 1
-#define GEN6_SURFACE_1D 0
-#define GEN6_SURFACE_2D 1
-#define GEN6_SURFACE_3D 2
-#define GEN6_SURFACE_CUBE 3
-#define GEN6_SURFACE_BUFFER 4
-#define GEN6_SURFACE_NULL 7
+#define GEN6_SURFACE_1D 0
+#define GEN6_SURFACE_2D 1
+#define GEN6_SURFACE_3D 2
+#define GEN6_SURFACE_CUBE 3
+#define GEN6_SURFACE_BUFFER 4
+#define GEN6_SURFACE_NULL 7
-#define GEN6_BORDER_COLOR_MODE_DEFAULT 0
-#define GEN6_BORDER_COLOR_MODE_LEGACY 1
+#define GEN6_BORDER_COLOR_MODE_DEFAULT 0
+#define GEN6_BORDER_COLOR_MODE_LEGACY 1
-#define GEN6_TEXCOORDMODE_WRAP 0
-#define GEN6_TEXCOORDMODE_MIRROR 1
-#define GEN6_TEXCOORDMODE_CLAMP 2
-#define GEN6_TEXCOORDMODE_CUBE 3
-#define GEN6_TEXCOORDMODE_CLAMP_BORDER 4
-#define GEN6_TEXCOORDMODE_MIRROR_ONCE 5
+#define GEN6_TEXCOORDMODE_WRAP 0
+#define GEN6_TEXCOORDMODE_MIRROR 1
+#define GEN6_TEXCOORDMODE_CLAMP 2
+#define GEN6_TEXCOORDMODE_CUBE 3
+#define GEN6_TEXCOORDMODE_CLAMP_BORDER 4
+#define GEN6_TEXCOORDMODE_MIRROR_ONCE 5
-#define GEN6_THREAD_PRIORITY_NORMAL 0
-#define GEN6_THREAD_PRIORITY_HIGH 1
+#define GEN6_THREAD_PRIORITY_NORMAL 0
+#define GEN6_THREAD_PRIORITY_HIGH 1
-#define GEN6_TILEWALK_XMAJOR 0
-#define GEN6_TILEWALK_YMAJOR 1
+#define GEN6_TILEWALK_XMAJOR 0
+#define GEN6_TILEWALK_YMAJOR 1
-#define GEN6_VERTEX_SUBPIXEL_PRECISION_8BITS 0
-#define GEN6_VERTEX_SUBPIXEL_PRECISION_4BITS 1
+#define GEN6_VERTEX_SUBPIXEL_PRECISION_8BITS 0
+#define GEN6_VERTEX_SUBPIXEL_PRECISION_4BITS 1
#define GEN6_VERTEXBUFFER_ACCESS_VERTEXDATA 0
#define GEN6_VERTEXBUFFER_ACCESS_INSTANCEDATA 1
-#define GEN6_VFCOMPONENT_NOSTORE 0
-#define GEN6_VFCOMPONENT_STORE_SRC 1
-#define GEN6_VFCOMPONENT_STORE_0 2
-#define GEN6_VFCOMPONENT_STORE_1_FLT 3
-#define GEN6_VFCOMPONENT_STORE_1_INT 4
-#define GEN6_VFCOMPONENT_STORE_VID 5
-#define GEN6_VFCOMPONENT_STORE_IID 6
-#define GEN6_VFCOMPONENT_STORE_PID 7
-
-
+#define GEN6_VFCOMPONENT_NOSTORE 0
+#define GEN6_VFCOMPONENT_STORE_SRC 1
+#define GEN6_VFCOMPONENT_STORE_0 2
+#define GEN6_VFCOMPONENT_STORE_1_FLT 3
+#define GEN6_VFCOMPONENT_STORE_1_INT 4
+#define GEN6_VFCOMPONENT_STORE_VID 5
+#define GEN6_VFCOMPONENT_STORE_IID 6
+#define GEN6_VFCOMPONENT_STORE_PID 7
/* Execution Unit (EU) defines
*/
-#define GEN6_ALIGN_1 0
-#define GEN6_ALIGN_16 1
+#define GEN6_ALIGN_1 0
+#define GEN6_ALIGN_16 1
-#define GEN6_ADDRESS_DIRECT 0
-#define GEN6_ADDRESS_REGISTER_INDIRECT_REGISTER 1
+#define GEN6_ADDRESS_DIRECT 0
+#define GEN6_ADDRESS_REGISTER_INDIRECT_REGISTER 1
-#define GEN6_CHANNEL_X 0
-#define GEN6_CHANNEL_Y 1
-#define GEN6_CHANNEL_Z 2
-#define GEN6_CHANNEL_W 3
+#define GEN6_CHANNEL_X 0
+#define GEN6_CHANNEL_Y 1
+#define GEN6_CHANNEL_Z 2
+#define GEN6_CHANNEL_W 3
-#define GEN6_COMPRESSION_NONE 0
-#define GEN6_COMPRESSION_2NDHALF 1
-#define GEN6_COMPRESSION_COMPRESSED 2
+#define GEN6_COMPRESSION_NONE 0
+#define GEN6_COMPRESSION_2NDHALF 1
+#define GEN6_COMPRESSION_COMPRESSED 2
-#define GEN6_CONDITIONAL_NONE 0
-#define GEN6_CONDITIONAL_Z 1
-#define GEN6_CONDITIONAL_NZ 2
-#define GEN6_CONDITIONAL_EQ 1 /* Z */
-#define GEN6_CONDITIONAL_NEQ 2 /* NZ */
-#define GEN6_CONDITIONAL_G 3
-#define GEN6_CONDITIONAL_GE 4
-#define GEN6_CONDITIONAL_L 5
-#define GEN6_CONDITIONAL_LE 6
-#define GEN6_CONDITIONAL_C 7
-#define GEN6_CONDITIONAL_O 8
+#define GEN6_CONDITIONAL_NONE 0
+#define GEN6_CONDITIONAL_Z 1
+#define GEN6_CONDITIONAL_NZ 2
+#define GEN6_CONDITIONAL_EQ 1 /* Z */
+#define GEN6_CONDITIONAL_NEQ 2 /* NZ */
+#define GEN6_CONDITIONAL_G 3
+#define GEN6_CONDITIONAL_GE 4
+#define GEN6_CONDITIONAL_L 5
+#define GEN6_CONDITIONAL_LE 6
+#define GEN6_CONDITIONAL_C 7
+#define GEN6_CONDITIONAL_O 8
-#define GEN6_DEBUG_NONE 0
-#define GEN6_DEBUG_BREAKPOINT 1
+#define GEN6_DEBUG_NONE 0
+#define GEN6_DEBUG_BREAKPOINT 1
-#define GEN6_DEPENDENCY_NORMAL 0
-#define GEN6_DEPENDENCY_NOTCLEARED 1
-#define GEN6_DEPENDENCY_NOTCHECKED 2
-#define GEN6_DEPENDENCY_DISABLE 3
+#define GEN6_DEPENDENCY_NORMAL 0
+#define GEN6_DEPENDENCY_NOTCLEARED 1
+#define GEN6_DEPENDENCY_NOTCHECKED 2
+#define GEN6_DEPENDENCY_DISABLE 3
-#define GEN6_EXECUTE_1 0
-#define GEN6_EXECUTE_2 1
-#define GEN6_EXECUTE_4 2
-#define GEN6_EXECUTE_8 3
-#define GEN6_EXECUTE_16 4
-#define GEN6_EXECUTE_32 5
+#define GEN6_EXECUTE_1 0
+#define GEN6_EXECUTE_2 1
+#define GEN6_EXECUTE_4 2
+#define GEN6_EXECUTE_8 3
+#define GEN6_EXECUTE_16 4
+#define GEN6_EXECUTE_32 5
-#define GEN6_HORIZONTAL_STRIDE_0 0
-#define GEN6_HORIZONTAL_STRIDE_1 1
-#define GEN6_HORIZONTAL_STRIDE_2 2
-#define GEN6_HORIZONTAL_STRIDE_4 3
+#define GEN6_HORIZONTAL_STRIDE_0 0
+#define GEN6_HORIZONTAL_STRIDE_1 1
+#define GEN6_HORIZONTAL_STRIDE_2 2
+#define GEN6_HORIZONTAL_STRIDE_4 3
-#define GEN6_INSTRUCTION_NORMAL 0
-#define GEN6_INSTRUCTION_SATURATE 1
+#define GEN6_INSTRUCTION_NORMAL 0
+#define GEN6_INSTRUCTION_SATURATE 1
-#define GEN6_MASK_ENABLE 0
-#define GEN6_MASK_DISABLE 1
+#define GEN6_MASK_ENABLE 0
+#define GEN6_MASK_DISABLE 1
-#define GEN6_OPCODE_MOV 1
-#define GEN6_OPCODE_SEL 2
-#define GEN6_OPCODE_NOT 4
-#define GEN6_OPCODE_AND 5
-#define GEN6_OPCODE_OR 6
-#define GEN6_OPCODE_XOR 7
-#define GEN6_OPCODE_SHR 8
-#define GEN6_OPCODE_SHL 9
-#define GEN6_OPCODE_RSR 10
-#define GEN6_OPCODE_RSL 11
-#define GEN6_OPCODE_ASR 12
-#define GEN6_OPCODE_CMP 16
-#define GEN6_OPCODE_JMPI 32
-#define GEN6_OPCODE_IF 34
-#define GEN6_OPCODE_IFF 35
-#define GEN6_OPCODE_ELSE 36
-#define GEN6_OPCODE_ENDIF 37
-#define GEN6_OPCODE_DO 38
-#define GEN6_OPCODE_WHILE 39
-#define GEN6_OPCODE_BREAK 40
-#define GEN6_OPCODE_CONTINUE 41
-#define GEN6_OPCODE_HALT 42
-#define GEN6_OPCODE_MSAVE 44
-#define GEN6_OPCODE_MRESTORE 45
-#define GEN6_OPCODE_PUSH 46
-#define GEN6_OPCODE_POP 47
-#define GEN6_OPCODE_WAIT 48
-#define GEN6_OPCODE_SEND 49
-#define GEN6_OPCODE_ADD 64
-#define GEN6_OPCODE_MUL 65
-#define GEN6_OPCODE_AVG 66
-#define GEN6_OPCODE_FRC 67
-#define GEN6_OPCODE_RNDU 68
-#define GEN6_OPCODE_RNDD 69
-#define GEN6_OPCODE_RNDE 70
-#define GEN6_OPCODE_RNDZ 71
-#define GEN6_OPCODE_MAC 72
-#define GEN6_OPCODE_MACH 73
-#define GEN6_OPCODE_LZD 74
-#define GEN6_OPCODE_SAD2 80
-#define GEN6_OPCODE_SADA2 81
-#define GEN6_OPCODE_DP4 84
-#define GEN6_OPCODE_DPH 85
-#define GEN6_OPCODE_DP3 86
-#define GEN6_OPCODE_DP2 87
-#define GEN6_OPCODE_DPA2 88
-#define GEN6_OPCODE_LINE 89
-#define GEN6_OPCODE_NOP 126
+#define GEN6_OPCODE_MOV 1
+#define GEN6_OPCODE_SEL 2
+#define GEN6_OPCODE_NOT 4
+#define GEN6_OPCODE_AND 5
+#define GEN6_OPCODE_OR 6
+#define GEN6_OPCODE_XOR 7
+#define GEN6_OPCODE_SHR 8
+#define GEN6_OPCODE_SHL 9
+#define GEN6_OPCODE_RSR 10
+#define GEN6_OPCODE_RSL 11
+#define GEN6_OPCODE_ASR 12
+#define GEN6_OPCODE_CMP 16
+#define GEN6_OPCODE_JMPI 32
+#define GEN6_OPCODE_IF 34
+#define GEN6_OPCODE_IFF 35
+#define GEN6_OPCODE_ELSE 36
+#define GEN6_OPCODE_ENDIF 37
+#define GEN6_OPCODE_DO 38
+#define GEN6_OPCODE_WHILE 39
+#define GEN6_OPCODE_BREAK 40
+#define GEN6_OPCODE_CONTINUE 41
+#define GEN6_OPCODE_HALT 42
+#define GEN6_OPCODE_MSAVE 44
+#define GEN6_OPCODE_MRESTORE 45
+#define GEN6_OPCODE_PUSH 46
+#define GEN6_OPCODE_POP 47
+#define GEN6_OPCODE_WAIT 48
+#define GEN6_OPCODE_SEND 49
+#define GEN6_OPCODE_ADD 64
+#define GEN6_OPCODE_MUL 65
+#define GEN6_OPCODE_AVG 66
+#define GEN6_OPCODE_FRC 67
+#define GEN6_OPCODE_RNDU 68
+#define GEN6_OPCODE_RNDD 69
+#define GEN6_OPCODE_RNDE 70
+#define GEN6_OPCODE_RNDZ 71
+#define GEN6_OPCODE_MAC 72
+#define GEN6_OPCODE_MACH 73
+#define GEN6_OPCODE_LZD 74
+#define GEN6_OPCODE_SAD2 80
+#define GEN6_OPCODE_SADA2 81
+#define GEN6_OPCODE_DP4 84
+#define GEN6_OPCODE_DPH 85
+#define GEN6_OPCODE_DP3 86
+#define GEN6_OPCODE_DP2 87
+#define GEN6_OPCODE_DPA2 88
+#define GEN6_OPCODE_LINE 89
+#define GEN6_OPCODE_NOP 126
-#define GEN6_PREDICATE_NONE 0
-#define GEN6_PREDICATE_NORMAL 1
-#define GEN6_PREDICATE_ALIGN1_ANYV 2
-#define GEN6_PREDICATE_ALIGN1_ALLV 3
-#define GEN6_PREDICATE_ALIGN1_ANY2H 4
-#define GEN6_PREDICATE_ALIGN1_ALL2H 5
-#define GEN6_PREDICATE_ALIGN1_ANY4H 6
-#define GEN6_PREDICATE_ALIGN1_ALL4H 7
-#define GEN6_PREDICATE_ALIGN1_ANY8H 8
-#define GEN6_PREDICATE_ALIGN1_ALL8H 9
-#define GEN6_PREDICATE_ALIGN1_ANY16H 10
-#define GEN6_PREDICATE_ALIGN1_ALL16H 11
-#define GEN6_PREDICATE_ALIGN16_REPLICATE_X 2
-#define GEN6_PREDICATE_ALIGN16_REPLICATE_Y 3
-#define GEN6_PREDICATE_ALIGN16_REPLICATE_Z 4
-#define GEN6_PREDICATE_ALIGN16_REPLICATE_W 5
-#define GEN6_PREDICATE_ALIGN16_ANY4H 6
-#define GEN6_PREDICATE_ALIGN16_ALL4H 7
+#define GEN6_PREDICATE_NONE 0
+#define GEN6_PREDICATE_NORMAL 1
+#define GEN6_PREDICATE_ALIGN1_ANYV 2
+#define GEN6_PREDICATE_ALIGN1_ALLV 3
+#define GEN6_PREDICATE_ALIGN1_ANY2H 4
+#define GEN6_PREDICATE_ALIGN1_ALL2H 5
+#define GEN6_PREDICATE_ALIGN1_ANY4H 6
+#define GEN6_PREDICATE_ALIGN1_ALL4H 7
+#define GEN6_PREDICATE_ALIGN1_ANY8H 8
+#define GEN6_PREDICATE_ALIGN1_ALL8H 9
+#define GEN6_PREDICATE_ALIGN1_ANY16H 10
+#define GEN6_PREDICATE_ALIGN1_ALL16H 11
+#define GEN6_PREDICATE_ALIGN16_REPLICATE_X 2
+#define GEN6_PREDICATE_ALIGN16_REPLICATE_Y 3
+#define GEN6_PREDICATE_ALIGN16_REPLICATE_Z 4
+#define GEN6_PREDICATE_ALIGN16_REPLICATE_W 5
+#define GEN6_PREDICATE_ALIGN16_ANY4H 6
+#define GEN6_PREDICATE_ALIGN16_ALL4H 7
-#define GEN6_ARCHITECTURE_REGISTER_FILE 0
-#define GEN6_GENERAL_REGISTER_FILE 1
-#define GEN6_MESSAGE_REGISTER_FILE 2
-#define GEN6_IMMEDIATE_VALUE 3
+#define GEN6_ARCHITECTURE_REGISTER_FILE 0
+#define GEN6_GENERAL_REGISTER_FILE 1
+#define GEN6_MESSAGE_REGISTER_FILE 2
+#define GEN6_IMMEDIATE_VALUE 3
-#define GEN6_REGISTER_TYPE_UD 0
-#define GEN6_REGISTER_TYPE_D 1
-#define GEN6_REGISTER_TYPE_UW 2
-#define GEN6_REGISTER_TYPE_W 3
-#define GEN6_REGISTER_TYPE_UB 4
-#define GEN6_REGISTER_TYPE_B 5
-#define GEN6_REGISTER_TYPE_VF 5 /* packed float vector, immediates only? */
-#define GEN6_REGISTER_TYPE_HF 6
-#define GEN6_REGISTER_TYPE_V 6 /* packed int vector, immediates only, uword dest only */
-#define GEN6_REGISTER_TYPE_F 7
+#define GEN6_REGISTER_TYPE_UD 0
+#define GEN6_REGISTER_TYPE_D 1
+#define GEN6_REGISTER_TYPE_UW 2
+#define GEN6_REGISTER_TYPE_W 3
+#define GEN6_REGISTER_TYPE_UB 4
+#define GEN6_REGISTER_TYPE_B 5
+/* packed float vector, immediates only? */
+#define GEN6_REGISTER_TYPE_VF 5
+#define GEN6_REGISTER_TYPE_HF 6
+/* packed int vector, immediates only, uword dest only */
+#define GEN6_REGISTER_TYPE_V 6
+#define GEN6_REGISTER_TYPE_F 7
-#define GEN6_ARF_NULL 0x00
-#define GEN6_ARF_ADDRESS 0x10
-#define GEN6_ARF_ACCUMULATOR 0x20
-#define GEN6_ARF_FLAG 0x30
-#define GEN6_ARF_MASK 0x40
-#define GEN6_ARF_MASK_STACK 0x50
-#define GEN6_ARF_MASK_STACK_DEPTH 0x60
-#define GEN6_ARF_STATE 0x70
-#define GEN6_ARF_CONTROL 0x80
-#define GEN6_ARF_NOTIFICATION_COUNT 0x90
-#define GEN6_ARF_IP 0xA0
+#define GEN6_ARF_NULL 0x00
+#define GEN6_ARF_ADDRESS 0x10
+#define GEN6_ARF_ACCUMULATOR 0x20
+#define GEN6_ARF_FLAG 0x30
+#define GEN6_ARF_MASK 0x40
+#define GEN6_ARF_MASK_STACK 0x50
+#define GEN6_ARF_MASK_STACK_DEPTH 0x60
+#define GEN6_ARF_STATE 0x70
+#define GEN6_ARF_CONTROL 0x80
+#define GEN6_ARF_NOTIFICATION_COUNT 0x90
+#define GEN6_ARF_IP 0xA0
-#define GEN6_AMASK 0
-#define GEN6_IMASK 1
-#define GEN6_LMASK 2
-#define GEN6_CMASK 3
+#define GEN6_AMASK 0
+#define GEN6_IMASK 1
+#define GEN6_LMASK 2
+#define GEN6_CMASK 3
+#define GEN6_THREAD_NORMAL 0
+#define GEN6_THREAD_ATOMIC 1
+#define GEN6_THREAD_SWITCH 2
+#define GEN6_VERTICAL_STRIDE_0 0
+#define GEN6_VERTICAL_STRIDE_1 1
+#define GEN6_VERTICAL_STRIDE_2 2
+#define GEN6_VERTICAL_STRIDE_4 3
+#define GEN6_VERTICAL_STRIDE_8 4
+#define GEN6_VERTICAL_STRIDE_16 5
+#define GEN6_VERTICAL_STRIDE_32 6
+#define GEN6_VERTICAL_STRIDE_64 7
+#define GEN6_VERTICAL_STRIDE_128 8
+#define GEN6_VERTICAL_STRIDE_256 9
+#define GEN6_VERTICAL_STRIDE_ONE_DIMENSIONAL 0xF
-#define GEN6_THREAD_NORMAL 0
-#define GEN6_THREAD_ATOMIC 1
-#define GEN6_THREAD_SWITCH 2
+#define GEN6_WIDTH_1 0
+#define GEN6_WIDTH_2 1
+#define GEN6_WIDTH_4 2
+#define GEN6_WIDTH_8 3
+#define GEN6_WIDTH_16 4
-#define GEN6_VERTICAL_STRIDE_0 0
-#define GEN6_VERTICAL_STRIDE_1 1
-#define GEN6_VERTICAL_STRIDE_2 2
-#define GEN6_VERTICAL_STRIDE_4 3
-#define GEN6_VERTICAL_STRIDE_8 4
-#define GEN6_VERTICAL_STRIDE_16 5
-#define GEN6_VERTICAL_STRIDE_32 6
-#define GEN6_VERTICAL_STRIDE_64 7
-#define GEN6_VERTICAL_STRIDE_128 8
-#define GEN6_VERTICAL_STRIDE_256 9
-#define GEN6_VERTICAL_STRIDE_ONE_DIMENSIONAL 0xF
+#define GEN6_STATELESS_BUFFER_BOUNDARY_1K 0
+#define GEN6_STATELESS_BUFFER_BOUNDARY_2K 1
+#define GEN6_STATELESS_BUFFER_BOUNDARY_4K 2
+#define GEN6_STATELESS_BUFFER_BOUNDARY_8K 3
+#define GEN6_STATELESS_BUFFER_BOUNDARY_16K 4
+#define GEN6_STATELESS_BUFFER_BOUNDARY_32K 5
+#define GEN6_STATELESS_BUFFER_BOUNDARY_64K 6
+#define GEN6_STATELESS_BUFFER_BOUNDARY_128K 7
+#define GEN6_STATELESS_BUFFER_BOUNDARY_256K 8
+#define GEN6_STATELESS_BUFFER_BOUNDARY_512K 9
+#define GEN6_STATELESS_BUFFER_BOUNDARY_1M 10
+#define GEN6_STATELESS_BUFFER_BOUNDARY_2M 11
-#define GEN6_WIDTH_1 0
-#define GEN6_WIDTH_2 1
-#define GEN6_WIDTH_4 2
-#define GEN6_WIDTH_8 3
-#define GEN6_WIDTH_16 4
+#define GEN6_POLYGON_FACING_FRONT 0
+#define GEN6_POLYGON_FACING_BACK 1
-#define GEN6_STATELESS_BUFFER_BOUNDARY_1K 0
-#define GEN6_STATELESS_BUFFER_BOUNDARY_2K 1
-#define GEN6_STATELESS_BUFFER_BOUNDARY_4K 2
-#define GEN6_STATELESS_BUFFER_BOUNDARY_8K 3
-#define GEN6_STATELESS_BUFFER_BOUNDARY_16K 4
-#define GEN6_STATELESS_BUFFER_BOUNDARY_32K 5
-#define GEN6_STATELESS_BUFFER_BOUNDARY_64K 6
-#define GEN6_STATELESS_BUFFER_BOUNDARY_128K 7
-#define GEN6_STATELESS_BUFFER_BOUNDARY_256K 8
-#define GEN6_STATELESS_BUFFER_BOUNDARY_512K 9
-#define GEN6_STATELESS_BUFFER_BOUNDARY_1M 10
-#define GEN6_STATELESS_BUFFER_BOUNDARY_2M 11
+#define GEN6_MESSAGE_TARGET_NULL 0
+#define GEN6_MESSAGE_TARGET_MATH 1
+#define GEN6_MESSAGE_TARGET_SAMPLER 2
+#define GEN6_MESSAGE_TARGET_GATEWAY 3
+#define GEN6_MESSAGE_TARGET_DATAPORT_READ 4
+#define GEN6_MESSAGE_TARGET_DATAPORT_WRITE 5
+#define GEN6_MESSAGE_TARGET_URB 6
+#define GEN6_MESSAGE_TARGET_THREAD_SPAWNER 7
-#define GEN6_POLYGON_FACING_FRONT 0
-#define GEN6_POLYGON_FACING_BACK 1
-
-#define GEN6_MESSAGE_TARGET_NULL 0
-#define GEN6_MESSAGE_TARGET_MATH 1
-#define GEN6_MESSAGE_TARGET_SAMPLER 2
-#define GEN6_MESSAGE_TARGET_GATEWAY 3
-#define GEN6_MESSAGE_TARGET_DATAPORT_READ 4
-#define GEN6_MESSAGE_TARGET_DATAPORT_WRITE 5
-#define GEN6_MESSAGE_TARGET_URB 6
-#define GEN6_MESSAGE_TARGET_THREAD_SPAWNER 7
-
-#define GEN6_SAMPLER_RETURN_FORMAT_FLOAT32 0
-#define GEN6_SAMPLER_RETURN_FORMAT_UINT32 2
-#define GEN6_SAMPLER_RETURN_FORMAT_SINT32 3
+#define GEN6_SAMPLER_RETURN_FORMAT_FLOAT32 0
+#define GEN6_SAMPLER_RETURN_FORMAT_UINT32 2
+#define GEN6_SAMPLER_RETURN_FORMAT_SINT32 3
#define GEN6_SAMPLER_MESSAGE_SIMD8_SAMPLE 0
#define GEN6_SAMPLER_MESSAGE_SIMD16_SAMPLE 0
@@ -1196,26 +932,26 @@
#define GEN6_SAMPLER_MESSAGE_SIMD8_LD 3
#define GEN6_SAMPLER_MESSAGE_SIMD16_LD 3
-#define GEN6_DATAPORT_OWORD_BLOCK_1_OWORDLOW 0
-#define GEN6_DATAPORT_OWORD_BLOCK_1_OWORDHIGH 1
-#define GEN6_DATAPORT_OWORD_BLOCK_2_OWORDS 2
-#define GEN6_DATAPORT_OWORD_BLOCK_4_OWORDS 3
-#define GEN6_DATAPORT_OWORD_BLOCK_8_OWORDS 4
+#define GEN6_DATAPORT_OWORD_BLOCK_1_OWORDLOW 0
+#define GEN6_DATAPORT_OWORD_BLOCK_1_OWORDHIGH 1
+#define GEN6_DATAPORT_OWORD_BLOCK_2_OWORDS 2
+#define GEN6_DATAPORT_OWORD_BLOCK_4_OWORDS 3
+#define GEN6_DATAPORT_OWORD_BLOCK_8_OWORDS 4
-#define GEN6_DATAPORT_OWORD_DUAL_BLOCK_1OWORD 0
-#define GEN6_DATAPORT_OWORD_DUAL_BLOCK_4OWORDS 2
+#define GEN6_DATAPORT_OWORD_DUAL_BLOCK_1OWORD 0
+#define GEN6_DATAPORT_OWORD_DUAL_BLOCK_4OWORDS 2
-#define GEN6_DATAPORT_DWORD_SCATTERED_BLOCK_8DWORDS 2
-#define GEN6_DATAPORT_DWORD_SCATTERED_BLOCK_16DWORDS 3
+#define GEN6_DATAPORT_DWORD_SCATTERED_BLOCK_8DWORDS 2
+#define GEN6_DATAPORT_DWORD_SCATTERED_BLOCK_16DWORDS 3
-#define GEN6_DATAPORT_READ_MESSAGE_OWORD_BLOCK_READ 0
-#define GEN6_DATAPORT_READ_MESSAGE_OWORD_DUAL_BLOCK_READ 1
-#define GEN6_DATAPORT_READ_MESSAGE_DWORD_BLOCK_READ 2
-#define GEN6_DATAPORT_READ_MESSAGE_DWORD_SCATTERED_READ 3
+#define GEN6_DATAPORT_READ_MESSAGE_OWORD_BLOCK_READ 0
+#define GEN6_DATAPORT_READ_MESSAGE_OWORD_DUAL_BLOCK_READ 1
+#define GEN6_DATAPORT_READ_MESSAGE_DWORD_BLOCK_READ 2
+#define GEN6_DATAPORT_READ_MESSAGE_DWORD_SCATTERED_READ 3
-#define GEN6_DATAPORT_READ_TARGET_DATA_CACHE 0
-#define GEN6_DATAPORT_READ_TARGET_RENDER_CACHE 1
-#define GEN6_DATAPORT_READ_TARGET_SAMPLER_CACHE 2
+#define GEN6_DATAPORT_READ_TARGET_DATA_CACHE 0
+#define GEN6_DATAPORT_READ_TARGET_RENDER_CACHE 1
+#define GEN6_DATAPORT_READ_TARGET_SAMPLER_CACHE 2
#define GEN6_DATAPORT_RENDER_TARGET_WRITE_SIMD16_SINGLE_SOURCE 0
#define GEN6_DATAPORT_RENDER_TARGET_WRITE_SIMD16_SINGLE_SOURCE_REPLICATED 1
@@ -1245,36 +981,36 @@
#define GEN6_MATH_FUNCTION_INT_DIV_QUOTIENT 12
#define GEN6_MATH_FUNCTION_INT_DIV_REMAINDER 13
-#define GEN6_MATH_INTEGER_UNSIGNED 0
-#define GEN6_MATH_INTEGER_SIGNED 1
+#define GEN6_MATH_INTEGER_UNSIGNED 0
+#define GEN6_MATH_INTEGER_SIGNED 1
-#define GEN6_MATH_PRECISION_FULL 0
-#define GEN6_MATH_PRECISION_PARTIAL 1
+#define GEN6_MATH_PRECISION_FULL 0
+#define GEN6_MATH_PRECISION_PARTIAL 1
-#define GEN6_MATH_SATURATE_NONE 0
-#define GEN6_MATH_SATURATE_SATURATE 1
+#define GEN6_MATH_SATURATE_NONE 0
+#define GEN6_MATH_SATURATE_SATURATE 1
-#define GEN6_MATH_DATA_VECTOR 0
-#define GEN6_MATH_DATA_SCALAR 1
+#define GEN6_MATH_DATA_VECTOR 0
+#define GEN6_MATH_DATA_SCALAR 1
-#define GEN6_URB_OPCODE_WRITE 0
+#define GEN6_URB_OPCODE_WRITE 0
-#define GEN6_URB_SWIZZLE_NONE 0
-#define GEN6_URB_SWIZZLE_INTERLEAVE 1
-#define GEN6_URB_SWIZZLE_TRANSPOSE 2
+#define GEN6_URB_SWIZZLE_NONE 0
+#define GEN6_URB_SWIZZLE_INTERLEAVE 1
+#define GEN6_URB_SWIZZLE_TRANSPOSE 2
-#define GEN6_SCRATCH_SPACE_SIZE_1K 0
-#define GEN6_SCRATCH_SPACE_SIZE_2K 1
-#define GEN6_SCRATCH_SPACE_SIZE_4K 2
-#define GEN6_SCRATCH_SPACE_SIZE_8K 3
-#define GEN6_SCRATCH_SPACE_SIZE_16K 4
-#define GEN6_SCRATCH_SPACE_SIZE_32K 5
-#define GEN6_SCRATCH_SPACE_SIZE_64K 6
-#define GEN6_SCRATCH_SPACE_SIZE_128K 7
-#define GEN6_SCRATCH_SPACE_SIZE_256K 8
-#define GEN6_SCRATCH_SPACE_SIZE_512K 9
-#define GEN6_SCRATCH_SPACE_SIZE_1M 10
-#define GEN6_SCRATCH_SPACE_SIZE_2M 11
+#define GEN6_SCRATCH_SPACE_SIZE_1K 0
+#define GEN6_SCRATCH_SPACE_SIZE_2K 1
+#define GEN6_SCRATCH_SPACE_SIZE_4K 2
+#define GEN6_SCRATCH_SPACE_SIZE_8K 3
+#define GEN6_SCRATCH_SPACE_SIZE_16K 4
+#define GEN6_SCRATCH_SPACE_SIZE_32K 5
+#define GEN6_SCRATCH_SPACE_SIZE_64K 6
+#define GEN6_SCRATCH_SPACE_SIZE_128K 7
+#define GEN6_SCRATCH_SPACE_SIZE_256K 8
+#define GEN6_SCRATCH_SPACE_SIZE_512K 9
+#define GEN6_SCRATCH_SPACE_SIZE_1M 10
+#define GEN6_SCRATCH_SPACE_SIZE_2M 11
/* The hardware supports two different modes for border color. The
* default (OpenGL) mode uses floating-point color channels, while the
--
2.9.5
More information about the igt-dev
mailing list