diff --git a/.pick_status.json b/.pick_status.json index f7671314aae..29160fb8106 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -444,7 +444,7 @@ "description": "ir3/shared_ra: use ir3_cursor instead of instr in reload helpers", "nominated": true, "nomination_type": 2, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "fa22b0901af548d5e1433ad4cdbda314182137c5", "notes": null diff --git a/src/freedreno/ir3/ir3_shared_ra.c b/src/freedreno/ir3/ir3_shared_ra.c index 58b2ba4fc67..ba25b752f8d 100644 --- a/src/freedreno/ir3/ir3_shared_ra.c +++ b/src/freedreno/ir3/ir3_shared_ra.c @@ -826,7 +826,7 @@ reload_interval(struct ra_ctx *ctx, struct ir3_cursor cursor, } static void -reload_src_finalize(struct ra_ctx *ctx, struct ir3_instruction *instr, +reload_src_finalize(struct ra_ctx *ctx, struct ir3_cursor reload_cursor, struct ir3_register *src) { struct ir3_register *reg = src->def; @@ -835,7 +835,7 @@ reload_src_finalize(struct ra_ctx *ctx, struct ir3_instruction *instr, if (!interval->needs_reload) return; - reload_interval(ctx, ir3_before_instr(instr), interval); + reload_interval(ctx, reload_cursor, interval); interval->needs_reload = false; } @@ -1019,14 +1019,14 @@ handle_dst(struct ra_ctx *ctx, struct ir3_instruction *instr, } static void -handle_src_late(struct ra_ctx *ctx, struct ir3_instruction *instr, +handle_src_late(struct ra_ctx *ctx, struct ir3_cursor reload_cursor, struct ir3_register *src) { if (!(src->flags & IR3_REG_SHARED)) return; struct ra_interval *interval = ra_interval_get(ctx, src->def); - reload_src_finalize(ctx, instr, src); + reload_src_finalize(ctx, reload_cursor, src); /* Remove killed sources that have to be killed late due to being merged with * other defs. @@ -1054,7 +1054,7 @@ handle_normal_instr(struct ra_ctx *ctx, struct ir3_instruction *instr) handle_dst(ctx, instr, dst); ra_foreach_src (src, instr) - handle_src_late(ctx, instr, src); + handle_src_late(ctx, ir3_before_instr(instr), src); } static void @@ -1208,7 +1208,7 @@ handle_pcopy(struct ra_ctx *ctx, struct ir3_instruction *pcopy) assign_src(ctx, src); ra_foreach_src (src, pcopy) - handle_src_late(ctx, pcopy, src); + handle_src_late(ctx, ir3_before_instr(pcopy), src); } static void