47#ifndef GPR_LINALG_BACKEND_INTERFACE_H_
48#define GPR_LINALG_BACKEND_INTERFACE_H_
94 return "host-threads";
119 return "serial-equal";
121 return "grid-invariant";
123 return "unconstrained";
132 return static_cast<int>(provided) >=
static_cast<int>(required);
143 [[nodiscard]]
constexpr int total() const noexcept
147 [[nodiscard]]
constexpr bool fits(
int cpu_share)
const noexcept
161 [[nodiscard]]
constexpr int ranks() const noexcept
193template <
class Backend>
200 static constexpr const char*
name =
"eigen";
213 static constexpr const char*
name =
"cholmod";
227 static constexpr const char*
name =
"stdpar";
241 static constexpr const char*
name =
"cusolver";
258 static constexpr const char*
name =
"scalapack";
272 static constexpr const char*
name =
"slate";
324 int cpu_share) const noexcept = 0;
340 std::vector<
double>& eigenvalues) = 0;
virtual ~DistributedKernelProvider()=default
virtual bool rank_block_cholesky_append_lower(TileView a, int n, int cached_n)=0
virtual bool trsm_left_lower(ConstTileView l, int n, TileView b, int nrhs, bool transpose)=0
Solve L X = B (or L^T X = B when transpose) in place on b.
virtual bool potri_lower(TileView a, int n)=0
virtual ThreadBudget threadBudget(int cpu_share) const noexcept=0
Threads this provider spends on one rank, within cpu_share.
virtual bool gram_lower(TileView b, int rows, int columns, TileView product)=0
Lower triangle of B^T B for the rows x columns block b.
virtual bool heev_lower(TileView a, int n, TileView z, std::vector< double > &eigenvalues)=0
virtual ProviderTraits traits() const noexcept=0
virtual bool potrf_lower(TileView a, int n)=0
Cholesky factor of the order-n lower triangle, in place.
Dense and structured linear algebra behind the GP: Cholesky and eigen solvers, linear operators,...
constexpr bool satisfies(ArithmeticClass provided, ArithmeticClass required) noexcept
True when a provider of class provided meets the class required.
constexpr const char * executionKindName(ExecutionKind kind) noexcept
constexpr const char * memoryKindName(MemoryKind kind) noexcept
ExecutionKind
Which units run the operation.
constexpr const char * arithmeticClassName(ArithmeticClass cls) noexcept
constexpr bool hostAccessible(MemoryKind kind) noexcept
Gaussian-process regression, kernels, priors, and the searches that run on the surrogate.
Eigen::Matrix< double, EigenDynamic, EigenDynamic, EigenMatrixStorage > EigenMatrix
static constexpr ArithmeticClass arithmetic
static constexpr bool retains_factor
static constexpr const char * name
static constexpr bool distributed
Eigen::VectorXd vector_type
static constexpr bool resident
static constexpr MemoryKind memory
static constexpr ExecutionKind execution
static constexpr ArithmeticClass arithmetic
static constexpr bool distributed
static constexpr const char * name
static constexpr bool resident
static constexpr MemoryKind memory
Eigen::VectorXd vector_type
static constexpr ExecutionKind execution
static constexpr bool retains_factor
static constexpr ExecutionKind execution
static constexpr bool resident
static constexpr bool retains_factor
Eigen::VectorXd vector_type
static constexpr bool distributed
static constexpr const char * name
static constexpr MemoryKind memory
static constexpr ArithmeticClass arithmetic
static constexpr ExecutionKind execution
Eigen::VectorXd vector_type
static constexpr bool distributed
static constexpr bool resident
static constexpr bool retains_factor
static constexpr const char * name
static constexpr ArithmeticClass arithmetic
static constexpr MemoryKind memory
static constexpr const char * name
static constexpr bool distributed
static constexpr bool resident
static constexpr bool retains_factor
static constexpr ExecutionKind execution
static constexpr MemoryKind memory
static constexpr ArithmeticClass arithmetic
Eigen::VectorXd vector_type
static constexpr MemoryKind memory
static constexpr bool retains_factor
Eigen::VectorXd vector_type
static constexpr const char * name
static constexpr ExecutionKind execution
static constexpr ArithmeticClass arithmetic
static constexpr bool resident
static constexpr bool distributed
constexpr int ranks() const noexcept
Description of a distributed kernel provider.
bool resident
Operands in memory are consumed without staging through host.
ArithmeticClass arithmetic
constexpr int total() const noexcept
constexpr bool fits(int cpu_share) const noexcept