aboutsummaryrefslogtreecommitdiffstats
path: root/src/amd
diff options
context:
space:
mode:
authorRhys Perry <[email protected]>2020-02-11 16:55:39 +0000
committerMarge Bot <[email protected]>2020-03-13 14:04:50 +0000
commit625d8705f02e211e2733c3fe12845505725c37d4 (patch)
tree39f4401e3625fc507d2b09a18763758f185766d4 /src/amd
parent6b4c31f814b8ba61c94506f42f609a2f36ab1fbb (diff)
aco: don't stop scheduling at exports
This allows us to move v_cvt_pkrtz_f16_f32 instructions upwards, improving schedules and (somewhat unintentionally) moving the exports slightly closer together. Totals from affected shaders: SGPRS: 1030224 -> 1030248 (0.00 %) VGPRS: 794080 -> 794392 (0.04 %) Spilled SGPRs: 127117 -> 127117 (0.00 %) Spilled VGPRs: 0 -> 0 (0.00 %) Scratch size: 0 -> 0 (0.00 %) dwords per thread Code Size: 89028152 -> 89032312 (0.00 %) bytes LDS: 0 -> 0 (0.00 %) blocks Max Waves: 65252 -> 65219 (-0.05 %) SMEM score: 843808.00 -> 843918.00 (0.01 %) VMEM score: 5331687.00 -> 5397802.00 (1.24 %) SMEM clauses: 567659 -> 567655 (-0.00 %) VMEM clauses: 290715 -> 290716 (0.00 %) Instructions: 17143219 -> 17144259 (0.01 %) Cycles: 1098442808 -> 1098446968 (0.00 %) Signed-off-by: Rhys Perry <[email protected]> Reviewed-by: Daniel Schürmann <[email protected]> Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3776> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3776>
Diffstat (limited to 'src/amd')
-rw-r--r--src/amd/compiler/aco_scheduler.cpp12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/amd/compiler/aco_scheduler.cpp b/src/amd/compiler/aco_scheduler.cpp
index 84b0fa10cad..146c1809577 100644
--- a/src/amd/compiler/aco_scheduler.cpp
+++ b/src/amd/compiler/aco_scheduler.cpp
@@ -571,7 +571,7 @@ void schedule_SMEM(sched_ctx& ctx, Block* block,
bool can_move_down = true;
HazardResult haz = perform_hazard_query(&hq, candidate.get());
- if (haz == hazard_fail_reorder_ds || haz == hazard_fail_spill || haz == hazard_fail_reorder_sendmsg || haz == hazard_fail_barrier)
+ if (haz == hazard_fail_reorder_ds || haz == hazard_fail_spill || haz == hazard_fail_reorder_sendmsg || haz == hazard_fail_barrier || haz == hazard_fail_export)
can_move_down = false;
else if (haz != hazard_success)
break;
@@ -620,7 +620,8 @@ void schedule_SMEM(sched_ctx& ctx, Block* block,
if (found_dependency) {
HazardResult haz = perform_hazard_query(&hq, candidate.get());
if (haz == hazard_fail_reorder_ds || haz == hazard_fail_spill ||
- haz == hazard_fail_reorder_sendmsg || haz == hazard_fail_barrier)
+ haz == hazard_fail_reorder_sendmsg || haz == hazard_fail_barrier ||
+ haz == hazard_fail_export)
is_dependency = true;
else if (haz != hazard_success)
break;
@@ -711,7 +712,8 @@ void schedule_VMEM(sched_ctx& ctx, Block* block,
HazardResult haz = perform_hazard_query(part_of_clause ? &clause_hq : &indep_hq, candidate.get());
if (haz == hazard_fail_reorder_ds || haz == hazard_fail_spill ||
- haz == hazard_fail_reorder_sendmsg || haz == hazard_fail_barrier)
+ haz == hazard_fail_reorder_sendmsg || haz == hazard_fail_barrier ||
+ haz == hazard_fail_export)
can_move_down = false;
else if (haz != hazard_success)
break;
@@ -757,7 +759,7 @@ void schedule_VMEM(sched_ctx& ctx, Block* block,
HazardResult haz = perform_hazard_query(&indep_hq, candidate.get());
if (haz == hazard_fail_reorder_ds || haz == hazard_fail_spill ||
haz == hazard_fail_reorder_vmem_smem || haz == hazard_fail_reorder_sendmsg ||
- haz == hazard_fail_barrier)
+ haz == hazard_fail_barrier || haz == hazard_fail_export)
is_dependency = true;
else if (haz != hazard_success)
break;
@@ -822,7 +824,7 @@ void schedule_position_export(sched_ctx& ctx, Block* block,
break;
HazardResult haz = perform_hazard_query(&hq, candidate.get());
- if (haz == hazard_fail_exec || haz == hazard_fail_export || haz == hazard_fail_memtime)
+ if (haz == hazard_fail_exec || haz == hazard_fail_memtime)
break;
if (haz != hazard_success) {