Skip to main content

kryst/matrix/parcsr/
mod.rs

1//! Legacy AMG-focused distributed CSR (diag/off splitting).
2//!
3//! NOTE: `ParCsrMatrix` is maintained for backward compatibility but is
4//! considered secondary to `matrix::DistCsrOp`. New distributed code should
5//! prefer `DistCsrOp`, and ParCsrMatrix will be gradually reworked to build on
6//! the same halo infrastructure.
7//!
8//! Migration plan (active):
9//! 1. `ParCsrMatrix` matvec now delegates to an internal canonical
10//!    `DistCsrOp` adapter.
11//! 2. Halo exchange and ownership semantics are unified through
12//!    `matrix::dist::halo::HaloPlan` used by `DistCsrOp`.
13//! 3. Solver/PC entry points should consume `LinOp::dist_layout()` /
14//!    `LinOp::comm()` metadata; `ParCsrOp` forwards these from the canonical
15//!    operator.
16//! 4. Legacy diag/off data structures remain only as compatibility adapters and
17//!    are marked deprecated (since 1.1.0) with planned removal after
18//!    2026-12-31 in favor of canonical conversion helpers.
19//! 5. Test parity gates validate that legacy `ParCsrMatrix` SpMV behavior
20//!    matches canonical distributed SpMV before removing legacy routes.
21
22pub type Global = u64;
23pub type Local = usize;
24
25pub mod builder;
26pub mod halo;
27pub mod mat;
28
29pub use halo::HaloPlan;
30pub use mat::{ParCsrMatrix, ParCsrOp};