Contents

namespace

SushiBLAS::Core

Declared in
include/SushiBLAS/core/blas_types.hpp

Contains

Enumerations

enum class Transpose

Selects op(X) for a matrix operand.

See also

include/SushiBLAS/core/README.md

NO_TRANS

op(X) = X.

TRANS

op(X) = X^T.

CONJ_TRANS

op(X) = X^H, which is X^T for a real element type.

enum class Uplo

Selects the triangle of a symmetric, Hermitian or triangular matrix.

See also

include/SushiBLAS/core/README.md

UPPER

The triangle on and above the diagonal.

LOWER

The triangle on and below the diagonal.

enum class Diag

Selects whether a triangular matrix has a unit diagonal.

See also

include/SushiBLAS/core/README.md

NON_UNIT

The diagonal is read from the matrix.

UNIT

The diagonal is taken as all ones and never read.

enum class Side

Selects the side a triangular matrix stands on.

See also

include/SushiBLAS/core/README.md

LEFT

op(A) * X.

RIGHT

X * op(A).

enum class Layout

Memory layout strategies.

ROW_MAJOR
COLUMN_MAJOR
enum class DataType

Enumerates the element types a tensor can hold.

See also

include/SushiBLAS/core/README.md

HALF
FLOAT32
FLOAT64
COMPLEX32
COMPLEX64
INT32
INT64
enum class LogType

Logging levels to filter messages.

OFF

Logging is disabled.

ERR

Only error messages.

WARN

Warnings and errors.

INFO

Info, warnings and errors.

DEBUG

All messages including debug.

Variables

constexpr size_t MAX_TENSOR_RANK = 6

Maximum number of supported tensor ranks.

constexpr LogType ACTIVE_LOG_LEVEL = LogType::SB_ACTIVE_LOG_LEVEL

The level messages are compiled in at, from SB_ACTIVE_LOG_LEVEL.

Every SB_LOG_* macro tests against this in an if constexpr, so anything above the level costs nothing at all - not the formatting, not the source_location, not the call.

template <typename T>
constexpr bool is_complex_v = is_complex<T>::value

Convenience variable template for is_complex.

Template parameters

T

The type to inspect.

Functions

constexpr bool is_valid(Transpose value) noexcept

Returns whether value is an enumerator of Transpose.

constexpr bool is_valid(Uplo value) noexcept

Returns whether value is an enumerator of Uplo.

constexpr bool is_valid(Diag value) noexcept

Returns whether value is an enumerator of Diag.

constexpr bool is_valid(Side value) noexcept

Returns whether value is an enumerator of Side.

constexpr bool is_transposed(Transpose value) noexcept

Returns whether op(X) swaps the rows and columns of X.

constexpr bool is_conjugated(Transpose value) noexcept

Returns whether op(X) conjugates the elements of a complex X.

constexpr const char * to_string(Transpose value) noexcept

Returns the name of a Transpose, or "UNKNOWN" outside the enumeration.

constexpr const char * to_string(Uplo value) noexcept

Returns the name of a Uplo, or "UNKNOWN" outside the enumeration.

constexpr const char * to_string(Diag value) noexcept

Returns the name of a Diag, or "UNKNOWN" outside the enumeration.

constexpr const char * to_string(Side value) noexcept

Returns the name of a Side, or "UNKNOWN" outside the enumeration.

constexpr const char * to_string(DataType dtype)

Returns the name of a DataType for diagnostics, or "UNKNOWN" outside the enumeration.

See also

include/SushiBLAS/core/README.md

constexpr bool is_complex_dtype(DataType dtype)

Whether a DataType names one of the complex element types.

Parameters

dtype

The data type to classify.

Returns

True for COMPLEX32 / COMPLEX64, false otherwise.

constexpr bool is_integer_dtype(DataType dtype)

Returns whether a DataType is INT32 or INT64.

See also

include/SushiBLAS/core/README.md

constexpr bool is_real_dtype(DataType dtype)

Whether a DataType names one of the real floating-point element types.

Parameters

dtype

The data type to classify.

Returns

True for HALF / FLOAT32 / FLOAT64, false otherwise.

constexpr size_t bytes_per_element(DataType dtype)

Returns the size in bytes of one element of a DataType.

See also

include/SushiBLAS/core/README.md

template <typename... Args>
std::string format(std::string_view fmt, const Args &... args)

Substitutes the arguments into the replacement fields of fmt, left to right.

See also

include/SushiBLAS/core/README.md