summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers
diff options
context:
space:
mode:
authorAlyssa Rosenzweig <[email protected]>2019-06-28 09:07:30 -0700
committerAlyssa Rosenzweig <[email protected]>2019-07-01 07:42:55 -0700
commitaa333ac6ad4873bc66b42e12f342381344da5060 (patch)
tree566681105e1f15c0f59434357d1c2a912f4ac0d1 /src/gallium/drivers
parentbbc050b82e7a64848078f993b229a79161c1e95e (diff)
panfrost/midgard: Add unsigned ld/st ops
Signed-off-by: Alyssa Rosenzweig <[email protected]>
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r--src/gallium/drivers/panfrost/midgard/midgard.h4
-rw-r--r--src/gallium/drivers/panfrost/midgard/midgard_compile.c4
-rw-r--r--src/gallium/drivers/panfrost/midgard/midgard_ops.c4
3 files changed, 11 insertions, 1 deletions
diff --git a/src/gallium/drivers/panfrost/midgard/midgard.h b/src/gallium/drivers/panfrost/midgard/midgard.h
index 0a121c3a5b4..d632063e8a4 100644
--- a/src/gallium/drivers/panfrost/midgard/midgard.h
+++ b/src/gallium/drivers/panfrost/midgard/midgard.h
@@ -419,13 +419,16 @@ typedef enum {
midgard_op_ld_attr_32 = 0x94,
midgard_op_ld_attr_16 = 0x95,
+ midgard_op_ld_attr_32u = 0x96,
midgard_op_ld_attr_32i = 0x97,
midgard_op_ld_vary_32 = 0x98,
midgard_op_ld_vary_16 = 0x99,
+ midgard_op_ld_vary_32u = 0x9A,
midgard_op_ld_vary_32i = 0x9B,
midgard_op_ld_color_buffer_16 = 0x9D,
midgard_op_ld_uniform_16 = 0xAC,
+ midgard_op_ld_uniform_32i = 0xA8,
midgard_op_ld_uniform_32 = 0xB0,
midgard_op_ld_color_buffer_8 = 0xBA,
@@ -438,6 +441,7 @@ typedef enum {
midgard_op_st_vary_32 = 0xD4,
midgard_op_st_vary_16 = 0xD5,
+ midgard_op_st_vary_32u = 0xD6,
midgard_op_st_vary_32i = 0xD7,
/* Value to st in r27, location r26.w as short2 */
diff --git a/src/gallium/drivers/panfrost/midgard/midgard_compile.c b/src/gallium/drivers/panfrost/midgard/midgard_compile.c
index edf7eb0b16a..d7155289a71 100644
--- a/src/gallium/drivers/panfrost/midgard/midgard_compile.c
+++ b/src/gallium/drivers/panfrost/midgard/midgard_compile.c
@@ -1294,9 +1294,11 @@ emit_intrinsic(compiler_context *ctx, nir_intrinsic_instr *instr)
/* Use the type appropriate load */
switch (t) {
- case nir_type_int:
case nir_type_uint:
case nir_type_bool:
+ ins.load_store.op = midgard_op_ld_attr_32u;
+ break;
+ case nir_type_int:
ins.load_store.op = midgard_op_ld_attr_32i;
break;
case nir_type_float:
diff --git a/src/gallium/drivers/panfrost/midgard/midgard_ops.c b/src/gallium/drivers/panfrost/midgard/midgard_ops.c
index 3c8535ae09a..089d5cecb1f 100644
--- a/src/gallium/drivers/panfrost/midgard/midgard_ops.c
+++ b/src/gallium/drivers/panfrost/midgard/midgard_ops.c
@@ -190,15 +190,18 @@ const char *load_store_opcode_names[256] = {
[midgard_op_ld_attr_32] = "ld_attr_32",
[midgard_op_ld_attr_16] = "ld_attr_16",
[midgard_op_ld_attr_32i] = "ld_attr_32i",
+ [midgard_op_ld_attr_32u] = "ld_attr_32u",
[midgard_op_ld_vary_32] = "ld_vary_32",
[midgard_op_ld_vary_16] = "ld_vary_16",
[midgard_op_ld_vary_32i] = "ld_vary_32i",
+ [midgard_op_ld_vary_32u] = "ld_vary_32u",
[midgard_op_ld_color_buffer_16] = "ld_color_buffer_16",
[midgard_op_ld_uniform_16] = "ld_uniform_16",
[midgard_op_ld_uniform_32] = "ld_uniform_32",
+ [midgard_op_ld_uniform_32i] = "ld_uniform_32i",
[midgard_op_ld_color_buffer_8] = "ld_color_buffer_8",
[midgard_op_st_char] = "st_char",
@@ -210,6 +213,7 @@ const char *load_store_opcode_names[256] = {
[midgard_op_st_vary_32] = "st_vary_32",
[midgard_op_st_vary_16] = "st_vary_16",
[midgard_op_st_vary_32i] = "st_vary_32i",
+ [midgard_op_st_vary_32u] = "st_vary_32u",
[midgard_op_st_image_f] = "st_image_f",
[midgard_op_st_image_ui] = "st_image_ui",