GCC Middle and Back End API Reference
wide_int_ref_storage< SE, HDP > Class Template Reference

#include <wide-int.h>

Inheritance diagram for wide_int_ref_storage< SE, HDP >:
Collaboration diagram for wide_int_ref_storage< SE, HDP >:

Public Member Functions

 wide_int_ref_storage ()
 
 wide_int_ref_storage (const wi::storage_ref &)
 
template<typename T >
 wide_int_ref_storage (const T &)
 
template<typename T >
 wide_int_ref_storage (const T &, unsigned int)
 
unsigned int get_len () const
 
unsigned int get_precision () const
 
const HOST_WIDE_INT * get_val () const
 

Data Fields

const HOST_WIDE_INT * val
 
unsigned int len
 
unsigned int precision
 

Private Attributes

HOST_WIDE_INT scratch [2]
 

Detailed Description

template<bool SE, bool HDP>
class wide_int_ref_storage< SE, HDP >
wi::storage_ref can be a reference to a primitive type,
so this is the conservatively-correct setting.   
Provide the storage for a wide_int_ref.  This acts like a read-only
wide_int, with the optimization that VAL is normally a pointer to
another integer's storage, so that no array copy is needed.   

Constructor & Destructor Documentation

◆ wide_int_ref_storage() [1/4]

template<bool SE, bool HDP>
wide_int_ref_storage< SE, HDP >::wide_int_ref_storage ( )
inline

◆ wide_int_ref_storage() [2/4]

template<bool SE, bool HDP>
wide_int_ref_storage< SE, HDP >::wide_int_ref_storage ( const wi::storage_ref & x)
inline
Create a reference from an existing reference.   

◆ wide_int_ref_storage() [3/4]

template<bool SE, bool HDP>
template<typename T >
wide_int_ref_storage< SE, HDP >::wide_int_ref_storage ( const T & x)
inline
Create a reference to integer X in its natural precision.  Note
that the natural precision is host-dependent for primitive
types.   

◆ wide_int_ref_storage() [4/4]

template<bool SE, bool HDP>
template<typename T >
wide_int_ref_storage< SE, HDP >::wide_int_ref_storage ( const T & x,
unsigned int precision )
inline
Create a reference to integer X in precision PRECISION.   

Member Function Documentation

◆ get_len()

unsigned int wi::storage_ref::get_len ( ) const
inlineinherited

◆ get_precision()

unsigned int wi::storage_ref::get_precision ( ) const
inlineinherited

References wi::precision.

◆ get_val()

const HOST_WIDE_INT * wi::storage_ref::get_val ( ) const
inlineinherited

Field Documentation

◆ len

unsigned int wi::storage_ref::len
inherited

◆ precision

unsigned int wi::storage_ref::precision
inherited

◆ scratch

template<bool SE, bool HDP>
HOST_WIDE_INT wide_int_ref_storage< SE, HDP >::scratch[2]
private

◆ val

const HOST_WIDE_INT* wi::storage_ref::val
inherited

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