1bcb2dfaeSJed Brown# Changes/Release Notes 2bcb2dfaeSJed Brown 3bcb2dfaeSJed BrownOn this page we provide a summary of the main API changes, new features and examples 4bcb2dfaeSJed Brownfor each release of libCEED. 5bcb2dfaeSJed Brown 6bcb2dfaeSJed Brown(main)= 7bcb2dfaeSJed Brown 8bcb2dfaeSJed Brown## Current `main` branch 9bcb2dfaeSJed Brown 107e7773b5SJeremy L Thompson### Interface changes 117e7773b5SJeremy L Thompson 127e7773b5SJeremy L Thompson- Update {c:func}`CeedQFunctionGetFields` and {c:func}`CeedOperatorGetFields` to include number of fields. 13ce4822f6SJeremy L Thompson- Promote to the public API: QFunction and Operator field objects, `CeedQFunctionField` and `CeedOperatorField`, and associated getters, {c:func}`CeedQFunctionGetFields`; {c:func}`CeedQFunctionFieldGetName`; {c:func}`CeedQFunctionFieldGetSize`; {c:func}`CeedQFunctionFieldGetEvalMode`; {c:func}`CeedOperatorGetFields`; {c:func}`CeedOperatorFieldGetElemRestriction`; {c:func}`CeedOperatorFieldGetBasis`; and {c:func}`CeedOperatorFieldGetVector`. 14f04ea552SJeremy L Thompson- Clarify and document conditions where `CeedQFunction` and `CeedOperator` become immutable and no further fields or suboperators can be added. 1570a7ffb3SJeremy L Thompson- Add {c:func}`CeedOperatorLinearAssembleQFunctionBuildOrUpdate` to reduce object creation overhead in assembly of CeedOperator preconditioning ingredients. 164db537f9SJeremy L Thompson- Promote {c:func}`CeedOperatorCheckReady`to the public API to facilitate interactive interfaces. 17dcc1e3ecSJeremy L Thompson- Warning added when compiling OCCA backend to alert users that this backend is experimental. 189a1d3511SJeremy L Thompson- `ceed-backend.h`, `ceed-hash.h`, and `ceed-khash.h` removed. Users should use `ceed/backend.h`, `ceed/hash.h`, and `ceed/khash.h`. 1943e1b16fSJeremy L Thompson- Added {c:func}`CeedQFunctionGetKernelName`; refactored {c:func}`CeedQFunctionGetSourcePath` to exclude function kernel name. 209c774eddSJeremy L Thompson- Clarify documentation for {c:func}`CeedVectorTakeArray`; this function will error if {c:func}`CeedVectorSetArray` with `copy_mode == CEED_USE_POINTER` was not previously called for the corresponding `CeedMemType`. 219c774eddSJeremy L Thompson- Added {c:func}`CeedVectorGetArrayWrite` that allows access to uninitalized arrays; require initalized data for {c:func}`CeedVectorGetArray`. 22c38440baSJed Brown- Added {c:func}`CeedQFunctionContextRegisterDouble` and {c:func}`CeedQFunctionContextRegisterInt32` with {c:func}`CeedQFunctionContextSetDouble` and {c:func}`CeedQFunctionContextSetInt32` to facilitate easy updating of {c:struct}`CeedQFunctionContext` data by user defined field names. 23cdf32b93SJeremy L Thompson- Added {c:func}`CeedQFunctionContextGetFieldDescriptions` to retreive user defined descriptions of fields that are registered with `CeedQFunctionContextRegister*`. 247a06ec9fSJeremy L Thompson- Renamed `CeedElemTopology` entries for clearer namespacing between libCEED enums. 25f4f98f9dSJeremy L Thompson- Added type `CeedSize` equivalent to `ptrdiff_t` for array sizes in {c:func}`CeedVectorCreate`, {c:func}`CeedVectorGetLength`, `CeedElemRestrictionCreate*`, {c:func}`CeedElemRestrictionGetLVectorSize`, and {c:func}`CeedOperatorLinearAssembleSymbolic`. This is a breaking change. 26*8b919e6bSJeremy L Thompson- Added {c:func}`CeedOperatorSetQFunctionUpdated` to facilitate QFunction data re-use between operators sharing the same quadrature space, such as in a multigrid hierarchy. 277e7773b5SJeremy L Thompson 28f479eb23SJeremy L Thompson### New features 29f479eb23SJeremy L Thompson 30f479eb23SJeremy L Thompson- `CeedScalar` can now be set as `float` or `double` at compile time. 3130601ac0SJeremy L Thompson- Added JiT utilities in `ceed/jit-tools.h` to reduce duplicated code in GPU backends. 32fb3c7d02SJeremy L Thompson- Added support for JiT of QFunctions with `#include "relative/path/local-file.h"` statements for additional local files. Note that files included with `""` are searched relative to the current file first, then by compiler paths (as with `<>` includes). To use this feature, one should adhere to relative paths only, not compiler flags like `-I`, which the JiT will not be aware of. 3323dfbf5bSJeremy L Thompson- Remove need to guard library headers in QFunction source for code generation backends. 343f21f6b1SJeremy L Thompson- `CeedDebugEnv()` macro created to provide debugging outputs when Ceed context is not present. 35f7e22acaSJeremy L Thompson- Added {c:func}`CeedStringAllocCopy` to reduce repeated code for copying strings internally. 363451974fSJeremy L Thompson- Added {c:func}`CeedPathConcatenate` to facilitate loading kernel source files with a path relative to the current file. 377a06ec9fSJeremy L Thompson- Added support for non-tensor H(div) elements, to include CPU backend implementations and {c:func}`CeedBasisCreateHdiv` convenience constructor. 38d34e270fSJeremy L Thompson- Added {c:func}`CeedQFunctionSetContextWritable` and read-only access to `CeedQFunctionContext` data as an optional feature to improve GPU performance. By default, calling the `CeedQFunctionUser` during {c:func}`CeedQFunctionApply` is assumed to write into the `CeedQFunctionContext` data, consistent with the previous behavior. Note that if a user asserts that their `CeedQFunctionUser` does not write into the `CeedQFunctionContext` data, they are responsible for the validity of this assertion. 39f479eb23SJeremy L Thompson 40bcb2dfaeSJed Brown### Maintainability 41bcb2dfaeSJed Brown 42bcb2dfaeSJed Brown- Refactored preconditioner support internally to facilitate future development and improve GPU completeness/test coverage. 43db52d626SJeremy L Thompson- `Include-what-you-use` makefile target added as `make iwyu`. 44bf4cb664SJeremy L Thompson- Create backend constant `CEED_FIELD_MAX` to reduce magic numbers in codebase. 453451974fSJeremy L Thompson- Put GPU JiTed kernel source code into separate files. 46f9996dfdSJeremy L Thompson- Dropped legacy version support in PETSc based examples to better utilize PETSc DMPlex and Mat updates to support libCEED; current minimum PETSc version for the examples is v3.17. 47bcb2dfaeSJed Brown 48bcb2dfaeSJed Brown(v0-9)= 49bcb2dfaeSJed Brown 50bcb2dfaeSJed Brown## v0.9 (Jul 6, 2021) 51bcb2dfaeSJed Brown 52bcb2dfaeSJed Brown### Interface changes 53bcb2dfaeSJed Brown 54bcb2dfaeSJed Brown- Minor modification in error handling macro to silence pedantic warnings when compiling with Clang, but no functional impact. 55bcb2dfaeSJed Brown 56bcb2dfaeSJed Brown### New features 57bcb2dfaeSJed Brown 58bcb2dfaeSJed Brown- Add {c:func}`CeedVectorAXPY` and {c:func}`CeedVectorPointwiseMult` as a convenience for stand-alone testing and internal use. 59bcb2dfaeSJed Brown- Add `CEED_QFUNCTION_HELPER` macro to properly annotate QFunction helper functions for code generation backends. 60bcb2dfaeSJed Brown- Add `CeedPragmaOptimizeOff` macro for code that is sensitive to floating point errors from fast math optimizations. 61bcb2dfaeSJed Brown- Rust support: split `libceed-sys` crate out of `libceed` and [publish both on crates.io](https://crates.io/crates/libceed). 62bcb2dfaeSJed Brown 63bcb2dfaeSJed Brown### Performance improvements 64bcb2dfaeSJed Brown 65bcb2dfaeSJed Brown### Examples 66bcb2dfaeSJed Brown 67bcb2dfaeSJed Brown- Solid mechanics mini-app updated to explore the performance impacts of various formulations in the initial and current configurations. 68bcb2dfaeSJed Brown- Fluid mechanics example adds GPU support and improves modularity. 69bcb2dfaeSJed Brown 70bcb2dfaeSJed Brown### Deprecated backends 71bcb2dfaeSJed Brown 72bcb2dfaeSJed Brown- The `/cpu/self/tmpl` and `/cpu/self/tmpl/sub` backends have been removed. These backends were intially added to test the backend inheritance mechanism, but this mechanism is now widely used and tested in multiple backends. 73bcb2dfaeSJed Brown 74bcb2dfaeSJed Brown(v0-8)= 75bcb2dfaeSJed Brown 76bcb2dfaeSJed Brown## v0.8 (Mar 31, 2021) 77bcb2dfaeSJed Brown 78bcb2dfaeSJed Brown### Interface changes 79bcb2dfaeSJed Brown 80bcb2dfaeSJed Brown- Error handling improved to include enumerated error codes for C interface return values. 81bcb2dfaeSJed Brown- Installed headers that will follow semantic versioning were moved to {code}`include/ceed` directory. These headers have been renamed from {code}`ceed-*.h` to {code}`ceed/*.h`. Placeholder headers with the old naming schema are currently provided, but these headers will be removed in the libCEED v0.9 release. 82bcb2dfaeSJed Brown 83bcb2dfaeSJed Brown### New features 84bcb2dfaeSJed Brown 85bcb2dfaeSJed Brown- Julia and Rust interfaces added, providing a nearly 1-1 correspondence with the C interface, plus some convenience features. 86bcb2dfaeSJed Brown- Static libraries can be built with `make STATIC=1` and the pkg-config file is installed accordingly. 87bcb2dfaeSJed Brown- Add {c:func}`CeedOperatorLinearAssembleSymbolic` and {c:func}`CeedOperatorLinearAssemble` to support full assembly of libCEED operators. 88bcb2dfaeSJed Brown 89bcb2dfaeSJed Brown### Performance improvements 90bcb2dfaeSJed Brown 91bcb2dfaeSJed Brown- New HIP MAGMA backends for hipMAGMA library users: `/gpu/hip/magma` and `/gpu/hip/magma/det`. 92bcb2dfaeSJed Brown- New HIP backends for improved tensor basis performance: `/gpu/hip/shared` and `/gpu/hip/gen`. 93bcb2dfaeSJed Brown 94bcb2dfaeSJed Brown### Examples 95bcb2dfaeSJed Brown 96bcb2dfaeSJed Brown- {ref}`example-petsc-elasticity` example updated with traction boundary conditions and improved Dirichlet boundary conditions. 97bcb2dfaeSJed Brown- {ref}`example-petsc-elasticity` example updated with Neo-Hookean hyperelasticity in current configuration as well as improved Neo-Hookean hyperelasticity exploring storage vs computation tradeoffs. 98bcb2dfaeSJed Brown- {ref}`example-petsc-navier-stokes` example updated with isentropic traveling vortex test case, an analytical solution to the Euler equations that is useful for testing boundary conditions, discretization stability, and order of accuracy. 99bcb2dfaeSJed Brown- {ref}`example-petsc-navier-stokes` example updated with support for performing convergence study and plotting order of convergence by polynomial degree. 100bcb2dfaeSJed Brown 101bcb2dfaeSJed Brown(v0-7)= 102bcb2dfaeSJed Brown 103bcb2dfaeSJed Brown## v0.7 (Sep 29, 2020) 104bcb2dfaeSJed Brown 105bcb2dfaeSJed Brown### Interface changes 106bcb2dfaeSJed Brown 107bcb2dfaeSJed Brown- Replace limited {code}`CeedInterlaceMode` with more flexible component stride {code}`compstride` in {code}`CeedElemRestriction` constructors. 108bcb2dfaeSJed Brown As a result, the {code}`indices` parameter has been replaced with {code}`offsets` and the {code}`nnodes` parameter has been replaced with {code}`lsize`. 109bcb2dfaeSJed Brown These changes improve support for mixed finite element methods. 110bcb2dfaeSJed Brown- Replace various uses of {code}`Ceed*Get*Status` with {code}`Ceed*Is*` in the backend API to match common nomenclature. 111bcb2dfaeSJed Brown- Replace {code}`CeedOperatorAssembleLinearDiagonal` with {c:func}`CeedOperatorLinearAssembleDiagonal` for clarity. 112bcb2dfaeSJed Brown- Linear Operators can be assembled as point-block diagonal matrices with {c:func}`CeedOperatorLinearAssemblePointBlockDiagonal`, provided in row-major form in a {code}`ncomp` by {code}`ncomp` block per node. 113bcb2dfaeSJed Brown- Diagonal assemble interface changed to accept a {ref}`CeedVector` instead of a pointer to a {ref}`CeedVector` to reduce memory movement when interfacing with calling code. 114bcb2dfaeSJed Brown- Added {c:func}`CeedOperatorLinearAssembleAddDiagonal` and {c:func}`CeedOperatorLinearAssembleAddPointBlockDiagonal` for improved future integration with codes such as MFEM that compose the action of {ref}`CeedOperator`s external to libCEED. 115bcb2dfaeSJed Brown- Added {c:func}`CeedVectorTakeAray` to sync and remove libCEED read/write access to an allocated array and pass ownership of the array to the caller. 116bcb2dfaeSJed Brown This function is recommended over {c:func}`CeedVectorSyncArray` when the {code}`CeedVector` has an array owned by the caller that was set by {c:func}`CeedVectorSetArray`. 117bcb2dfaeSJed Brown- Added {code}`CeedQFunctionContext` object to manage user QFunction context data and reduce copies between device and host memory. 118bcb2dfaeSJed Brown- Added {c:func}`CeedOperatorMultigridLevelCreate`, {c:func}`CeedOperatorMultigridLevelCreateTensorH1`, and {c:func}`CeedOperatorMultigridLevelCreateH1` to facilitate creation of multigrid prolongation, restriction, and coarse grid operators using a common quadrature space. 119bcb2dfaeSJed Brown 120bcb2dfaeSJed Brown### New features 121bcb2dfaeSJed Brown 122bcb2dfaeSJed Brown- New HIP backend: `/gpu/hip/ref`. 123bcb2dfaeSJed Brown- CeedQFunction support for user `CUfunction`s in some backends 124bcb2dfaeSJed Brown 125bcb2dfaeSJed Brown### Performance improvements 126bcb2dfaeSJed Brown 127bcb2dfaeSJed Brown- OCCA backend rebuilt to facilitate future performance enhancements. 128bcb2dfaeSJed Brown- Petsc BPs suite improved to reduce noise due to multiple calls to {code}`mpiexec`. 129bcb2dfaeSJed Brown 130bcb2dfaeSJed Brown### Examples 131bcb2dfaeSJed Brown 132bcb2dfaeSJed Brown- {ref}`example-petsc-elasticity` example updated with strain energy computation and more flexible boundary conditions. 133bcb2dfaeSJed Brown 134bcb2dfaeSJed Brown### Deprecated backends 135bcb2dfaeSJed Brown 136bcb2dfaeSJed Brown- The `/gpu/cuda/reg` backend has been removed, with its core features moved into `/gpu/cuda/ref` and `/gpu/cuda/shared`. 137bcb2dfaeSJed Brown 138bcb2dfaeSJed Brown(v0-6)= 139bcb2dfaeSJed Brown 140bcb2dfaeSJed Brown## v0.6 (Mar 29, 2020) 141bcb2dfaeSJed Brown 142bcb2dfaeSJed BrownlibCEED v0.6 contains numerous new features and examples, as well as expanded 143bcb2dfaeSJed Browndocumentation in [this new website](https://libceed.readthedocs.io). 144bcb2dfaeSJed Brown 145bcb2dfaeSJed Brown### New features 146bcb2dfaeSJed Brown 147bcb2dfaeSJed Brown- New Python interface using [CFFI](https://cffi.readthedocs.io/) provides a nearly 148bcb2dfaeSJed Brown 1-1 correspondence with the C interface, plus some convenience features. For instance, 149bcb2dfaeSJed Brown data stored in the {cpp:type}`CeedVector` structure are available without copy as 150bcb2dfaeSJed Brown {py:class}`numpy.ndarray`. Short tutorials are provided in 151bcb2dfaeSJed Brown [Binder](https://mybinder.org/v2/gh/CEED/libCEED/main?urlpath=lab/tree/examples/tutorials/). 152bcb2dfaeSJed Brown- Linear QFunctions can be assembled as block-diagonal matrices (per quadrature point, 153bcb2dfaeSJed Brown {c:func}`CeedOperatorAssembleLinearQFunction`) or to evaluate the diagonal 154bcb2dfaeSJed Brown ({c:func}`CeedOperatorAssembleLinearDiagonal`). These operations are useful for 155bcb2dfaeSJed Brown preconditioning ingredients and are used in the libCEED's multigrid examples. 156bcb2dfaeSJed Brown- The inverse of separable operators can be obtained using 157bcb2dfaeSJed Brown {c:func}`CeedOperatorCreateFDMElementInverse` and applied with 158bcb2dfaeSJed Brown {c:func}`CeedOperatorApply`. This is a useful preconditioning ingredient, 159bcb2dfaeSJed Brown especially for Laplacians and related operators. 160bcb2dfaeSJed Brown- New functions: {c:func}`CeedVectorNorm`, {c:func}`CeedOperatorApplyAdd`, 161bcb2dfaeSJed Brown {c:func}`CeedQFunctionView`, {c:func}`CeedOperatorView`. 162bcb2dfaeSJed Brown- Make public accessors for various attributes to facilitate writing composable code. 163bcb2dfaeSJed Brown- New backend: `/cpu/self/memcheck/serial`. 164bcb2dfaeSJed Brown- QFunctions using variable-length array (VLA) pointer constructs can be used with CUDA 165bcb2dfaeSJed Brown backends. (Single source is coming soon for OCCA backends.) 166bcb2dfaeSJed Brown- Fix some missing edge cases in CUDA backend. 167bcb2dfaeSJed Brown 168bcb2dfaeSJed Brown### Performance Improvements 169bcb2dfaeSJed Brown 170bcb2dfaeSJed Brown- MAGMA backend performance optimization and non-tensor bases. 171bcb2dfaeSJed Brown- No-copy optimization in {c:func}`CeedOperatorApply`. 172bcb2dfaeSJed Brown 173bcb2dfaeSJed Brown### Interface changes 174bcb2dfaeSJed Brown 175bcb2dfaeSJed Brown- Replace {code}`CeedElemRestrictionCreateIdentity` and 176bcb2dfaeSJed Brown {code}`CeedElemRestrictionCreateBlocked` with more flexible 177bcb2dfaeSJed Brown {c:func}`CeedElemRestrictionCreateStrided` and 178bcb2dfaeSJed Brown {c:func}`CeedElemRestrictionCreateBlockedStrided`. 179bcb2dfaeSJed Brown- Add arguments to {c:func}`CeedQFunctionCreateIdentity`. 180bcb2dfaeSJed Brown- Replace ambiguous uses of {cpp:enum}`CeedTransposeMode` for L-vector identification 181bcb2dfaeSJed Brown with {cpp:enum}`CeedInterlaceMode`. This is now an attribute of the 182bcb2dfaeSJed Brown {cpp:type}`CeedElemRestriction` (see {c:func}`CeedElemRestrictionCreate`) and no 183bcb2dfaeSJed Brown longer passed as `lmode` arguments to {c:func}`CeedOperatorSetField` and 184bcb2dfaeSJed Brown {c:func}`CeedElemRestrictionApply`. 185bcb2dfaeSJed Brown 186bcb2dfaeSJed Brown### Examples 187bcb2dfaeSJed Brown 188bcb2dfaeSJed BrownlibCEED-0.6 contains greatly expanded examples with {ref}`new documentation <Examples>`. 189bcb2dfaeSJed BrownNotable additions include: 190bcb2dfaeSJed Brown 191bcb2dfaeSJed Brown- Standalone {ref}`ex2-surface` ({file}`examples/ceed/ex2-surface`): compute the area of 192bcb2dfaeSJed Brown a domain in 1, 2, and 3 dimensions by applying a Laplacian. 193bcb2dfaeSJed Brown 194bcb2dfaeSJed Brown- PETSc {ref}`example-petsc-area` ({file}`examples/petsc/area.c`): computes surface area 195bcb2dfaeSJed Brown of domains (like the cube and sphere) by direct integration on a surface mesh; 196bcb2dfaeSJed Brown demonstrates geometric dimension different from topological dimension. 197bcb2dfaeSJed Brown 198bcb2dfaeSJed Brown- PETSc {ref}`example-petsc-bps`: 199bcb2dfaeSJed Brown 200bcb2dfaeSJed Brown - {file}`examples/petsc/bpsraw.c` (formerly `bps.c`): transparent CUDA support. 201bcb2dfaeSJed Brown - {file}`examples/petsc/bps.c` (formerly `bpsdmplex.c`): performance improvements 202bcb2dfaeSJed Brown and transparent CUDA support. 203bcb2dfaeSJed Brown - {ref}`example-petsc-bps-sphere` ({file}`examples/petsc/bpssphere.c`): 204bcb2dfaeSJed Brown generalizations of all CEED BPs to the surface of the sphere; demonstrates geometric 205bcb2dfaeSJed Brown dimension different from topological dimension. 206bcb2dfaeSJed Brown 207bcb2dfaeSJed Brown- {ref}`example-petsc-multigrid` ({file}`examples/petsc/multigrid.c`): new p-multigrid 208bcb2dfaeSJed Brown solver with algebraic multigrid coarse solve. 209bcb2dfaeSJed Brown 210bcb2dfaeSJed Brown- {ref}`example-petsc-navier-stokes` ({file}`examples/fluids/navierstokes.c`; formerly 211bcb2dfaeSJed Brown `examples/navier-stokes`): unstructured grid support (using PETSc's `DMPlex`), 212bcb2dfaeSJed Brown implicit time integration, SU/SUPG stabilization, free-slip boundary conditions, and 213bcb2dfaeSJed Brown quasi-2D computational domain support. 214bcb2dfaeSJed Brown 215bcb2dfaeSJed Brown- {ref}`example-petsc-elasticity` ({file}`examples/solids/elasticity.c`): new solver for 216bcb2dfaeSJed Brown linear elasticity, small-strain hyperelasticity, and globalized finite-strain 217bcb2dfaeSJed Brown hyperelasticity using p-multigrid with algebraic multigrid coarse solve. 218bcb2dfaeSJed Brown 219bcb2dfaeSJed Brown(v0-5)= 220bcb2dfaeSJed Brown 221bcb2dfaeSJed Brown## v0.5 (Sep 18, 2019) 222bcb2dfaeSJed Brown 223bcb2dfaeSJed BrownFor this release, several improvements were made. Two new CUDA backends were added to 224bcb2dfaeSJed Brownthe family of backends, of which, the new `cuda-gen` backend achieves state-of-the-art 225bcb2dfaeSJed Brownperformance using single-source {ref}`CeedQFunction`. From this release, users 226bcb2dfaeSJed Browncan define Q-Functions in a single source code independently of the targeted backend 227bcb2dfaeSJed Brownwith the aid of a new macro `CEED QFUNCTION` to support JIT (Just-In-Time) and CPU 228bcb2dfaeSJed Browncompilation of the user provided {ref}`CeedQFunction` code. To allow a unified 229bcb2dfaeSJed Browndeclaration, the {ref}`CeedQFunction` API has undergone a slight change: 230bcb2dfaeSJed Brownthe `QFunctionField` parameter `ncomp` has been changed to `size`. This change 231bcb2dfaeSJed Brownrequires setting the previous value of `ncomp` to `ncomp*dim` when adding a 232bcb2dfaeSJed Brown`QFunctionField` with eval mode `CEED EVAL GRAD`. 233bcb2dfaeSJed Brown 234bcb2dfaeSJed BrownAdditionally, new CPU backends 235bcb2dfaeSJed Brownwere included in this release, such as the `/cpu/self/opt/*` backends (which are 236bcb2dfaeSJed Brownwritten in pure C and use partial **E-vectors** to improve performance) and the 237bcb2dfaeSJed Brown`/cpu/self/ref/memcheck` backend (which relies upon the 238bcb2dfaeSJed Brown[Valgrind](http://valgrind.org/) Memcheck tool to help verify that user 239bcb2dfaeSJed Brown{ref}`CeedQFunction` have no undefined values). 240bcb2dfaeSJed BrownThis release also included various performance improvements, bug fixes, new examples, 241bcb2dfaeSJed Brownand improved tests. Among these improvements, vectorized instructions for 242bcb2dfaeSJed Brown{ref}`CeedQFunction` code compiled for CPU were enhanced by using `CeedPragmaSIMD` 243bcb2dfaeSJed Browninstead of `CeedPragmaOMP`, implementation of a {ref}`CeedQFunction` gallery and 244bcb2dfaeSJed Brownidentity Q-Functions were introduced, and the PETSc benchmark problems were expanded 245bcb2dfaeSJed Brownto include unstructured meshes handling were. For this expansion, the prior version of 246bcb2dfaeSJed Brownthe PETSc BPs, which only included data associated with structured geometries, were 247bcb2dfaeSJed Brownrenamed `bpsraw`, and the new version of the BPs, which can handle data associated 248bcb2dfaeSJed Brownwith any unstructured geometry, were called `bps`. Additionally, other benchmark 249bcb2dfaeSJed Brownproblems, namely BP2 and BP4 (the vector-valued versions of BP1 and BP3, respectively), 250bcb2dfaeSJed Brownand BP5 and BP6 (the collocated versions---for which the quadrature points are the same 251bcb2dfaeSJed Brownas the Gauss Lobatto nodes---of BP3 and BP4 respectively) were added to the PETSc 252bcb2dfaeSJed Brownexamples. Furthermoew, another standalone libCEED example, called `ex2`, which 253bcb2dfaeSJed Browncomputes the surface area of a given mesh was added to this release. 254bcb2dfaeSJed Brown 255bcb2dfaeSJed BrownBackends available in this release: 256bcb2dfaeSJed Brown 25768e843eeSJed Brown| CEED resource (`-ceed`) | Backend | 25868e843eeSJed Brown|--------------------------|-----------------------------------------------------| 25968e843eeSJed Brown| `/cpu/self/ref/serial` | Serial reference implementation | 26068e843eeSJed Brown| `/cpu/self/ref/blocked` | Blocked reference implementation | 26168e843eeSJed Brown| `/cpu/self/ref/memcheck` | Memcheck backend, undefined value checks | 26268e843eeSJed Brown| `/cpu/self/opt/serial` | Serial optimized C implementation | 26368e843eeSJed Brown| `/cpu/self/opt/blocked` | Blocked optimized C implementation | 26468e843eeSJed Brown| `/cpu/self/avx/serial` | Serial AVX implementation | 26568e843eeSJed Brown| `/cpu/self/avx/blocked` | Blocked AVX implementation | 26668e843eeSJed Brown| `/cpu/self/xsmm/serial` | Serial LIBXSMM implementation | 26768e843eeSJed Brown| `/cpu/self/xsmm/blocked` | Blocked LIBXSMM implementation | 26868e843eeSJed Brown| `/cpu/occa` | Serial OCCA kernels | 26968e843eeSJed Brown| `/gpu/occa` | CUDA OCCA kernels | 27068e843eeSJed Brown| `/omp/occa` | OpenMP OCCA kernels | 27168e843eeSJed Brown| `/ocl/occa` | OpenCL OCCA kernels | 27268e843eeSJed Brown| `/gpu/cuda/ref` | Reference pure CUDA kernels | 27368e843eeSJed Brown| `/gpu/cuda/reg` | Pure CUDA kernels using one thread per element | 27468e843eeSJed Brown| `/gpu/cuda/shared` | Optimized pure CUDA kernels using shared memory | 27568e843eeSJed Brown| `/gpu/cuda/gen` | Optimized pure CUDA kernels using code generation | 27668e843eeSJed Brown| `/gpu/magma` | CUDA MAGMA kernels | 277bcb2dfaeSJed Brown 278bcb2dfaeSJed BrownExamples available in this release: 279bcb2dfaeSJed Brown 28068e843eeSJed Brown:::{list-table} 28168e843eeSJed Brown:header-rows: 1 28268e843eeSJed Brown:widths: auto 28368e843eeSJed Brown* - User code 28468e843eeSJed Brown - Example 28568e843eeSJed Brown* - `ceed` 28668e843eeSJed Brown - * ex1 (volume) 28768e843eeSJed Brown * ex2 (surface) 28868e843eeSJed Brown* - `mfem` 28968e843eeSJed Brown - * BP1 (scalar mass operator) 29068e843eeSJed Brown * BP3 (scalar Laplace operator) 29168e843eeSJed Brown* - `petsc` 29268e843eeSJed Brown - * BP1 (scalar mass operator) 29368e843eeSJed Brown * BP2 (vector mass operator) 29468e843eeSJed Brown * BP3 (scalar Laplace operator) 29568e843eeSJed Brown * BP4 (vector Laplace operator) 29668e843eeSJed Brown * BP5 (collocated scalar Laplace operator) 29768e843eeSJed Brown * BP6 (collocated vector Laplace operator) 29868e843eeSJed Brown * Navier-Stokes 29968e843eeSJed Brown* - `nek5000` 30068e843eeSJed Brown - * BP1 (scalar mass operator) 30168e843eeSJed Brown * BP3 (scalar Laplace operator) 30268e843eeSJed Brown::: 303bcb2dfaeSJed Brown 304bcb2dfaeSJed Brown(v0-4)= 305bcb2dfaeSJed Brown 306bcb2dfaeSJed Brown## v0.4 (Apr 1, 2019) 307bcb2dfaeSJed Brown 308bcb2dfaeSJed BrownlibCEED v0.4 was made again publicly available in the second full CEED software 309bcb2dfaeSJed Browndistribution, release CEED 2.0. This release contained notable features, such as 310bcb2dfaeSJed Brownfour new CPU backends, two new GPU backends, CPU backend optimizations, initial 311bcb2dfaeSJed Brownsupport for operator composition, performance benchmarking, and a Navier-Stokes demo. 312bcb2dfaeSJed BrownThe new CPU backends in this release came in two families. The `/cpu/self/*/serial` 313bcb2dfaeSJed Brownbackends process one element at a time and are intended for meshes with a smaller number 314bcb2dfaeSJed Brownof high order elements. The `/cpu/self/*/blocked` backends process blocked batches of 315bcb2dfaeSJed Browneight interlaced elements and are intended for meshes with higher numbers of elements. 316bcb2dfaeSJed BrownThe `/cpu/self/avx/*` backends rely upon AVX instructions to provide vectorized CPU 317bcb2dfaeSJed Brownperformance. The `/cpu/self/xsmm/*` backends rely upon the 318bcb2dfaeSJed Brown[LIBXSMM](http://github.com/hfp/libxsmm) package to provide vectorized CPU 319bcb2dfaeSJed Brownperformance. The `/gpu/cuda/*` backends provide GPU performance strictly using CUDA. 320bcb2dfaeSJed BrownThe `/gpu/cuda/ref` backend is a reference CUDA backend, providing reasonable 321bcb2dfaeSJed Brownperformance for most problem configurations. The `/gpu/cuda/reg` backend uses a simple 322bcb2dfaeSJed Brownparallelization approach, where each thread treats a finite element. Using just in time 323bcb2dfaeSJed Browncompilation, provided by nvrtc (NVidia Runtime Compiler), and runtime parameters, this 324bcb2dfaeSJed Brownbackend unroll loops and map memory address to registers. The `/gpu/cuda/reg` backend 325bcb2dfaeSJed Brownachieve good peak performance for 1D, 2D, and low order 3D problems, but performance 326bcb2dfaeSJed Browndeteriorates very quickly when threads run out of registers. 327bcb2dfaeSJed Brown 328bcb2dfaeSJed BrownA new explicit time-stepping Navier-Stokes solver was added to the family of libCEED 329bcb2dfaeSJed Brownexamples in the `examples/petsc` directory (see {ref}`example-petsc-navier-stokes`). 330bcb2dfaeSJed BrownThis example solves the time-dependent Navier-Stokes equations of compressible gas 331bcb2dfaeSJed Browndynamics in a static Eulerian three-dimensional frame, using structured high-order 332bcb2dfaeSJed Brownfinite/spectral element spatial discretizations and explicit high-order time-stepping 333bcb2dfaeSJed Brown(available in PETSc). Moreover, the Navier-Stokes example was developed using PETSc, 334bcb2dfaeSJed Brownso that the pointwise physics (defined at quadrature points) is separated from the 335bcb2dfaeSJed Brownparallelization and meshing concerns. 336bcb2dfaeSJed Brown 337bcb2dfaeSJed BrownBackends available in this release: 338bcb2dfaeSJed Brown 33968e843eeSJed Brown| CEED resource (`-ceed`) | Backend | 34068e843eeSJed Brown|--------------------------|-----------------------------------------------------| 34168e843eeSJed Brown| `/cpu/self/ref/serial` | Serial reference implementation | 34268e843eeSJed Brown| `/cpu/self/ref/blocked` | Blocked reference implementation | 34368e843eeSJed Brown| `/cpu/self/tmpl` | Backend template, defaults to `/cpu/self/blocked` | 34468e843eeSJed Brown| `/cpu/self/avx/serial` | Serial AVX implementation | 34568e843eeSJed Brown| `/cpu/self/avx/blocked` | Blocked AVX implementation | 34668e843eeSJed Brown| `/cpu/self/xsmm/serial` | Serial LIBXSMM implementation | 34768e843eeSJed Brown| `/cpu/self/xsmm/blocked` | Blocked LIBXSMM implementation | 34868e843eeSJed Brown| `/cpu/occa` | Serial OCCA kernels | 34968e843eeSJed Brown| `/gpu/occa` | CUDA OCCA kernels | 35068e843eeSJed Brown| `/omp/occa` | OpenMP OCCA kernels | 35168e843eeSJed Brown| `/ocl/occa` | OpenCL OCCA kernels | 35268e843eeSJed Brown| `/gpu/cuda/ref` | Reference pure CUDA kernels | 35368e843eeSJed Brown| `/gpu/cuda/reg` | Pure CUDA kernels using one thread per element | 35468e843eeSJed Brown| `/gpu/magma` | CUDA MAGMA kernels | 355bcb2dfaeSJed Brown 356bcb2dfaeSJed BrownExamples available in this release: 357bcb2dfaeSJed Brown 35868e843eeSJed Brown:::{list-table} 35968e843eeSJed Brown:header-rows: 1 36068e843eeSJed Brown:widths: auto 36168e843eeSJed Brown* - User code 36268e843eeSJed Brown - Example 36368e843eeSJed Brown* - `ceed` 36468e843eeSJed Brown - * ex1 (volume) 36568e843eeSJed Brown* - `mfem` 36668e843eeSJed Brown - * BP1 (scalar mass operator) 36768e843eeSJed Brown * BP3 (scalar Laplace operator) 36868e843eeSJed Brown* - `petsc` 36968e843eeSJed Brown - * BP1 (scalar mass operator) 37068e843eeSJed Brown * BP3 (scalar Laplace operator) 37168e843eeSJed Brown * Navier-Stokes 37268e843eeSJed Brown* - `nek5000` 37368e843eeSJed Brown - * BP1 (scalar mass operator) 37468e843eeSJed Brown * BP3 (scalar Laplace operator) 37568e843eeSJed Brown::: 376bcb2dfaeSJed Brown 377bcb2dfaeSJed Brown(v0-3)= 378bcb2dfaeSJed Brown 379bcb2dfaeSJed Brown## v0.3 (Sep 30, 2018) 380bcb2dfaeSJed Brown 381bcb2dfaeSJed BrownNotable features in this release include active/passive field interface, support for 382bcb2dfaeSJed Brownnon-tensor bases, backend optimization, and improved Fortran interface. This release 383bcb2dfaeSJed Brownalso focused on providing improved continuous integration, and many new tests with code 384bcb2dfaeSJed Browncoverage reports of about 90%. This release also provided a significant change to the 385bcb2dfaeSJed Brownpublic interface: a {ref}`CeedQFunction` can take any number of named input and output 386bcb2dfaeSJed Brownarguments while {ref}`CeedOperator` connects them to the actual data, which may be 387bcb2dfaeSJed Brownsupplied explicitly to `CeedOperatorApply()` (active) or separately via 388bcb2dfaeSJed Brown`CeedOperatorSetField()` (passive). This interface change enables reusable libraries 389bcb2dfaeSJed Brownof CeedQFunctions and composition of block solvers constructed using 390bcb2dfaeSJed Brown{ref}`CeedOperator`. A concept of blocked restriction was added to this release and 391bcb2dfaeSJed Brownused in an optimized CPU backend. Although this is typically not visible to the user, 392bcb2dfaeSJed Brownit enables effective use of arbitrary-length SIMD while maintaining cache locality. 393bcb2dfaeSJed BrownThis CPU backend also implements an algebraic factorization of tensor product gradients 394bcb2dfaeSJed Brownto perform fewer operations than standard application of interpolation and 395bcb2dfaeSJed Browndifferentiation from nodes to quadrature points. This algebraic formulation 396bcb2dfaeSJed Brownautomatically supports non-polynomial and non-interpolatory bases, thus is more general 397bcb2dfaeSJed Brownthan the more common derivation in terms of Lagrange polynomials on the quadrature points. 398bcb2dfaeSJed Brown 399bcb2dfaeSJed BrownBackends available in this release: 400bcb2dfaeSJed Brown 40168e843eeSJed Brown| CEED resource (`-ceed`) | Backend | 40268e843eeSJed Brown|-------------------------|-----------------------------------------------------| 40368e843eeSJed Brown| `/cpu/self/blocked` | Blocked reference implementation | 40468e843eeSJed Brown| `/cpu/self/ref` | Serial reference implementation | 40568e843eeSJed Brown| `/cpu/self/tmpl` | Backend template, defaults to `/cpu/self/blocked` | 40668e843eeSJed Brown| `/cpu/occa` | Serial OCCA kernels | 40768e843eeSJed Brown| `/gpu/occa` | CUDA OCCA kernels | 40868e843eeSJed Brown| `/omp/occa` | OpenMP OCCA kernels | 40968e843eeSJed Brown| `/ocl/occa` | OpenCL OCCA kernels | 41068e843eeSJed Brown| `/gpu/magma` | CUDA MAGMA kernels | 411bcb2dfaeSJed Brown 412bcb2dfaeSJed BrownExamples available in this release: 413bcb2dfaeSJed Brown 41468e843eeSJed Brown:::{list-table} 41568e843eeSJed Brown:header-rows: 1 41668e843eeSJed Brown:widths: auto 41768e843eeSJed Brown* - User code 41868e843eeSJed Brown - Example 41968e843eeSJed Brown* - `ceed` 42068e843eeSJed Brown - * ex1 (volume) 42168e843eeSJed Brown* - `mfem` 42268e843eeSJed Brown - * BP1 (scalar mass operator) 42368e843eeSJed Brown * BP3 (scalar Laplace operator) 42468e843eeSJed Brown* - `petsc` 42568e843eeSJed Brown - * BP1 (scalar mass operator) 42668e843eeSJed Brown * BP3 (scalar Laplace operator) 42768e843eeSJed Brown* - `nek5000` 42868e843eeSJed Brown - * BP1 (scalar mass operator) 42968e843eeSJed Brown * BP3 (scalar Laplace operator) 43068e843eeSJed Brown::: 431bcb2dfaeSJed Brown 432bcb2dfaeSJed Brown(v0-21)= 433bcb2dfaeSJed Brown 434bcb2dfaeSJed Brown## v0.21 (Sep 30, 2018) 435bcb2dfaeSJed Brown 436bcb2dfaeSJed BrownA MAGMA backend (which relies upon the 437bcb2dfaeSJed Brown[MAGMA](https://bitbucket.org/icl/magma) package) was integrated in libCEED for this 438bcb2dfaeSJed Brownrelease. This initial integration set up the framework of using MAGMA and provided the 439bcb2dfaeSJed BrownlibCEED functionality through MAGMA kernels as one of libCEED’s computational backends. 440bcb2dfaeSJed BrownAs any other backend, the MAGMA backend provides extended basic data structures for 441bcb2dfaeSJed Brown{ref}`CeedVector`, {ref}`CeedElemRestriction`, and {ref}`CeedOperator`, and implements 442bcb2dfaeSJed Brownthe fundamental CEED building blocks to work with the new data structures. 443bcb2dfaeSJed BrownIn general, the MAGMA-specific data structures keep the libCEED pointers to CPU data 444bcb2dfaeSJed Brownbut also add corresponding device (e.g., GPU) pointers to the data. Coherency is handled 445bcb2dfaeSJed Browninternally, and thus seamlessly to the user, through the functions/methods that are 446bcb2dfaeSJed Brownprovided to support them. 447bcb2dfaeSJed Brown 448bcb2dfaeSJed BrownBackends available in this release: 449bcb2dfaeSJed Brown 45068e843eeSJed Brown| CEED resource (`-ceed`) | Backend | 45168e843eeSJed Brown|-------------------------|---------------------------------| 45268e843eeSJed Brown| `/cpu/self` | Serial reference implementation | 45368e843eeSJed Brown| `/cpu/occa` | Serial OCCA kernels | 45468e843eeSJed Brown| `/gpu/occa` | CUDA OCCA kernels | 45568e843eeSJed Brown| `/omp/occa` | OpenMP OCCA kernels | 45668e843eeSJed Brown| `/ocl/occa` | OpenCL OCCA kernels | 45768e843eeSJed Brown| `/gpu/magma` | CUDA MAGMA kernels | 458bcb2dfaeSJed Brown 459bcb2dfaeSJed BrownExamples available in this release: 460bcb2dfaeSJed Brown 46168e843eeSJed Brown:::{list-table} 46268e843eeSJed Brown:header-rows: 1 46368e843eeSJed Brown:widths: auto 46468e843eeSJed Brown* - User code 46568e843eeSJed Brown - Example 46668e843eeSJed Brown* - `ceed` 46768e843eeSJed Brown - * ex1 (volume) 46868e843eeSJed Brown* - `mfem` 46968e843eeSJed Brown - * BP1 (scalar mass operator) 47068e843eeSJed Brown * BP3 (scalar Laplace operator) 47168e843eeSJed Brown* - `petsc` 47268e843eeSJed Brown - * BP1 (scalar mass operator) 47368e843eeSJed Brown* - `nek5000` 47468e843eeSJed Brown - * BP1 (scalar mass operator) 47568e843eeSJed Brown::: 476bcb2dfaeSJed Brown 477bcb2dfaeSJed Brown(v0-2)= 478bcb2dfaeSJed Brown 479bcb2dfaeSJed Brown## v0.2 (Mar 30, 2018) 480bcb2dfaeSJed Brown 481bcb2dfaeSJed BrownlibCEED was made publicly available the first full CEED software distribution, release 482bcb2dfaeSJed BrownCEED 1.0. The distribution was made available using the Spack package manager to provide 483bcb2dfaeSJed Browna common, easy-to-use build environment, where the user can build the CEED distribution 484bcb2dfaeSJed Brownwith all dependencies. This release included a new Fortran interface for the library. 485bcb2dfaeSJed BrownThis release also contained major improvements in the OCCA backend (including a new 486bcb2dfaeSJed Brown`/ocl/occa` backend) and new examples. The standalone libCEED example was modified to 487bcb2dfaeSJed Browncompute the volume volume of a given mesh (in 1D, 2D, or 3D) and placed in an 488bcb2dfaeSJed Brown`examples/ceed` subfolder. A new `mfem` example to perform BP3 (with the application 489bcb2dfaeSJed Brownof the Laplace operator) was also added to this release. 490bcb2dfaeSJed Brown 491bcb2dfaeSJed BrownBackends available in this release: 492bcb2dfaeSJed Brown 49368e843eeSJed Brown| CEED resource (`-ceed`) | Backend | 49468e843eeSJed Brown|-------------------------|---------------------------------| 49568e843eeSJed Brown| `/cpu/self` | Serial reference implementation | 49668e843eeSJed Brown| `/cpu/occa` | Serial OCCA kernels | 49768e843eeSJed Brown| `/gpu/occa` | CUDA OCCA kernels | 49868e843eeSJed Brown| `/omp/occa` | OpenMP OCCA kernels | 49968e843eeSJed Brown| `/ocl/occa` | OpenCL OCCA kernels | 500bcb2dfaeSJed Brown 501bcb2dfaeSJed BrownExamples available in this release: 502bcb2dfaeSJed Brown 50368e843eeSJed Brown:::{list-table} 50468e843eeSJed Brown:header-rows: 1 50568e843eeSJed Brown:widths: auto 50668e843eeSJed Brown* - User code 50768e843eeSJed Brown - Example 50868e843eeSJed Brown* - `ceed` 50968e843eeSJed Brown - * ex1 (volume) 51068e843eeSJed Brown* - `mfem` 51168e843eeSJed Brown - * BP1 (scalar mass operator) 51268e843eeSJed Brown * BP3 (scalar Laplace operator) 51368e843eeSJed Brown* - `petsc` 51468e843eeSJed Brown - * BP1 (scalar mass operator) 51568e843eeSJed Brown* - `nek5000` 51668e843eeSJed Brown - * BP1 (scalar mass operator) 51768e843eeSJed Brown::: 518bcb2dfaeSJed Brown 519bcb2dfaeSJed Brown(v0-1)= 520bcb2dfaeSJed Brown 521bcb2dfaeSJed Brown## v0.1 (Jan 3, 2018) 522bcb2dfaeSJed Brown 523bcb2dfaeSJed BrownInitial low-level API of the CEED project. The low-level API provides a set of Finite 524bcb2dfaeSJed BrownElements kernels and components for writing new low-level kernels. Examples include: 525bcb2dfaeSJed Brownvector and sparse linear algebra, element matrix assembly over a batch of elements, 526bcb2dfaeSJed Brownpartial assembly and action for efficient high-order operators like mass, diffusion, 527bcb2dfaeSJed Brownadvection, etc. The main goal of the low-level API is to establish the basis for the 528bcb2dfaeSJed Brownhigh-level API. Also, identifying such low-level kernels and providing a reference 529bcb2dfaeSJed Brownimplementation for them serves as the basis for specialized backend implementations. 530bcb2dfaeSJed BrownThis release contained several backends: `/cpu/self`, and backends which rely upon the 531bcb2dfaeSJed Brown[OCCA](http://github.com/libocca/occa) package, such as `/cpu/occa`, 532bcb2dfaeSJed Brown`/gpu/occa`, and `/omp/occa`. 533bcb2dfaeSJed BrownIt also included several examples, in the `examples` folder: 534bcb2dfaeSJed BrownA standalone code that shows the usage of libCEED (with no external 535bcb2dfaeSJed Browndependencies) to apply the Laplace operator, `ex1`; an `mfem` example to perform BP1 536bcb2dfaeSJed Brown(with the application of the mass operator); and a `petsc` example to perform BP1 537bcb2dfaeSJed Brown(with the application of the mass operator). 538bcb2dfaeSJed Brown 539bcb2dfaeSJed BrownBackends available in this release: 540bcb2dfaeSJed Brown 54168e843eeSJed Brown| CEED resource (`-ceed`) | Backend | 54268e843eeSJed Brown|-------------------------|---------------------------------| 54368e843eeSJed Brown| `/cpu/self` | Serial reference implementation | 54468e843eeSJed Brown| `/cpu/occa` | Serial OCCA kernels | 54568e843eeSJed Brown| `/gpu/occa` | CUDA OCCA kernels | 54668e843eeSJed Brown| `/omp/occa` | OpenMP OCCA kernels | 547bcb2dfaeSJed Brown 548bcb2dfaeSJed BrownExamples available in this release: 549bcb2dfaeSJed Brown 550bcb2dfaeSJed Brown| User code | Example | 55168e843eeSJed Brown|-----------------------|-----------------------------------| 55268e843eeSJed Brown| `ceed` | ex1 (scalar Laplace operator) | 55368e843eeSJed Brown| `mfem` | BP1 (scalar mass operator) | 55468e843eeSJed Brown| `petsc` | BP1 (scalar mass operator) | 555bcb2dfaeSJed Brown``` 556