MLIR 22.0.0git
ArithmeticUtils.h File Reference
#include <cassert>
#include <cinttypes>
#include <limits>
#include <type_traits>

Go to the source code of this file.

Namespaces

namespace  mlir
 Include the generated interface declarations.
namespace  mlir::sparse_tensor
namespace  mlir::sparse_tensor::detail

Functions

template<typename T, typename U>
constexpr bool mlir::sparse_tensor::detail::safelyEQ (T t, U u) noexcept
template<typename T, typename U>
constexpr bool mlir::sparse_tensor::detail::safelyNE (T t, U u) noexcept
template<typename T, typename U>
constexpr bool mlir::sparse_tensor::detail::safelyLT (T t, U u) noexcept
template<typename T, typename U>
constexpr bool mlir::sparse_tensor::detail::safelyGT (T t, U u) noexcept
template<typename T, typename U>
constexpr bool mlir::sparse_tensor::detail::safelyLE (T t, U u) noexcept
template<typename T, typename U>
constexpr bool mlir::sparse_tensor::detail::safelyGE (T t, U u) noexcept
template<typename To, typename From>
To mlir::sparse_tensor::detail::checkOverflowCast (From x)
 A version of static_cast<To> which checks for overflow/underflow.
uint64_t mlir::sparse_tensor::detail::checkedMul (uint64_t lhs, uint64_t rhs)
 A version of operator* on uint64_t which guards against overflows (when assertions are enabled).