L4Re - L4 Runtime Environment
|
Definition for a member (part) of a bit field. More...
Data Structures | |
class | Value |
Internal helper type. More... | |
class | Value_base |
Internal helper type. More... | |
class | Value_unshifted |
Internal helper type. More... | |
Public Types | |
enum | { Bits = MSB + 1 - LSB, Lsb = LSB, Msb = MSB } |
enum | Masks : T { Low_mask = ((T)~0ULL) >> (sizeof(T)*8 - Bits), Mask = Low_mask << Lsb } |
typedef Best_type< Bits >::Type | Bits_type |
Type to hold at least Bits bits. More... | |
typedef Best_type< Bits+Lsb >::Type | Shift_type |
Type to hold at least Bits + Lsb bits. More... | |
typedef Value< T & > | Ref |
Reference type to access the bits inside a raw bit field. More... | |
typedef Value< T const > | Val |
Value type to access the bits inside a raw bit field. More... | |
typedef Value_unshifted< T & > | Ref_unshifted |
Reference type to access the bits inside a raw bit field (in place). More... | |
typedef Value_unshifted< T const > | Val_unshifted |
Value type to access the bits inside a raw bit field (in place). More... | |
Static Public Member Functions | |
static Bits_type | get (Shift_type val) |
Get the bits out of val. More... | |
static T | get_unshifted (Shift_type val) |
Get the bits in place out of val. More... | |
static T | set_dirty (T dest, Shift_type val) |
Set the bits corresponding to val. More... | |
static T | set_unshifted_dirty (T dest, Shift_type val) |
Set the bits corresponding to val. More... | |
static T | set (T dest, Bits_type val) |
Set the bits corresponding to val. More... | |
static T | set_unshifted (T dest, Shift_type val) |
Set the bits corresponding to val. More... | |
static T | val_dirty (Shift_type val) |
Get the shifted bits for val. More... | |
static T | val (Bits_type val) |
Get the shifted bits for val. More... | |
static T | val_unshifted (Shift_type val) |
Get the shifted bits for val. More... | |
Definition for a member (part) of a bit field.
T | the underlying type of the bit field. |
LSB | the least significant bit of our bits. |
MSB | the mos significant bit if our bits. |
typedef Best_type<Bits>::Type cxx::Bitfield< T, LSB, MSB >::Bits_type |
typedef Value<T&> cxx::Bitfield< T, LSB, MSB >::Ref |
typedef Value_unshifted<T&> cxx::Bitfield< T, LSB, MSB >::Ref_unshifted |
typedef Best_type<Bits + Lsb>::Type cxx::Bitfield< T, LSB, MSB >::Shift_type |
typedef Value<T const> cxx::Bitfield< T, LSB, MSB >::Val |
typedef Value_unshifted<T const> cxx::Bitfield< T, LSB, MSB >::Val_unshifted |
anonymous enum |
enum cxx::Bitfield::Masks : T |
|
inlinestatic |
Get the bits out of val.
val | the raw value of the whole bit field. |
Definition at line 100 of file bitfield.
References cxx::Bitfield< T, LSB, MSB >::Low_mask, cxx::Bitfield< T, LSB, MSB >::Lsb, and cxx::Bitfield< T, LSB, MSB >::val().
|
inlinestatic |
Get the bits in place out of val.
val | the raw value of the whole bit field. |
This means other bits are masked out, however the result is not shifted to the right,
Definition at line 110 of file bitfield.
References cxx::Bitfield< T, LSB, MSB >::Mask.
|
inlinestatic |
Set the bits corresponding to val.
dest | the current value of the whole bit field. |
val | the value to set into the bits. |
Definition at line 146 of file bitfield.
References cxx::Bitfield< T, LSB, MSB >::Low_mask, cxx::Bitfield< T, LSB, MSB >::set_dirty(), and cxx::Bitfield< T, LSB, MSB >::val().
|
inlinestatic |
Set the bits corresponding to val.
dest | the current value of the whole bit field. |
val | the value to set into the bits. |
Definition at line 120 of file bitfield.
References cxx::Bitfield< T, LSB, MSB >::Lsb, and cxx::Bitfield< T, LSB, MSB >::Mask.
Referenced by cxx::Bitfield< T, LSB, MSB >::set().
|
inlinestatic |
Set the bits corresponding to val.
dest | the current value of the whole bit field. |
val | the value shifted Lsb bits to the left that shall be set into the bits. |
Definition at line 155 of file bitfield.
References cxx::Bitfield< T, LSB, MSB >::Mask, and cxx::Bitfield< T, LSB, MSB >::set_unshifted_dirty().
|
inlinestatic |
Set the bits corresponding to val.
dest | the current value of the whole bit field. |
val | the value shifted Lsb bits to the left that shall be set into the bits. |
Definition at line 135 of file bitfield.
References cxx::Bitfield< T, LSB, MSB >::Mask, and cxx::Bitfield< T, LSB, MSB >::val().
Referenced by cxx::Bitfield< T, LSB, MSB >::set_unshifted().
|
inlinestatic |
Get the shifted bits for val.
val | the value to set into the bits. |
Definition at line 170 of file bitfield.
References cxx::Bitfield< T, LSB, MSB >::Low_mask, and cxx::Bitfield< T, LSB, MSB >::val_dirty().
Referenced by cxx::Bitfield< T, LSB, MSB >::get(), cxx::Bitfield< T, LSB, MSB >::set(), and cxx::Bitfield< T, LSB, MSB >::set_unshifted_dirty().
|
inlinestatic |
Get the shifted bits for val.
val | the value to set into the bits. |
Definition at line 164 of file bitfield.
References cxx::Bitfield< T, LSB, MSB >::Lsb.
Referenced by cxx::Bitfield< T, LSB, MSB >::val().
|
inlinestatic |
Get the shifted bits for val.
val | the value shifted Lsb bits to the left that shall be set into the bits. |
Definition at line 177 of file bitfield.
References cxx::Bitfield< T, LSB, MSB >::Mask.