Universal Numbers Library C++ API
sw::universal -- header-only custom arithmetic types (posit, cfloat, lns, fixpnt, dd/qd, and more)
Loading...
Searching...
No Matches
sw::universal::positRegime< nbits, es, bt > Class Template Reference

#include <posit_regime.hpp>

Public Member Functions

constexpr positRegime ()
constexpr positRegime (const positRegime &r)=default
constexpr positRegime (positRegime &&r)=default
constexpr positRegime & operator= (const positRegime &r)=default
constexpr positRegime & operator= (positRegime &&r)=default
constexpr void reset ()
constexpr std::size_t nrBits () const
constexpr int scale () const
constexpr int positRegime_k () const
constexpr int positRegime_run () const
long double value () const
constexpr bool iszero () const
constexpr blockbinary< nbits - 1, bt, BinaryNumberType::Unsigned > bits () const
constexpr void set (const blockbinary< nbits - 1, bt > &raw, unsigned nrOfRegimeBits)
constexpr void setzero ()
constexpr void setinf ()
constexpr int regime_size (int k) const
constexpr std::size_t assign (int scale)
constexpr unsigned assign_regime_pattern (int k)
bool increment ()

Friends

template<unsigned nnbits, unsigned ees, typename bbt>
std::ostream & operator<< (std::ostream &ostr, const positRegime< nnbits, ees, bbt > &r)
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator== (const positRegime< nnbits, ees, bbt > &lhs, const positRegime< nnbits, ees, bbt > &rhs)
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator!= (const positRegime< nnbits, ees, bbt > &lhs, const positRegime< nnbits, ees, bbt > &rhs)
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator< (const positRegime< nnbits, ees, bbt > &lhs, const positRegime< nnbits, ees, bbt > &rhs)
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator> (const positRegime< nnbits, ees, bbt > &lhs, const positRegime< nnbits, ees, bbt > &rhs)
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator<= (const positRegime< nnbits, ees, bbt > &lhs, const positRegime< nnbits, ees, bbt > &rhs)
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator>= (const positRegime< nnbits, ees, bbt > &lhs, const positRegime< nnbits, ees, bbt > &rhs)

Constructor & Destructor Documentation

◆ positRegime() [1/3]

template<unsigned nbits, unsigned es, typename bt>
sw::universal::positRegime< nbits, es, bt >::positRegime ( )
inlineconstexpr

◆ positRegime() [2/3]

template<unsigned nbits, unsigned es, typename bt>
sw::universal::positRegime< nbits, es, bt >::positRegime ( const positRegime< nbits, es, bt > & r)
constexprdefault

◆ positRegime() [3/3]

template<unsigned nbits, unsigned es, typename bt>
sw::universal::positRegime< nbits, es, bt >::positRegime ( positRegime< nbits, es, bt > && r)
constexprdefault

Member Function Documentation

◆ assign()

template<unsigned nbits, unsigned es, typename bt>
std::size_t sw::universal::positRegime< nbits, es, bt >::assign ( int scale)
inlineconstexpr

◆ assign_regime_pattern()

template<unsigned nbits, unsigned es, typename bt>
unsigned sw::universal::positRegime< nbits, es, bt >::assign_regime_pattern ( int k)
inlineconstexpr

◆ bits()

template<unsigned nbits, unsigned es, typename bt>
blockbinary< nbits - 1, bt, BinaryNumberType::Unsigned > sw::universal::positRegime< nbits, es, bt >::bits ( ) const
inlineconstexpr

◆ increment()

template<unsigned nbits, unsigned es, typename bt>
bool sw::universal::positRegime< nbits, es, bt >::increment ( )
inline

◆ iszero()

template<unsigned nbits, unsigned es, typename bt>
bool sw::universal::positRegime< nbits, es, bt >::iszero ( ) const
inlineconstexpr

◆ nrBits()

template<unsigned nbits, unsigned es, typename bt>
std::size_t sw::universal::positRegime< nbits, es, bt >::nrBits ( ) const
inlineconstexpr

