Build the reverse delta adjacency: for each producer block, the sorted set of consumer blocks that unfold it. This is the natural form for the partition hypergraph, where `net(p) = {p} ∪ consumers_of(p)`.
(&self)
| 185 | } |
| 186 | |
| 187 | impl BlockProfile { |
| 188 | /// Number of blocks (vertices). |
| 189 | pub fn num_blocks(&self) -> usize { |
| 190 | self.blocks.len() |
| 191 | } |
| 192 | |
| 193 | /// Number of delta edges (consumer → producer pairs). |
| 194 | pub fn num_edges(&self) -> usize { |
| 195 | self.delta_col.len() |
| 196 | } |
| 197 | |
| 198 | /// The block entries, indexed by block id. |
| 199 | pub fn blocks(&self) -> &[BlockEntry] { |
| 200 | &self.blocks |
| 201 | } |
| 202 | |
| 203 | /// The entry for block id `i`. |
| 204 | pub fn block(&self, i: u32) -> &BlockEntry { |
| 205 | &self.blocks[i as usize] |
| 206 | } |
| 207 | |
| 208 | /// Producer block ids unfolded by consumer block `c` (sorted, deduped, no |
| 209 | /// self-edges). |
| 210 | pub fn producers(&self, c: u32) -> &[u32] { |