summaryrefslogtreecommitdiff
path: root/src/gpgpu-sim/shader.h
diff options
context:
space:
mode:
authorDavit Grigoryan <[email protected]>2026-04-30 03:47:44 +0000
committerDavit Grigoryan <[email protected]>2026-04-30 03:47:44 +0000
commit208024b4007eba568d3787e72a345b3137e89ade (patch)
treee1cf2cc0ba1637bdeb9a99ebd5e5d52f3d83aa2e /src/gpgpu-sim/shader.h
parent314fb652d8a27a38599eeeec121d45327a405bb0 (diff)
add hw-realistic co-issue scheduling policies
Diffstat (limited to 'src/gpgpu-sim/shader.h')
-rw-r--r--src/gpgpu-sim/shader.h33
1 files changed, 30 insertions, 3 deletions
diff --git a/src/gpgpu-sim/shader.h b/src/gpgpu-sim/shader.h
index 92d6d33..4734d6a 100644
--- a/src/gpgpu-sim/shader.h
+++ b/src/gpgpu-sim/shader.h
@@ -604,6 +604,32 @@ class scheduler_unit { // this can be copied freely, so can be used in std
unsigned &available_sets,
unsigned &next_free_set);
+ // K-bounded variant of try_utilization_max_coissue: scans only the
+ // first K warps in m_next_cycle_prioritized_warps (K = num_simd_sets).
+ // Hardware-realistic alternative to the all-warps idealization above.
+ void try_utilization_max_coissue_window(warp_inst_t *co_issue_composite,
+ exec_unit_type_t co_issue_fu_type,
+ unsigned co_issue_primary_warp_id,
+ unsigned &available_sets,
+ unsigned &next_free_set);
+
+ // Centered-window K-bounded variant: scans K warps centered on the
+ // primary issuer's index in m_supervised_warps (K/2 before, K/2 after).
+ // Models a HW priority encoder local to the primary's natural warp_id
+ // position rather than tied to scheduler priority.
+ void try_utilization_max_coissue_window_centered(
+ warp_inst_t *co_issue_composite, exec_unit_type_t co_issue_fu_type,
+ unsigned co_issue_primary_warp_id, unsigned &available_sets,
+ unsigned &next_free_set);
+
+ // All-before-primary K-bounded variant: scans (K-1) warps strictly
+ // before primary's index in m_supervised_warps. Asymmetric counterpart
+ // to the centered variant.
+ void try_utilization_max_coissue_window_before(
+ warp_inst_t *co_issue_composite, exec_unit_type_t co_issue_fu_type,
+ unsigned co_issue_primary_warp_id, unsigned &available_sets,
+ unsigned &next_free_set);
+
protected:
shd_warp_t &warp(int i);
@@ -1874,10 +1900,10 @@ class shader_core_config : public core_config {
gpgpu_compaction_mode);
abort();
}
- if (gpgpu_co_issue_priority > 4) {
+ if (gpgpu_co_issue_priority > 7) {
fprintf(stderr,
"GPGPU-Sim: invalid -gpgpu_co_issue_priority %u; must be "
- "in [0,4]\n",
+ "in [0,7]\n",
gpgpu_co_issue_priority);
abort();
}
@@ -2048,7 +2074,8 @@ class shader_core_config : public core_config {
bool gpgpu_enable_compaction;
unsigned gpgpu_compaction_mode; // 0=none, 1=xor-static, 2=full
unsigned gpgpu_opndcoll_read_latency; // extra cycles to collector
- unsigned gpgpu_co_issue_priority; // 0=greedy..4=same-PC
+ unsigned gpgpu_co_issue_priority; // 0=greedy..5=K-bounded
+ unsigned gpgpu_coissue_window_K; // mode-5 window size; 0 = num_simd_sets
bool gpgpu_simd_partitioning_debug; // verbose SIMD_SETS printf gate
bool gpgpu_mem_coissue; // enable MEM/LDST co-issue path
unsigned gpgpu_scoreboard_mode; // 0=legacy, 1=mask-aware, 2=slot-pinned