|
Mallard 0.8.0
Unstructured, GPU accelerated, high-order finite volume CFD solver
Mallard website |
One thread does all the work of a cell. More...
#include <lanes.h>
Public Member Functions | |
| template<typename F > | |
| KOKKOS_INLINE_FUNCTION void | for_each (const uint32_t n, const F &f) const |
| KOKKOS_INLINE_FUNCTION void | sync () const |
| template<typename F > | |
| KOKKOS_INLINE_FUNCTION void | single (const F &f) const |
| template<typename F > | |
| KOKKOS_INLINE_FUNCTION double | sum (const uint32_t n, const F &f) const |
| sum_i f(i), in order. | |
| template<typename F > | |
| KOKKOS_INLINE_FUNCTION double | argmax_abs (const uint32_t first, const uint32_t n, const F &f, uint32_t &index) const |
| The largest |f(i)| for first <= i < n and the first i that has it. | |
Static Public Attributes | |
| static constexpr uint32_t | lanes = 1 |
| static constexpr bool | column_major = false |
| static constexpr bool | parallel = false |
One thread does all the work of a cell.
The interface every cell kernel uses: for_each(n, f) calls f(i) for 0 <= i < n, possibly concurrently; sync() makes the writes of a for_each visible to all lanes; single(f) runs f once; sum and argmax_abs reduce in an order that depends only on the lane count. column_major selects the layout of dense matrices that suits the lanes' access.
|
inline |
The largest |f(i)| for first <= i < n and the first i that has it.
|
inline |
|
inline |
|
inline |
sum_i f(i), in order.
|
inline |