gem5  v20.1.0.0
Public Member Functions | Public Attributes | Protected Member Functions | Static Protected Member Functions | Private Attributes | Friends | List of all members
sc_dt::sc_fxval_fast Class Reference

#include <sc_fxval.hh>

Public Member Functions

 sc_fxval_fast (sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (int, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (unsigned int, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (long, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (unsigned long, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (float, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (double, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (const char *, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (const sc_fxval &, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (const sc_fxval_fast &, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (const sc_fxnum &, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (const sc_fxnum_fast &, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (int64, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (uint64, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (const sc_int_base &, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (const sc_uint_base &, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (const sc_signed &, sc_fxval_fast_observer *=0)
 
 sc_fxval_fast (const sc_unsigned &, sc_fxval_fast_observer *=0)
 
 ~sc_fxval_fast ()
 
double get_val () const
 
void set_val (double)
 
const sc_fxval_fast operator- () const
 
const sc_fxval_fastoperator+ () const
 
 DECL_BIN_OP_T (/, int64) DECL_BIN_OP_T(/
 
uint64 DECL_BIN_OP_T (/, const sc_int_base &) DECL_BIN_OP_T(/
 
uint64 const sc_uint_baseDECL_BIN_OP_T (/, const sc_signed &) friend const sc_fxval_fast operator<<(const sc_fxval_fast &
 
const sc_fxval_fast operator++ (int)
 
const sc_fxval_fast operator-- (int)
 
sc_fxval_fastoperator++ ()
 
sc_fxval_fastoperator-- ()
 
 operator double () const
 
short to_short () const
 
unsigned short to_ushort () const
 
int to_int () const
 
unsigned int to_uint () const
 
long to_long () const
 
unsigned long to_ulong () const
 
int64 to_int64 () const
 
uint64 to_uint64 () const
 
float to_float () const
 
double to_double () const
 
const std::string to_string () const
 
const std::string to_string (sc_numrep) const
 
const std::string to_string (sc_numrep, bool) const
 
const std::string to_string (sc_fmt) const
 
const std::string to_string (sc_numrep, sc_fmt) const
 
const std::string to_string (sc_numrep, bool, sc_fmt) const
 
const std::string to_dec () const
 
const std::string to_bin () const
 
const std::string to_oct () const
 
const std::string to_hex () const
 
bool is_neg () const
 
bool is_zero () const
 
bool is_nan () const
 
bool is_inf () const
 
bool is_normal () const
 
bool rounding_flag () const
 
void print (::std::ostream &=::std::cout) const
 
void scan (::std::istream &=::std::cin)
 
void dump (::std::ostream &=::std::cout) const
 
bool get_bit (int) const
 

Public Attributes

uint64 const sc_uint_base int
 

Protected Member Functions

sc_fxval_fast_observerobserver () const
 
sc_fxval_fast_observerlock_observer () const
 
void unlock_observer (sc_fxval_fast_observer *) const
 

Static Protected Member Functions

static double from_string (const char *)
 

Private Attributes

double m_val
 
sc_fxval_fast_observerm_observer
 

Friends

class sc_fxnum_fast
 
void neg (sc_fxval_fast &, const sc_fxval_fast &)
 
const friend sc_fxval_fast operator/ (const sc_fxval_fast &, const sc_fxval_fast &)
 
const friend sc_fxval_fast operator>> (const sc_fxval_fast &, int)
 
void lshift (sc_fxval_fast &, const sc_fxval_fast &, int)
 
void rshift (sc_fxval_fast &, const sc_fxval_fast &, int)
 

Detailed Description

Definition at line 376 of file sc_fxval.hh.

Constructor & Destructor Documentation

◆ sc_fxval_fast() [1/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( sc_fxval_fast_observer observer_ = 0)
inlineexplicit

◆ sc_fxval_fast() [2/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( int  ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [3/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( unsigned int  ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [4/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( long  ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [5/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( unsigned long  ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [6/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( float  ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [7/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( double  ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [8/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( const char *  ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [9/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( const sc_fxval ,
sc_fxval_fast_observer = 0 
)

◆ sc_fxval_fast() [10/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( const sc_fxval_fast a,
sc_fxval_fast_observer observer_ = 0 
)
inline

◆ sc_fxval_fast() [11/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( const sc_fxnum a,
sc_fxval_fast_observer observer_ = 0 
)
inline

◆ sc_fxval_fast() [12/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( const sc_fxnum_fast a,
sc_fxval_fast_observer observer_ = 0 
)
inline

◆ sc_fxval_fast() [13/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( int64  ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [14/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( uint64  ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [15/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( const sc_int_base ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [16/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( const sc_uint_base ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [17/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( const sc_signed ,
sc_fxval_fast_observer = 0 
)
explicit

◆ sc_fxval_fast() [18/18]

sc_dt::sc_fxval_fast::sc_fxval_fast ( const sc_unsigned ,
sc_fxval_fast_observer = 0 
)
explicit

◆ ~sc_fxval_fast()

sc_dt::sc_fxval_fast::~sc_fxval_fast ( )
inline

Definition at line 1370 of file sc_fxval.hh.

References SC_FXVAL_FAST_OBSERVER_DESTRUCT_.

Member Function Documentation

◆ DECL_BIN_OP_T() [1/3]

uint64 sc_dt::sc_fxval_fast::DECL_BIN_OP_T ( ,
const sc_int_base  
)

◆ DECL_BIN_OP_T() [2/3]

uint64 const sc_uint_base& sc_dt::sc_fxval_fast::DECL_BIN_OP_T ( ,
const sc_signed  
) const &

◆ DECL_BIN_OP_T() [3/3]

sc_dt::sc_fxval_fast::DECL_BIN_OP_T ( ,
int64   
)

◆ dump()

void sc_dt::sc_fxval_fast::dump ( ::std::ostream &  os = ::std::cout) const

Definition at line 582 of file sc_fxval.cc.

◆ from_string()

double sc_dt::sc_fxval_fast::from_string ( const char *  s)
staticprotected

Definition at line 659 of file sc_fxval.cc.

◆ get_bit()

bool sc_dt::sc_fxval_fast::get_bit ( int  i) const

Definition at line 600 of file sc_fxval.cc.

◆ get_val()

double sc_dt::sc_fxval_fast::get_val ( ) const
inline

Definition at line 1377 of file sc_fxval.hh.

References m_val, and SC_FXVAL_FAST_OBSERVER_READ_.

◆ is_inf()

bool sc_dt::sc_fxval_fast::is_inf ( ) const
inline

Definition at line 1902 of file sc_fxval.hh.

References ArmISA::id, m_val, and SC_FXVAL_FAST_OBSERVER_READ_.

Referenced by print().

◆ is_nan()

bool sc_dt::sc_fxval_fast::is_nan ( ) const
inline

Definition at line 1894 of file sc_fxval.hh.

References ArmISA::id, m_val, and SC_FXVAL_FAST_OBSERVER_READ_.

Referenced by print().

◆ is_neg()

bool sc_dt::sc_fxval_fast::is_neg ( ) const
inline

Definition at line 1878 of file sc_fxval.hh.

References ArmISA::id, m_val, and SC_FXVAL_FAST_OBSERVER_READ_.

◆ is_normal()

bool sc_dt::sc_fxval_fast::is_normal ( ) const
inline

Definition at line 1910 of file sc_fxval.hh.

References ArmISA::id, is_zero(), m_val, and SC_FXVAL_FAST_OBSERVER_READ_.

Referenced by to_uint64().

◆ is_zero()

bool sc_dt::sc_fxval_fast::is_zero ( ) const
inline

Definition at line 1886 of file sc_fxval.hh.

References ArmISA::id, m_val, and SC_FXVAL_FAST_OBSERVER_READ_.

Referenced by is_normal(), and print().

◆ lock_observer()

sc_fxval_fast_observer * sc_dt::sc_fxval_fast::lock_observer ( ) const
protected

Definition at line 637 of file sc_fxval.cc.

◆ observer()

sc_fxval_fast_observer * sc_dt::sc_fxval_fast::observer ( ) const
inlineprotected

Definition at line 1309 of file sc_fxval.hh.

References sc_dt::sc_fxval::m_observer.

◆ operator double()

sc_dt::sc_fxval_fast::operator double ( ) const
inline

Definition at line 1783 of file sc_fxval.hh.

References m_val, and SC_FXVAL_FAST_OBSERVER_READ_.

◆ operator+()

const sc_fxval_fast & sc_dt::sc_fxval_fast::operator+ ( ) const
inline

Definition at line 1400 of file sc_fxval.hh.

◆ operator++() [1/2]

sc_fxval_fast & sc_dt::sc_fxval_fast::operator++ ( )
inline

Definition at line 1765 of file sc_fxval.hh.

References m_val, SC_FXVAL_FAST_OBSERVER_READ_, and SC_FXVAL_FAST_OBSERVER_WRITE_.

◆ operator++() [2/2]

const sc_fxval_fast sc_dt::sc_fxval_fast::operator++ ( int  )
inline

◆ operator-()

const sc_fxval_fast sc_dt::sc_fxval_fast::operator- ( ) const
inline

Definition at line 1393 of file sc_fxval.hh.

References m_val, sc_fxval_fast(), and SC_FXVAL_FAST_OBSERVER_READ_.

◆ operator--() [1/2]

sc_fxval_fast & sc_dt::sc_fxval_fast::operator-- ( )
inline

Definition at line 1774 of file sc_fxval.hh.

References m_val, SC_FXVAL_FAST_OBSERVER_READ_, and SC_FXVAL_FAST_OBSERVER_WRITE_.

◆ operator--() [2/2]

const sc_fxval_fast sc_dt::sc_fxval_fast::operator-- ( int  )
inline

◆ print()

void sc_dt::sc_fxval_fast::print ( ::std::ostream &  os = ::std::cout) const

Definition at line 568 of file sc_fxval.cc.

References ArmISA::id, is_inf(), is_nan(), is_zero(), and m_val.

◆ rounding_flag()

bool sc_dt::sc_fxval_fast::rounding_flag ( ) const
inline

Definition at line 1918 of file sc_fxval.hh.

◆ scan()

void sc_dt::sc_fxval_fast::scan ( ::std::istream &  is = ::std::cin)

Definition at line 574 of file sc_fxval.cc.

◆ set_val()

void sc_dt::sc_fxval_fast::set_val ( double  val_)
inline

Definition at line 1385 of file sc_fxval.hh.

References m_val, and SC_FXVAL_FAST_OBSERVER_WRITE_.

◆ to_bin()

const std::string sc_dt::sc_fxval_fast::to_bin ( ) const

Definition at line 547 of file sc_fxval.cc.

◆ to_dec()

const std::string sc_dt::sc_fxval_fast::to_dec ( ) const

Definition at line 541 of file sc_fxval.cc.

References MipsISA::is, and ArmISA::s.

◆ to_double()

double sc_dt::sc_fxval_fast::to_double ( ) const
inline

Definition at line 1870 of file sc_fxval.hh.

References m_val, and SC_FXVAL_FAST_OBSERVER_READ_.

◆ to_float()

float sc_dt::sc_fxval_fast::to_float ( ) const
inline

Definition at line 1863 of file sc_fxval.hh.

References m_val, and SC_FXVAL_FAST_OBSERVER_READ_.

◆ to_hex()

const std::string sc_dt::sc_fxval_fast::to_hex ( ) const

Definition at line 559 of file sc_fxval.cc.

◆ to_int()

int sc_dt::sc_fxval_fast::to_int ( ) const
inline

Definition at line 1812 of file sc_fxval.hh.

References to_uint64().

◆ to_int64()

int64 sc_dt::sc_fxval_fast::to_int64 ( ) const
inline

Definition at line 1805 of file sc_fxval.hh.

References to_uint64().

◆ to_long()

long sc_dt::sc_fxval_fast::to_long ( ) const
inline

Definition at line 1849 of file sc_fxval.hh.

References to_uint64().

◆ to_oct()

const std::string sc_dt::sc_fxval_fast::to_oct ( ) const

Definition at line 553 of file sc_fxval.cc.

◆ to_short()

short sc_dt::sc_fxval_fast::to_short ( ) const
inline

Definition at line 1791 of file sc_fxval.hh.

References to_uint64().

◆ to_string() [1/6]

const std::string sc_dt::sc_fxval_fast::to_string ( ) const

Definition at line 503 of file sc_fxval.cc.

References m_val, and sc_dt::to_string().

◆ to_string() [2/6]

const std::string sc_dt::sc_fxval_fast::to_string ( sc_fmt  fmt) const

Definition at line 522 of file sc_fxval.cc.

References m_val, sc_dt::SC_E, sc_dt::SC_OCT, and sc_dt::to_string().

◆ to_string() [3/6]

const std::string sc_dt::sc_fxval_fast::to_string ( sc_numrep  numrep) const

Definition at line 509 of file sc_fxval.cc.

References m_val, sc_dt::SC_DEC, sc_dt::SC_E, and sc_dt::to_string().

◆ to_string() [4/6]

const std::string sc_dt::sc_fxval_fast::to_string ( sc_numrep  numrep,
bool  w_prefix 
) const

Definition at line 515 of file sc_fxval.cc.

References m_val, sc_dt::SC_BIN, sc_dt::SC_E, and sc_dt::to_string().

◆ to_string() [5/6]

const std::string sc_dt::sc_fxval_fast::to_string ( sc_numrep  numrep,
bool  w_prefix,
sc_fmt  fmt 
) const

Definition at line 534 of file sc_fxval.cc.

References m_val, X86ISA::os, sc_dt::SC_DEC, sc_dt::SC_E, and sc_dt::to_string().

◆ to_string() [6/6]

const std::string sc_dt::sc_fxval_fast::to_string ( sc_numrep  numrep,
sc_fmt  fmt 
) const

Definition at line 528 of file sc_fxval.cc.

References m_val, sc_dt::SC_E, sc_dt::SC_HEX, and sc_dt::to_string().

◆ to_uint()

unsigned int sc_dt::sc_fxval_fast::to_uint ( ) const
inline

Definition at line 1819 of file sc_fxval.hh.

References to_uint64().

◆ to_uint64()

uint64 sc_dt::sc_fxval_fast::to_uint64 ( ) const
inline

Definition at line 1826 of file sc_fxval.hh.

References is_normal(), m_val, and sc_dt::UINT64_ONE.

Referenced by to_int(), to_int64(), to_long(), to_short(), to_uint(), to_ulong(), and to_ushort().

◆ to_ulong()

unsigned long sc_dt::sc_fxval_fast::to_ulong ( ) const
inline

Definition at line 1856 of file sc_fxval.hh.

References to_uint64().

◆ to_ushort()

unsigned short sc_dt::sc_fxval_fast::to_ushort ( ) const
inline

Definition at line 1798 of file sc_fxval.hh.

References to_uint64().

◆ unlock_observer()

void sc_dt::sc_fxval_fast::unlock_observer ( sc_fxval_fast_observer observer_) const
protected

Definition at line 646 of file sc_fxval.cc.

Friends And Related Function Documentation

◆ lshift

void lshift ( sc_fxval_fast c,
const sc_fxval_fast a,
int  b 
)
friend

Definition at line 1564 of file sc_fxval.hh.

◆ neg

void neg ( sc_fxval_fast c,
const sc_fxval_fast a 
)
friend

Definition at line 1408 of file sc_fxval.hh.

◆ operator/

const friend sc_fxval_fast operator/ ( const sc_fxval_fast a,
const sc_fxval_fast b 
)
friend

Definition at line 1464 of file sc_fxval.hh.

◆ operator>>

const friend sc_fxval_fast operator>> ( const sc_fxval_fast a,
int  b 
)
friend

Definition at line 1501 of file sc_fxval.hh.

◆ rshift

void rshift ( sc_fxval_fast c,
const sc_fxval_fast a,
int  b 
)
friend

Definition at line 1572 of file sc_fxval.hh.

◆ sc_fxnum_fast

friend class sc_fxnum_fast
friend

Definition at line 378 of file sc_fxval.hh.

Member Data Documentation

◆ int

uint64 const sc_uint_base sc_dt::sc_fxval_fast::int

Definition at line 469 of file sc_fxval.hh.

◆ m_observer

sc_fxval_fast_observer* sc_dt::sc_fxval_fast::m_observer
mutableprivate

Definition at line 645 of file sc_fxval.hh.

◆ m_val

double sc_dt::sc_fxval_fast::m_val
private

The documentation for this class was generated from the following files:

Generated on Wed Sep 30 2020 14:03:10 for gem5 by doxygen 1.8.17