i965: Hide the register type hardware encodings
authorMatt Turner <mattst88@gmail.com>
Thu, 27 Jul 2017 04:13:03 +0000 (21:13 -0700)
committerMatt Turner <mattst88@gmail.com>
Mon, 21 Aug 2017 21:05:23 +0000 (14:05 -0700)
So we stop mixing them with the logical enum.

Reviewed-by: Scott D Phillips <scott.d.phillips@intel.com>
src/intel/compiler/brw_eu_defines.h
src/intel/compiler/brw_reg_type.c

index 44bde3ff5162d7e712405b732e62e00940643a93..da482b73c589a9219a725de5da8139a7229963d8 100644 (file)
@@ -819,37 +819,6 @@ enum PACKED brw_reg_file {
    BAD_FILE,
 };
 
-enum hw_reg_type {
-   BRW_HW_REG_TYPE_UD  = 0,
-   BRW_HW_REG_TYPE_D   = 1,
-   BRW_HW_REG_TYPE_UW  = 2,
-   BRW_HW_REG_TYPE_W   = 3,
-   BRW_HW_REG_TYPE_F   = 7,
-   GEN8_HW_REG_TYPE_UQ = 8,
-   GEN8_HW_REG_TYPE_Q  = 9,
-
-   BRW_HW_REG_TYPE_UB  = 4,
-   BRW_HW_REG_TYPE_B   = 5,
-   GEN7_HW_REG_TYPE_DF = 6,
-   GEN8_HW_REG_TYPE_HF = 10,
-};
-
-enum hw_imm_type {
-   BRW_HW_IMM_TYPE_UD  = 0,
-   BRW_HW_IMM_TYPE_D   = 1,
-   BRW_HW_IMM_TYPE_UW  = 2,
-   BRW_HW_IMM_TYPE_W   = 3,
-   BRW_HW_IMM_TYPE_F   = 7,
-   GEN8_HW_IMM_TYPE_UQ = 8,
-   GEN8_HW_IMM_TYPE_Q  = 9,
-
-   BRW_HW_IMM_TYPE_UV  = 4, /* Gen6+ packed unsigned immediate vector */
-   BRW_HW_IMM_TYPE_VF  = 5, /* packed float immediate vector */
-   BRW_HW_IMM_TYPE_V   = 6, /* packed int imm. vector; uword dest only */
-   GEN8_HW_IMM_TYPE_DF = 10,
-   GEN8_HW_IMM_TYPE_HF = 11,
-};
-
 /* SNB adds 3-src instructions (MAD and LRP) that only operate on floats, so
  * the types were implied. IVB adds BFE and BFI2 that operate on doublewords
  * and unsigned doublewords, so a new field is also available in the da3src
index e2f4d3558d806b7b2a81626ae51bae19a6e06312..a0f674f0d74569f032aa41571ae5978d1506b615 100644 (file)
 
 #define INVALID (-1)
 
+enum hw_reg_type {
+   BRW_HW_REG_TYPE_UD  = 0,
+   BRW_HW_REG_TYPE_D   = 1,
+   BRW_HW_REG_TYPE_UW  = 2,
+   BRW_HW_REG_TYPE_W   = 3,
+   BRW_HW_REG_TYPE_F   = 7,
+   GEN8_HW_REG_TYPE_UQ = 8,
+   GEN8_HW_REG_TYPE_Q  = 9,
+
+   BRW_HW_REG_TYPE_UB  = 4,
+   BRW_HW_REG_TYPE_B   = 5,
+   GEN7_HW_REG_TYPE_DF = 6,
+   GEN8_HW_REG_TYPE_HF = 10,
+};
+
+enum hw_imm_type {
+   BRW_HW_IMM_TYPE_UD  = 0,
+   BRW_HW_IMM_TYPE_D   = 1,
+   BRW_HW_IMM_TYPE_UW  = 2,
+   BRW_HW_IMM_TYPE_W   = 3,
+   BRW_HW_IMM_TYPE_F   = 7,
+   GEN8_HW_IMM_TYPE_UQ = 8,
+   GEN8_HW_IMM_TYPE_Q  = 9,
+
+   BRW_HW_IMM_TYPE_UV  = 4,
+   BRW_HW_IMM_TYPE_VF  = 5,
+   BRW_HW_IMM_TYPE_V   = 6,
+   GEN8_HW_IMM_TYPE_DF = 10,
+   GEN8_HW_IMM_TYPE_HF = 11,
+};
+
 static const struct {
    enum hw_reg_type reg_type;
    enum hw_imm_type imm_type;