◆ operator=() [1/2]

template<unsigned nbits, unsigned es, typename bt>
positRegime & sw::universal::positRegime< nbits, es, bt >::operator= ( const positRegime< nbits, es, bt > & r)
constexprdefault

◆ operator=() [2/2]

template<unsigned nbits, unsigned es, typename bt>
positRegime & sw::universal::positRegime< nbits, es, bt >::operator= ( positRegime< nbits, es, bt > && r)
constexprdefault

◆ positRegime_k()

template<unsigned nbits, unsigned es, typename bt>
int sw::universal::positRegime< nbits, es, bt >::positRegime_k ( ) const
inlineconstexpr

◆ positRegime_run()

template<unsigned nbits, unsigned es, typename bt>
int sw::universal::positRegime< nbits, es, bt >::positRegime_run ( ) const
inlineconstexpr

◆ regime_size()

template<unsigned nbits, unsigned es, typename bt>
int sw::universal::positRegime< nbits, es, bt >::regime_size ( int k) const
inlineconstexpr

◆ reset()

template<unsigned nbits, unsigned es, typename bt>
void sw::universal::positRegime< nbits, es, bt >::reset ( )
inlineconstexpr

◆ scale()

template<unsigned nbits, unsigned es, typename bt>
int sw::universal::positRegime< nbits, es, bt >::scale ( ) const
inlineconstexpr

◆ set()

template<unsigned nbits, unsigned es, typename bt>
void sw::universal::positRegime< nbits, es, bt >::set ( const blockbinary< nbits - 1, bt > & raw,
unsigned nrOfRegimeBits )
inlineconstexpr

◆ setinf()

template<unsigned nbits, unsigned es, typename bt>
void sw::universal::positRegime< nbits, es, bt >::setinf ( )
inlineconstexpr

◆ setzero()

template<unsigned nbits, unsigned es, typename bt>
void sw::universal::positRegime< nbits, es, bt >::setzero ( )
inlineconstexpr

◆ value()

template<unsigned nbits, unsigned es, typename bt>
long double sw::universal::positRegime< nbits, es, bt >::value ( ) const
inline

◆ operator!=

template<unsigned nbits, unsigned es, typename bt>
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator!= ( const positRegime< nnbits, ees, bbt > & lhs,
const positRegime< nnbits, ees, bbt > & rhs )
friend

◆ operator<

template<unsigned nbits, unsigned es, typename bt>
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator< ( const positRegime< nnbits, ees, bbt > & lhs,
const positRegime< nnbits, ees, bbt > & rhs )
friend

◆ operator<<

template<unsigned nbits, unsigned es, typename bt>
template<unsigned nnbits, unsigned ees, typename bbt>
std::ostream & operator<< ( std::ostream & ostr,
const positRegime< nnbits, ees, bbt > & r )
friend

◆ operator<=

template<unsigned nbits, unsigned es, typename bt>
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator<= ( const positRegime< nnbits, ees, bbt > & lhs,
const positRegime< nnbits, ees, bbt > & rhs )
friend

◆ operator==

template<unsigned nbits, unsigned es, typename bt>
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator== ( const positRegime< nnbits, ees, bbt > & lhs,
const positRegime< nnbits, ees, bbt > & rhs )
friend

◆ operator>

template<unsigned nbits, unsigned es, typename bt>
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator> ( const positRegime< nnbits, ees, bbt > & lhs,
const positRegime< nnbits, ees, bbt > & rhs )
friend

◆ operator>=

template<unsigned nbits, unsigned es, typename bt>
template<unsigned nnbits, unsigned ees, typename bbt>
bool operator>= ( const positRegime< nnbits, ees, bbt > & lhs,
const positRegime< nnbits, ees, bbt > & rhs )
friend

The documentation for this class was generated from the following file:
  • /home/runner/work/universal/universal/include/sw/universal/number/posit/posit_regime.hpp