Row-Clustered Matrix Format Overview
- Row-clustered matrix format is a representation that groups contiguous rows into clusters to regularize storage and improve access patterns.
- It encompasses various implementations like SELL-C-σ, ARGCSR, and CSR-k, each designed with trade-offs to balance padding overhead with hardware efficiency.
- Adaptive grouping and permutation-based reordering techniques enable efficient sparse matrix–vector and matrix–matrix operations while managing preprocessing costs.
Row-clustered matrix format denotes a family of matrix representations and orderings in which rows are grouped into contiguous clusters, strips, chunks, super-rows, or similarity-defined sets, and the cluster rather than the individual row becomes the primary unit of storage, traversal, scheduling, or interpretation. In sparse linear algebra, this idea appears in formats such as SELL-C-, row-grouped CSR, Adaptive Row-Grouped CSR, CMRS, CSR-, RCMF, and 1D-VBR, all of which exploit row grouping to regularize memory access, improve SIMD/SIMT utilization, reduce index traffic, or increase reuse of secondary operands; in matrix ordering, it appears as a permutation problem that makes similar rows contiguous and condenses matrix mass into block-diagonal, banded, triangular, or nested patterns (Kreutzer et al., 2013, Oberhuber et al., 2010, Morone, 2021, Islam et al., 28 Jul 2025).
1. Definitions and scope
In the sparse-kernel literature, a row-clustered format usually groups adjacent rows into a local storage unit and then stores the cluster in a layout that is more regular than standard CSR. The group may be fixed-height, as in SELL-C- chunks and CMRS strips; block-sized and adaptive, as in row-grouped CSR and ARGCSR; hierarchical, as in CSR- super-rows and super-super-rows; or variable-length and similarity-driven, as in RCMF clusters and 1D-VBR row partitions (Kreutzer et al., 2013, Koza et al., 2012, Heller et al., 2012, Lane et al., 2022, Islam et al., 28 Jul 2025, Ahrens et al., 2020).
In the ordering literature, row clustering refers instead to a permutation of rows, and optionally columns, so that similar rows appear contiguously and the reordered matrix exhibits a prescribed geometric pattern. The square symmetric case uses a similarity transform , while rectangular or asymmetric cases may use independent row and column permutations and (Morone, 2021).
| Format or framework | Cluster unit | Primary purpose |
|---|---|---|
| SELL-C- | chunk of rows | SIMD/SIMT-friendly SpMV |
| RgCSR / ARGCSR | CUDA block-sized row group | coalescing and load balance on GPUs |
| CMRS | strip of height | warp-per-strip SpMV |
| CSR-0 | super-rows and super-super-rows | heterogeneous CSR-compatible SpMV |
| RCMF | row cluster 1 with column slices | reuse of 2 in SpGEMM |
| 1D-VBR | contiguous row partition 3 | block reuse across adjacent rows |
| OPP-based ordering | permutation-defined contiguous row groups | interpretable geometric patterns |
A common misconception is that row clustering denotes a single storage format. The published literature instead uses the term across at least three distinct settings: sparse storage layout, cluster-wise execution order, and permutation-based matrix ordering. This suggests that the unifying concept is not a specific array layout but the decision to treat a small set of rows as a coherent structural object.
2. SELL-C-4 as a canonical SIMD/SIMT row-clustered format
SELL-C-5 is the most explicit formalization of a row-clustered sparse format in the SpMV literature. The matrix is partitioned into 6 chunks of height 7, with chunk 8 containing rows 9. Prior to chunking, rows may be locally sorted within windows of size 0, where 1 means no sorting and 2 yields global sorting. For chunk 3, the stored length is the longest row length in the chunk,
4
Values and column indices are then stored column-major within each chunk, with rows interleaved at stride 5, and shorter rows padded to 6 using padded values 7 and padded column indices 8 (Kreutzer et al., 2013).
The format’s central efficiency metric is chunk occupancy,
9
which measures the fraction of stored entries that are useful nonzeros. The same paper derives the double-precision code balance
0
and a bandwidth-bound performance estimate 1. Here 2 captures effective right-hand-side traffic per nonzero, while 3 isolates padding overhead in the streamed value and index arrays (Kreutzer et al., 2013).
The two tuning parameters serve different roles. 4 is a hardware-facing parameter: 5 for Intel Sandy Bridge AVX double precision, 6 for Intel Xeon Phi to satisfy 64-byte alignment constraints, and 7 for NVIDIA Tesla/Kepler K20 to match the warp size. 8 is a locality-facing parameter: moderate values such as 9–0 often raise 1 substantially while preserving right-hand-side locality, whereas very large 2 can increase 3 by destroying spatial and temporal locality. On the kkt_power matrix on SNB, 4 increased toward 5 as 6 increased, SELL surpassed CRS around 7, and 8 remained stable until 9, after which performance declined (Kreutzer et al., 2013).
SELL-C-0 was proposed as a hardware-independent “catch-all” format. For memory-bound, large-1 matrices such as RM07R and ML_Geer, the model with 2 gave upper bounds of SNB 3 Gflop/s, Xeon Phi 4 Gflop/s, and K20 5 Gflop/s; measured SELL-C-6 performance at tuned 7 reached 8 of bound on K20 and Xeon Phi and 9 on SNB. At the same time, the paper emphasizes the expected degradation on small-0 matrices, where performance drops by 1 or more because the 2 term dominates (Kreutzer et al., 2013).
3. GPU row-grouped and strip-based formats
Earlier GPU-oriented row-clustered formats pursued the same objective through CUDA-centric layouts. Row-grouped CSR (RgCSR) partitions rows into fixed-size groups of size 3, stores each group like a local ELLPACK slab, and interleaves the 4-th element of each row across the group. The padded element count is
5
with waste ratio 6 and storage efficiency 7. Each thread computes one row, and in iteration 8 threads in a warp read consecutive values and column indices, producing coalesced transactions. On GTX 280, the best observed performance at 9 with cached 0 was 1 Gflop/s in single precision and 2 Gflop/s in double precision; RgCSR was faster than HYB on 3 of matrices in single precision and 4 in double precision across 5 matrices, but extreme row-length variability could inflate artificial zeros above 6 for 7 and 8 for 9 (Oberhuber et al., 2010).
Adaptive Row-Grouped CSR (ARGCSR) preserved the group idea but made the internal decomposition adaptive. Rows are assigned to groups associated with CUDA blocks, long rows are split into fixed-size chunks processed by multiple threads, and all threads in the block iterate exactly chunkSize steps. The format stores values, columns, a per-group descriptor argcsrGroupInfo {firstRow, size, offset, chunkSize}, and globalThreadsMapping, which records how many threads are assigned to each row. Extra threads are greedily assigned to the longest rows, shrinking chunkSize and reducing padding. Padding entries use sentinel column index 0, enabling early exit in the kernel (Heller et al., 2012).
The quantitative evaluation of ARGCSR was unusually broad. On 1 matrices on Tesla C2070, ARGCSR was faster than Hybrid on 2 matrices, faster than Row-grouped CSR on 3, and faster than cuSPARSE on 4. It was particularly effective on irregular matrices from circuit/EDA and indefinite problems; rajat23 reached 5 Gflop/s and a speed-up of 6 versus CPU CSR with desiredChunkSize = 1, while Schenk_AFE reached nearly 7 Gflop/s with desiredChunkSize = 32 (Heller et al., 2012).
CMRS took a different but related route by assigning one warp to a strip of 8 contiguous rows. The core arrays are Val, ColInd, StripPtr, and RowInStrip; in the bit-packed variant, RowInStrip is stored in the low bits of ColInd with CMRS_BITS = 4. Nonzeros in the strip are concatenated contiguously, so a warp marches through Val and ColInd in stride 9, accumulates into a shared-memory buffer of size 0, and reduces to 1 row sums. The analytical speedup model relative to CSR-vector is expressed through a bandwidth waste factor 2, showing directly why larger strip heights help when the average row length 3 is small (Koza et al., 2012).
Empirically, CMRS achieved up to 4 speedup over the best of five alternative GPU kernels. On K20M, the reported maxima were 5 in single precision and 6 in double precision, with CMRS dominating especially for moderate 7, while HYB often remained strongest for very small 8 (Koza et al., 2012).
4. Hierarchical and block-aware row clustering
CSR-9 extends standard CSR by keeping vals, col_idx, and row_ptr unchanged and adding 00 pointer arrays that define a hierarchy of contiguous row clusters. In CSR-3, sr_ptr partitions rows into super-rows and ssr_ptr partitions super-rows into super-super-rows. On CPUs, CSR-2 was the preferred configuration; on NVIDIA GPUs, CSR-3 mapped more naturally to the block/grid hierarchy. The format is coupled with a multilevel bandwidth-limiting reordering called Band-01, intended to pull nonzeros closer to the diagonal and align the hierarchy with locality in the 02 vector (Lane et al., 2022).
The format was explicitly targeted at heterogeneous portability for regular sparse matrices, defined by 03, where 04 is the number of nonzeros in row 05. On A100, CSR-3 achieved 06 GFlop/s on regular matrices versus 07 for CSR5 and 08 for cuSPARSE; on V100, CSR-3 achieved 09 GFlop/s versus 10 for CSR5. The same paper also reported that CSR-3 lagged badly on irregular matrices, where cuSPARSE and CSR5 remained superior (Lane et al., 2022).
1D-VBR represents another row-clustered specialization, but in a block-format setting rather than a SIMD strip setting. It groups adjacent rows into a contiguous partition 11, keeps the column partition trivial, and stores each nonzero block as a dense 12 micro-vector. The core arrays are spl_Π, pos, ofs, idx, and val, and the memory footprint is
13
Because the column partition is fixed, the optimal row partition can be computed exactly by a linear-time dynamic program under several cost models, including block count, memory, and an empirical low-rank runtime model (Ahrens et al., 2020).
The empirical results favored 1D-VBR as a speed-oriented row-clustered format. 1D-VBR Min Compute achieved a median speedup of 14 versus CSR, median normalized multiply time of 15 CSR, and median critical point of 16 multiplies. Full VBR Min Memory compressed more aggressively, with median memory around 17 CSR, but 1D-VBR was often faster because it eliminated per-block width variability and reduced control overhead (Ahrens et al., 2020).
5. Cluster-wise multiplication beyond SpMV
Row clustering has also been used to reorganize sparse matrix–matrix multiplication. RCMF, a Row-Clustered Matrix Format for SpGEMM, partitions the rows of 18 into clusters 19, computes the per-cluster column union
20
and stores the matrix cluster-by-cluster and column-by-column inside each cluster. Its data structures include cluster_ptr, col_idx, cluster_size, slice_ptr, val, mask, row_order, and cluster_id. During execution, the algorithm iterates over clusters and then over column slices; when column 21 is encountered, row 22 is fetched once and reused across all rows in 23 that contain 24 (Islam et al., 28 Jul 2025).
The paper separates clustering from reordering and studies fixed-length, variable-length, and hierarchical clustering. Variable-length clustering uses Jaccard similarity,
25
with default parameters 26 and 27. Hierarchical clustering computes 28, keeps TopK matches per row with 29, and merges rows with union-find. On 30 SuiteSparse matrices, hierarchical clustering achieved a 31 geomean speedup, improved 32 of inputs, reached up to 33, and had preprocessing cost less than 34 a single SpGEMM on 35 of inputs (Islam et al., 28 Jul 2025).
A different use of row clustering appears in the exact and approximate multiplication of 36-37 matrices. There, rows of 38 are clustered around 39 centers in Hamming space, producing a centers matrix 40, a row-to-center map, and per-row difference sets
41
If 42 is the minimum maximum radius of an 43-center clustering of the rows, then each entry of 44 can be approximated within additive error at most 45 in 46 time for square matrices; symmetrically, column clustering of 47 yields additive error at most 48 in 49 time. After preprocessing, exact point queries can be answered in 50 or 51 time, and exact multiplication can be performed in 52 time (Jansson et al., 25 Mar 2025).
These two strands use the same structural idea in different ways: RCMF treats a cluster as an execution tile for reuse of sparse rows of 53, while the 54-55 framework treats a cluster as a representative-center approximation space. A plausible implication is that row clustering can be valuable even when the stored format itself remains close to CSR.
6. Permutation-based row clustering and geometric patterns
Outside sparse-kernel storage, row clustering is formalized as an optimal permutation problem. Given an input matrix 56 and a filter matrix 57 encoding a target pattern, the objective is
58
and one seeks 59. In the square symmetric case, the clustered matrix is 60; in rectangular or asymmetric cases, one may use independent row and column permutations 61 and 62 (Morone, 2021).
The framework supports several pattern families by choosing 63: square filters with 64 diagonal blocks and density 65, triangle filters with density 66, band filters defined by analytic 67 and 68, and nestedness filters defined by 69 if 70. The discrete problem is NP-hard as a quadratic assignment problem, so the paper uses a doubly stochastic relaxation over the Birkhoff polytope, a statistical-mechanics formulation with partition function 71, and Sinkhorn-Knopp scaling. The reported algorithm initializes 72, uses 73, 74, 75 starting at 76 and decreasing to 77, and tolerances 78 (Morone, 2021).
The empirical examples are biological. On a 79 neuronal correlation matrix for C. elegans, a two-block square filter separated forward and backward locomotion neurons, while a three-block filter isolated a “Turn” block involving ring interneurons RIVL/RIVR, motor neurons SMDVR/SMDVL and RMEV, labial neurons OLQDR/OLQVL, and polymodal ALA. On the gap-junction adjacency matrix with 80, 81 undirected edges, and 82, the nestedness packing fraction
83
was empirically 84 larger than in a degree-preserving randomized network across 85 (Morone, 2021).
This line of work uses “row-clustered matrix format” in an ordering sense rather than a low-level storage sense. The clustered object is the permutation 86 and the geometric pattern it induces, not necessarily a new values-and-indices layout.
7. Trade-offs, limitations, and recurring design tensions
Across these formats, the main trade-off is between regularity and distortion. SELL-C-87 exposes this most clearly: larger 88 improves SIMD/SIMT alignment, but higher 89 can lower 90; larger 91 can improve 92 by grouping similar row lengths, but can also worsen right-hand-side locality by increasing 93 (Kreutzer et al., 2013). GPU row-grouped formats exhibit the same pattern in more concrete form: RgCSR and fixed-length RCMF can suffer large padding overheads when row patterns in a cluster are dissimilar, while ARGCSR and variable-length RCMF mitigate this by adaptive thread assignment or adaptive cluster formation (Oberhuber et al., 2010, Heller et al., 2012, Islam et al., 28 Jul 2025).
Another recurring tension is preprocessing cost versus amortized speedup. CSR-94 relies on Band-95 reordering and microarchitecture-specific tuning formulas; RCMF hierarchical clustering adds one 96; 1D-VBR and OPP-based ordering solve nontrivial optimization problems before the first kernel invocation. These costs are acceptable when many multiplies follow, but the papers repeatedly note that single-use or rapidly changing sparsity patterns weaken the case for conversion or reordering (Lane et al., 2022, Islam et al., 28 Jul 2025, Ahrens et al., 2020, Morone, 2021).
The formats also have sharply delimited applicability domains. CSR-97 is explicitly strongest for regular matrices with 98 and underperforms cuSPARSE and CSR5 on irregular GPU workloads (Lane et al., 2022). CMRS loses much of its advantage on permutation-like matrices with 99, where 00 on K20M because 01 accesses remain uncoalesced (Koza et al., 2012). ARGCSR can be beaten by cuSPARSE or HYB on some power-system matrices and by earlier row-grouped or sliced-ELLPACK methods on some structured PDE matrices (Heller et al., 2012). 1D-VBR and VBR become unattractive when adjacent rows share few columns, because explicit zeros inside dense blocks increase 02 (Ahrens et al., 2020).
Finally, permutation-based formulations introduce a separate sensitivity: the filter must reflect the true target geometry. The OPP framework states directly that if the filter 03 poorly represents the underlying pattern, or the data are noisy, the overlap term 04 may not align well with the intended structure (Morone, 2021). In that sense, row clustering is not a universal improvement but a controlled regularization strategy whose success depends on how much meaningful structure is already present in the rows.