Expand description
The PMU banking model — P2 of the Plasticine lane: the Pattern Memory Unit’s scratchpad as the papers describe it (ISCA’17 §3.2), with an executable meaning.
A PMU is banks SRAM banks of words_per_bank 32-bit words (ISCA’17: 16 banks × 16 KB = 256 KB) behind an
address-calculation datapath of stages FU stages. Banking modes: strided (a configurable granularity
so a stride-s vector access spreads across all banks), FIFO, line buffer, and duplication
(every bank holds a copy, so any gather is conflict-free at the cost of broadcast writes). N-buffering
partitions each bank’s address space into n_buffers disjoint regions so a metapipeline’s producer writes
region t+1 while its consumer reads region t.
The executable meaning: Pmu is banked storage whose reads/writes equal a flat heap’s (the banking is a
bijection), and every vector access costs conflicts cycles = the most lanes that land in one bank. That
cost is the stage’s memory II (metapipeline::Stage::memory_ii). MODELED from the paper; never a
Plasticine simulation.
Structs§
- Affine
Access - One vector access: lane
lreads/writesbase + stride * lforlin0..lanes. - Pmu
- Banked storage with a flat-address interface: the executable meaning of the banking modes.
- PmuSpec
- A PMU’s published shape.
Enums§
- Banking
Mode - How addresses map to banks.
Functions§
- address_
datapath_ stages - FU stages the address datapath needs for an affine address
base + Σ stride_k * idx_koverdimscounters (+1 for the lane offset when vectorized): one multiply-add per dimension, chained. - address_
fits - Gate an address pattern against the PMU’s datapath depth — typed refusal.
- bank_of
- The bank an address lives in under
mode. - conflicts
- Cycles a vector access costs: the most lanes that land in one bank (1 = conflict-free). Under duplication a read is always 1 (every bank has the data; lanes are served from distinct copies).
- memory_
ii - The memory II of a stage: the costliest of its vector accesses per iteration.
- strided_
banking_ for - The strided-banking configuration that makes a stride-
stridevector access conflict-free: granularity = stride (lanellands in bank(base/stride + l) % banks, all distinct whilelanes <= banks).