aboutsummaryrefslogtreecommitdiffstats
path: root/src/panfrost/midgard/midgard_ra.c
diff options
context:
space:
mode:
authorAlyssa Rosenzweig <[email protected]>2019-08-01 10:03:02 -0700
committerAlyssa Rosenzweig <[email protected]>2019-08-12 12:43:01 -0700
commit419ddd63b0ec97dd722b447823f822b949b5baab (patch)
treee94c444c1d9a3deef080678d3202970a02c4720e /src/panfrost/midgard/midgard_ra.c
parenta8639b91b5e90dc8cf40a683a16cd8c4cb51193c (diff)
pan/midgard: Implement SSBO access
Just laying the groundwork. Reads and writes should be supported (both direct and indirect, either int or float, vec1/2/3/4), but no bounds checking is done at the moment. Signed-off-by: Alyssa Rosenzweig <[email protected]>
Diffstat (limited to 'src/panfrost/midgard/midgard_ra.c')
-rw-r--r--src/panfrost/midgard/midgard_ra.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/panfrost/midgard/midgard_ra.c b/src/panfrost/midgard/midgard_ra.c
index 6d8f32e4480..a669168eba4 100644
--- a/src/panfrost/midgard/midgard_ra.c
+++ b/src/panfrost/midgard/midgard_ra.c
@@ -753,8 +753,6 @@ install_registers_instr(
}
case TAG_LOAD_STORE_4: {
- bool fixed = args.src[0] >= SSA_FIXED_MINIMUM;
-
/* Which physical register we read off depends on
* whether we are loading or storing -- think about the
* logical dataflow */
@@ -763,9 +761,7 @@ install_registers_instr(
OP_IS_STORE(ins->load_store.op) &&
ins->load_store.op != midgard_op_st_cubemap_coords;
- if (OP_IS_STORE_R26(ins->load_store.op) && fixed) {
- ins->load_store.reg = SSA_REG_FROM_FIXED(args.src[0]);
- } else if (OP_IS_STORE_VARY(ins->load_store.op)) {
+ if (encodes_src) {
struct phys_reg src = index_to_reg(ctx, g, args.src[0]);
assert(src.reg == 26 || src.reg == 27);
@@ -806,7 +802,7 @@ install_registers_instr(
encodes_src ? args.src[1] : args.src[0];
int src3 =
- encodes_src ? -1 : args.src[1];
+ encodes_src ? args.src[2] : args.src[1];
if (src2 >= 0) {
struct phys_reg src = index_to_reg(ctx, g, src2);