You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Implement Array of Structs of Arrays (AoSoA) tiling and conflict-free memory padding.
Problem & Goal
Naive Array of Structures (AoS) causes expensive gather/scatter vector instructions. Power-of-two matrix strides cause 4K aliasing on CPUs and shared memory bank conflicts on GPUs.
Key Deliverables
Implement AoSoA memory layout transformations at the memref level.
Automatically insert compile-time padding for 2D/3D tile strides to eliminate GPU shared memory bank conflicts and CPU cache set aliasing.
Implement swizzled memory indexing for contiguous SIMD loads on non-major dimensions.
Incremental step merged in #891: automatic AoSoA layout canonicalization (structural IR rewrite, not text editing) with a --no-aosoa opt-out, benchmark, and tests. 210 MLIR/transpiler tests pass. Conflict-padding for cache-line alignment remains.
Maintenance note (2026-09-12): #891 merged an incremental AoSoA layout canonicalization at 121bf59c343321f7555ef58d0b65cca43d81d5c4, including a --no-aosoa opt-out plus focused benchmark/unit coverage. This does not appear to complete the full issue: conflict-padding for GPU shared-memory / CPU cache-set aliasing and swizzled indexing for non-major-dimension contiguous SIMD loads remain explicit deliverables. Keeping #667 open is correct; next work should target those remaining transforms and validate them locally.
Added PR #1217 with direct AoSoA padding coverage. The existing four-element Particle fixture now asserts memref<5xf32> under the opt-in padding mode, alongside the non-power-of-two swizzle check.
Activity
mlir: automatic AoSoA memory layout transformation (#667) (#891)
godofecht commentedon Sep 12, 2026
Incremental step merged in #891: automatic AoSoA layout canonicalization (structural IR rewrite, not text editing) with a --no-aosoa opt-out, benchmark, and tests. 210 MLIR/transpiler tests pass. Conflict-padding for cache-line alignment remains.
godofecht commentedon Sep 12, 2026
Maintenance note (2026-09-12): #891 merged an incremental AoSoA layout canonicalization at
121bf59c343321f7555ef58d0b65cca43d81d5c4, including a--no-aosoaopt-out plus focused benchmark/unit coverage. This does not appear to complete the full issue: conflict-padding for GPU shared-memory / CPU cache-set aliasing and swizzled indexing for non-major-dimension contiguous SIMD loads remain explicit deliverables. Keeping #667 open is correct; next work should target those remaining transforms and validate them locally.docs: denotational MLIR design, archive tags, AGENTS.md refresh
docs: denotational MLIR design, archive tags, AGENTS.md refresh (#1158)
godofecht commentedon Oct 2, 2026
Added PR #1217 with direct AoSoA padding coverage. The existing four-element Particle fixture now asserts memref<5xf32> under the opt-in padding mode, alongside the non-power-of-two swizzle check.