From 314fb652d8a27a38599eeeec121d45327a405bb0 Mon Sep 17 00:00:00 2001 From: Davit Grigoryan Date: Wed, 29 Apr 2026 00:02:46 +0000 Subject: impl option w/ only 2 SBs; stall so SBs are cleared before div or reconv --- src/abstract_hardware_model.h | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) (limited to 'src/abstract_hardware_model.h') diff --git a/src/abstract_hardware_model.h b/src/abstract_hardware_model.h index 6331d6b..09d59f9 100644 --- a/src/abstract_hardware_model.h +++ b/src/abstract_hardware_model.h @@ -1166,6 +1166,11 @@ struct simd_set_info { // source_inst that owns this set. Used at writeback to release the // matching (reg, mask) entry. Zero/empty when source_inst is NULL. active_mask_t source_mask; + // Mode 2 (slot-pinned scoreboard): which ibuffer half (0 or 1) the + // source_inst issued from in its own warp. Used at writeback to release + // the matching slot's scoreboard. (unsigned)-1 when source_inst is NULL + // (i.e., the set carries primary's own work). + unsigned source_slot_id; // Mixed-space MEM co-issue (v2): per-set shared state. // Populated only when source_inst's space is shared/sstarr; otherwise @@ -1177,7 +1182,8 @@ struct simd_set_info { simd_set_info() : set_id(0), warp_id(0), split_id((unsigned)-1), - num_active_threads(0), valid(false), source_inst(NULL), cycles(0) { + num_active_threads(0), valid(false), source_inst(NULL), + source_slot_id((unsigned)-1), cycles(0) { set_active_mask.reset(); active_mask_in_warp.reset(); source_mask.reset(); @@ -1337,6 +1343,16 @@ class warp_inst_t : public inst_t { // Mode 1: stamp the source_inst's full active_mask onto each valid set // for use at writeback (releaseRegisterMask). void set_source_mask_on_sets(const active_mask_t &mask); + // Mode 2: stamp the source_inst's owning ibuffer half (0 or 1) onto + // each valid set for use at writeback (releaseRegisterSlot). + void set_source_slot_on_sets(unsigned slot_id); + + // Mode 2: which ibuffer half (0 or 1) this inst was issued from. Set + // by the issue path; read by the scoreboard reservation/release + // dispatcher to pick the correct per-slot scoreboard. (unsigned)-1 + // means "not from a slot" (modes 0/1 don't use this). + unsigned get_ibuffer_half_id() const { return m_ibuffer_half_id; } + void set_ibuffer_half_id(unsigned h) { m_ibuffer_half_id = h; } static bool simd_sets_overlap(const std::vector &a, const std::vector &b); @@ -1575,6 +1591,10 @@ class warp_inst_t : public inst_t { int m_dbg_split_id = -1; const void *m_dbg_source_inst = NULL; + // Mode 2 (slot-pinned scoreboard): which ibuffer half (0 or 1) this + // inst was issued from. (unsigned)-1 = unset / N/A in modes 0,1. + unsigned m_ibuffer_half_id = (unsigned)-1; + // Jin: cdp support public: int m_is_cdp; -- cgit v1.3