... + CTAD + NTTP = 🤩
summary
Combines variadic templates, CTAD, and NTTP to build a compile-time declarative model description used to auto-generate JSON and to validate runtime tensor extents for thermodynamic simulations. Implements domain intervals and extent-constraint resolution (matrix-multiply example) in roughly 50 lines for domains, folds and pack expansions for serialization, and a constraint-table algorithm that rejects mismatched sizes; tests pass and code compiles on clang‑18, gcc‑14 and MSVC. Notes: large NTTP arrays can inflate compile time unless passed by reference.
AI-written summary · about
chapters (8)
- 0:00Introduction and agenda
- 1:17Variadic templates and parameter packs
- 8:17Fold expressions in C++17
- 15:40Class Template Argument Deduction
- 22:59Non-type template parameters
- 31:29Real-world thermodynamic simulation
- 40:49Results and limitations
- 43:19Q&A session
related talks
28mC2TACO: Lifting Tensor Code to TACO
28mFunctional Sparse Tensor Compilation
15mVTC: DNN Compilation with Virtual Tensors for Data Movement Elimination
32mCompilation of Dynamic Sparse Tensor Algebra
20mCompiling Structured Tensor Algebra
33mTeIL: a type-safe imperative Tensor Intermediate Language
14mCompressed and Parallelized Structured Tensor Algebra
13mAccelerating Complex-Valued Tensors With Torch.compile
