@@ -7,33 +7,119 @@ SPDX-License-Identifier: AGPL-3.0-or-later
77
88## [ Unreleased]
99
10+ ## [ 0.1.4] - 2025-12-18
11+
1012### Added
1113
12- - ** Testing** : First integration test suite for diffusion model in
13- ` tests/integration/test_diffusion_integration.cpp ` validating complete
14- simulation pipeline (World → Decomposition → FFT → Model → Time Integration)
15- against analytical solutions. Includes 4 test cases with 331 assertions:
16- 1D sinusoidal diffusion with convergence validation, 3D Gaussian diffusion
17- with spherical symmetry preservation, and MPI consistency verification.
18- Test helper model in ` tests/fixtures/diffusion_model.hpp ` demonstrates
19- "Laboratory, Not Fortress" philosophy with public ` m_ ` prefixed fields.
20- All tests execute in <2 seconds validating spectral method accuracy
21- (max error <1e-4, RMS <5e-5). Establishes pattern for future physics
22- validation tests and enables safe refactoring of core components.
14+ - ** GPU/CUDA Support** : Complete CUDA implementation enabling GPU-accelerated PFC simulations.
15+ Added ` DataBuffer ` for backend-agnostic memory management with CPU/GPU memory traits,
16+ CUDA FFT integration via HeFFTe, GPU kernels for element-wise operations, and ` GPUVector `
17+ RAII container. Implemented full Tungsten model on GPU with optimized kernel launches and
18+ CPU-GPU synchronization for FieldModifiers and VTK output. Runtime backend selection API
19+ allows choosing between CPU and CUDA FFT backends via configuration. Comprehensive test
20+ coverage includes GPU device detection, memory allocation, FFT operations, and CPU vs CUDA
21+ result comparison. Build system supports optional ` OpenPFC_ENABLE_CUDA ` flag.
22+ - ** VTK Output** : New VTK ImageData writer in ` include/openpfc/results/vtk_writer.hpp ` and
23+ ` src/results/vtk_writer.cpp ` for parallel visualization output. Generates ` .vti ` files
24+ for each rank and ` .pvti ` parallel metadata files for ParaView/VisIt. Includes comprehensive
25+ test suite with MPI-aware tests and single-invocation test model to prevent cleanup races.
26+ - ** TOML Configuration** : Added TOML config file support alongside JSON. New
27+ ` feat(utils): Add TOML to JSON conversion utility ` enables ` .toml ` input files with
28+ automatic conversion. Integrated tomlplusplus library via CMake find module. All example
29+ configurations converted to TOML format. Unit tests validate conversion accuracy.
30+ - ** Modular CMake Architecture** : Refactored monolithic CMakeLists.txt into 12 focused modules
31+ in ` cmake/ ` directory: ProjectSetup, CompilerSettings, CudaSupport, Dependencies,
32+ LibraryConfiguration, BuildOptions, CodeCoverage, Installation, PackageConfig, BuildSummary.
33+ Improves maintainability and reusability. Documented in ` cmake/README.md ` .
34+ - ** CI/CD Pipelines** : Comprehensive GitHub Actions workflows for build matrix (GCC/Clang,
35+ multiple OS), documentation deployment, code coverage analysis with Codecov integration,
36+ and REUSE license compliance. Status badges added to README. Documentation includes
37+ workflow descriptions and troubleshooting guides.
38+ - ** Parameter Validation System** : New UI subsystem for configuration validation with
39+ ` ParameterMetadata ` , ` ParameterValidator ` , and ` ValidationResult ` classes. Supports nested
40+ path validation, finite checks, type validation, and helpful error messages. Integrated
41+ into Tungsten app with comprehensive test coverage (300+ assertions).
42+ - ** FFT Backend Selection** : Runtime FFT backend selection API allowing users to choose
43+ between available HeFFTe backends (FFTW, MKL, cuFFT) via configuration. New
44+ ` examples/fft_backend_benchmark.cpp ` demonstrates performance comparison. Backend field
45+ added to config schema with parsing and validation.
46+ - ** SparseVector & MPI Exchange** : New ` SparseVector ` container with halo exchange patterns
47+ for domain decomposition. Includes gather/scatter operations, neighbor exchange with MPI,
48+ and halo pattern creation utilities. Comprehensive test suite validates exchange correctness.
49+ - ** Testing Infrastructure** : First integration test suite for diffusion model validating
50+ complete simulation pipeline against analytical solutions (4 test cases, 331 assertions).
51+ Added benchmark subdirectory with microbenchmarks for World coordinate operations.
52+ Comprehensive unit tests for UI validation (300+ assertions), VTK writer (MPI-aware),
53+ DataBuffer, GPUVector, and SparseVector. Switched to single-invocation test model to
54+ prevent MPI initialization issues. Test coverage improvements across all modules.
2355- ** World API** : Type-safe World construction using strong types from ` strong_types.hpp ` .
24- Added new ` create(GridSize, PhysicalOrigin, GridSpacing) ` overload that prevents
25- parameter confusion at compile time. Strong types (GridSize, PhysicalOrigin, GridSpacing)
26- make function signatures self-documenting and catch argument order mistakes. Old
27- ` create(Int3, Real3, Real3) ` API marked as deprecated with migration guide in
28- documentation. Zero overhead - strong types compile away completely (verified with
29- static_assert and performance tests). Updated all World helper functions (uniform(),
30- from_bounds(), with_spacing(), with_origin()) to use new type-safe API internally.
31- Updated production examples (` 02_domain_decomposition.cpp ` , ` 04_diffusion_model.cpp ` ,
32- ` 12_cahn_hilliard.cpp ` ) to demonstrate the new API and migration path. Also fixed
33- missing ` set_fft() ` call in ` 04_diffusion_model.cpp ` that was causing runtime errors.
34- Comprehensive test suite added in ` tests/unit/core/test_world_strong_types.cpp `
35- with 71 assertions covering type safety, zero overhead, backward compatibility,
36- and coordinate transformations. All 195 World-related test assertions pass.
56+ Added new ` create(GridSize, PhysicalOrigin, GridSpacing) ` overload preventing parameter
57+ confusion at compile time. Old ` create(Int3, Real3, Real3) ` API deprecated. Zero overhead -
58+ strong types compile away completely. Updated all examples and helper functions. Test suite
59+ with 71 assertions covering type safety, zero overhead, and backward compatibility.
60+ - ** Documentation** : Added 10 comprehensive API examples (World, FFT, Simulator, Time,
61+ Decomposition, ResultsWriter, FieldModifier, DiscreteField, Model, custom field initializer).
62+ Added CITATION.cff for standardized citations. Improved Doxygen configuration. README
63+ sections on configuration validation, FFT backend selection, and extending OpenPFC.
64+ - ** Research Tools** : Added power consumption benchmarks for FFT operations (CPU and GPU),
65+ multi-GPU HeFFTe examples, and scalability testing applications for Tungsten model.
66+
67+ ### Changed
68+
69+ - ** CMake Structure** : Root ` project() ` moved to top-level CMakeLists.txt. Build options
70+ reorganized into logical modules. Test discovery switched to single-invocation model.
71+ Benchmark compilation now optional via ` OpenPFC_BUILD_BENCHMARKS ` .
72+ - ** Tungsten Structure** : Split monolithic tungsten code into modular headers and separate
73+ JSON inputs into ` inputs_json/ ` subdirectory. Restructured JSON schema to nested format.
74+ Renamed 'origo' field to 'origin' for consistency.
75+ - ** UI Module** : Split monolithic ` ui.hpp ` into modular components. Made ` plan_options `
76+ optional in app config. Added error formatting utilities for better user messages.
77+ - ** World Module** : Split ` world.hpp ` into modular headers. Added query helper examples.
78+ Updated coordinate benchmark documentation.
79+ - ** Test Organization** : Split monolithic parameter validation tests. Serialize VTK writer
80+ tests to prevent cleanup races. Make ` MPI_Worker ` static to persist MPI per process.
81+ Normalize test commands under single-invocation model.
82+ - ** Build Warnings** : Enabled additional compiler warnings for code quality in Debug builds.
83+ Added ` -Werror=format-security ` . Made GCC-specific warnings conditional. Format check
84+ warns instead of fails in Nix builds.
85+ - ** Dependencies** : Updated nixpkgs from 23.11 to 24.05. Added git and tomlplusplus to
86+ Nix build dependencies. Integrated Catch2 test discovery.
87+
88+ ### Fixed
89+
90+ - ** Build System** : Fixed CMake warnings by moving ` project() ` to root. Fixed Catch2 test
91+ discovery and optional MPI suites. Made documentation comment posting optional in CI.
92+ Cleaned up clang-format artifacts before REUSE checks. Improved error reporting in Nix tests.
93+ - ** Test Fixes** : Fixed narrowing conversions in sparse vector tests. Fixed GridSpacing
94+ initializers in FFT tests. Fixed syntax errors in world benchmark and CUDA tests. Added
95+ missing ` pfc ` namespace qualifiers. Suppressed unused variable/parameter warnings with
96+ ` [[maybe_unused]] ` . Fixed incorrectly converted ` world::create ` calls.
97+ - ** Application Fixes** : Fixed missing ` set_fft() ` call in diffusion example causing runtime
98+ errors. Removed unused fields (verbose in Diffusion, m_first in Aluminum). Fixed array
99+ initialization in SeedFCC. Added MPI-aware main to tungsten CPU vs CUDA test.
100+ - ** MPI Fixes** : Fixed ` MPI_Worker ` to be safe for test frameworks. Query current MPI
101+ rank/size when generating PVTI instead of using stale values. Synchronize ranks before
102+ cleanup in VTK writer test to prevent races.
103+ - ** Memory Safety** : Initialize all params struct members in aluminum to prevent undefined
104+ behavior. Add explicit template instantiation for World constructor. Fix CPU FFT
105+ ` std::vector ` interface to call HeFFTe directly.
106+ - ** Code Quality** : Removed redundant const qualifiers. Added missing override keywords.
107+ Fixed variable shadowing in multiple files. Removed variable shadowing in timing collection.
108+ Fixed clang-format violations across codebase.
109+ - ** CI/CD** : Removed ubuntu-20.04 from test matrix. Removed Cachix binary cache step.
110+ Initialized git submodules in all workflows. Made clang-format check warning instead of
111+ error. Used forked clang-format-action with fail-on-error option.
112+ - ** Documentation** : Removed internal tracking references from code. Added SPDX headers for
113+ REUSE compliance to all test READMEs. Fixed Doxygen file headers for better doc generation.
114+
115+ ### Deprecated
116+
117+ - ** World API** : Old ` world::create(Int3, Real3, Real3) ` deprecated in favor of type-safe
118+ ` create(GridSize, PhysicalOrigin, GridSpacing) ` . Migration guide in documentation.
119+
120+ ### Breaking Changes
121+
122+ None - all deprecated APIs remain functional with warnings.
37123
38124## [ 0.1.3] - 2025-11-25
39125
0 commit comments