From fbb90ef3a76cd6c469782c84668d25c5f3bfdd22 Mon Sep 17 00:00:00 2001 From: Davit Grigoryan Date: Tue, 28 Apr 2026 22:06:08 +0000 Subject: critical fix - add option to have masks for SB entries --- src/abstract_hardware_model.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/abstract_hardware_model.h') diff --git a/src/abstract_hardware_model.h b/src/abstract_hardware_model.h index 6ce1871..6331d6b 100644 --- a/src/abstract_hardware_model.h +++ b/src/abstract_hardware_model.h @@ -1162,6 +1162,10 @@ struct simd_set_info { unsigned num_active_threads; // popcount of set_active_mask bool valid; // Whether this set has any active threads const inst_t *source_inst; // Pointer to static decoded instruction (for MIMD) + // Mode 1 (mask-aware scoreboard): full issue-time active mask of the + // 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; // Mixed-space MEM co-issue (v2): per-set shared state. // Populated only when source_inst's space is shared/sstarr; otherwise @@ -1176,6 +1180,7 @@ struct simd_set_info { num_active_threads(0), valid(false), source_inst(NULL), cycles(0) { set_active_mask.reset(); active_mask_in_warp.reset(); + source_mask.reset(); for (unsigned i = 0; i < MAX_WARP_SIZE; i++) thread_ids[i] = 0; } @@ -1329,6 +1334,9 @@ class warp_inst_t : public inst_t { void merge_simd_sets(const std::vector &other_sets); void set_source_inst_on_sets(const inst_t *src); void set_split_id_on_sets(unsigned split_id); + // 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); static bool simd_sets_overlap(const std::vector &a, const std::vector &b); -- cgit v1.3