[Mesa-dev] [PATCH 09/30] r600: add support for some ALU sources.

Dave Airlie airlied at gmail.com
Thu Mar 31 07:03:38 UTC 2016


From: Dave Airlie <airlied at redhat.com>

These special ALU sources provide the shader engine,
simd and hw wave ids.

These are required for images support.

Signed-off-by: Dave Airlie <airlied at redhat.com>
---
 src/gallium/drivers/r600/r600_asm.c | 9 +++++++++
 src/gallium/drivers/r600/r600_sq.h  | 4 ++++
 2 files changed, 13 insertions(+)

diff --git a/src/gallium/drivers/r600/r600_asm.c b/src/gallium/drivers/r600/r600_asm.c
index e03912c..f2f6c2e 100644
--- a/src/gallium/drivers/r600/r600_asm.c
+++ b/src/gallium/drivers/r600/r600_asm.c
@@ -1964,6 +1964,15 @@ static int print_src(struct r600_bytecode_alu *alu, unsigned idx)
 			o += fprintf(stderr, "LDS_OQ_B_POP");
 			need_chan = 1;
 			break;
+		case EG_V_SQ_ALU_SRC_SE_ID:
+			o += fprintf(stderr, "SE_ID");
+			break;
+		case EG_V_SQ_ALU_SRC_SIMD_ID:
+			o += fprintf(stderr, "SIMD_ID");
+			break;
+		case EG_V_SQ_ALU_SRC_HW_WAVE_ID:
+			o += fprintf(stderr, "HW_WAVE_ID");
+			break;
 		case V_SQ_ALU_SRC_PS:
 			o += fprintf(stderr, "PS");
 			break;
diff --git a/src/gallium/drivers/r600/r600_sq.h b/src/gallium/drivers/r600/r600_sq.h
index 37b6d58..a3815b9 100644
--- a/src/gallium/drivers/r600/r600_sq.h
+++ b/src/gallium/drivers/r600/r600_sq.h
@@ -197,6 +197,10 @@
 #define     EG_V_SQ_ALU_SRC_LDS_DIRECT_A                             0x000000DF
 #define     EG_V_SQ_ALU_SRC_LDS_DIRECT_B                             0x000000E0
 
+#define     EG_V_SQ_ALU_SRC_HW_WAVE_ID                               0x000000E7
+#define     EG_V_SQ_ALU_SRC_SIMD_ID                                  0x000000E8
+#define     EG_V_SQ_ALU_SRC_SE_ID                                    0x000000E9
+
 #define     V_SQ_ALU_SRC_0                                           0x000000F8
 #define     V_SQ_ALU_SRC_1                                           0x000000F9
 #define     V_SQ_ALU_SRC_1_INT                                       0x000000FA
-- 
2.5.0



More information about the mesa-dev mailing list