gem5 v24.0.0.0
Loading...
Searching...
No Matches
bitunion.hh File Reference
#include <functional>
#include <iostream>
#include <type_traits>
#include <typeinfo>
#include "base/bitfield.hh"
#include "base/compiler.hh"
#include "sim/serialize_handlers.hh"

Go to the source code of this file.

Classes

class  gem5::BitfieldTypeImpl< Base >
 
struct  gem5::BitfieldTypeImpl< Base >::TypeDeducer
 
struct  gem5::BitfieldTypeImpl< Base >::TypeDeducer::T< void(C::*)(Type1 &, Type2)>
 
struct  gem5::BitfieldTypeImpl< Base >::TypeDeducer::Wrapper
 
class  gem5::BitfieldType< Base >
 
class  gem5::BitfieldROType< Base >
 
class  gem5::BitfieldWOType< Base >
 
class  gem5::bitfield_backend::Unsigned< Storage, first, last >
 
class  gem5::bitfield_backend::Signed< Storage, first, last >
 
class  gem5::bitfield_backend::BitfieldTypes< Storage >
 
class  gem5::bitfield_backend::BitUnionOperators< Base >
 
struct  gem5::bitfield_backend::BitUnionBaseType< T >
 
struct  gem5::bitfield_backend::BitUnionBaseType< BitUnionType< T > >
 
struct  gem5::ParseParam< BitUnionType< T > >
 
struct  gem5::ShowParam< BitUnionType< T > >
 
struct  std::hash< gem5::BitUnionType< T > >
 

Namespaces

namespace  gem5
 Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.
 
namespace  gem5::bitfield_backend
 
namespace  std
 Overload hash function for BasicBlockRange type.
 

Macros

#define __BitUnion(type, name)
 
#define EndBitUnion(name)
 This closes off the class and union started by the above macro.
 
#define __SubBitUnion(name, fieldType, ...)
 
#define EndSubBitUnion(name)
 This closes off the union created above and gives it a name.
 
#define SubBitUnion(name, first, last)    __SubBitUnion(name, Bitfield, first, last)
 Regular bitfields These define macros for read/write regular bitfield based subbitfields.
 
#define SignedSubBitUnion(name, first, last)    __SubBitUnion(name, SignedBitfield, first, last)
 Regular bitfields These define macros for read/write regular bitfield based subbitfields.
 
#define BitUnion(type, name)   __BitUnion(type, name)
 Use this to define an arbitrary type overlayed with bitfields.
 
#define BitUnion64(name)   __BitUnion(uint64_t, name)
 Use this to define conveniently sized values overlayed with bitfields.
 
#define BitUnion32(name)   __BitUnion(uint32_t, name)
 
#define BitUnion16(name)   __BitUnion(uint16_t, name)
 
#define BitUnion8(name)   __BitUnion(uint8_t, name)
 

Typedefs

template<typename T >
using gem5::BitUnionType = bitfield_backend::BitUnionOperators<T>
 
template<typename T >
using gem5::BitUnionBaseType = typename bitfield_backend::BitUnionBaseType<T>::Type
 

Functions

template<typename T >
static std::ostream & gem5::bitfield_backend::bitfieldBackendPrinter (std::ostream &os, const T &t)
 
template<>
std::ostream & gem5::bitfield_backend::bitfieldBackendPrinter (std::ostream &os, const char &t)
 
template<>
std::ostream & gem5::bitfield_backend::bitfieldBackendPrinter (std::ostream &os, const unsigned char &t)
 
template<typename T >
std::ostream & gem5::operator<< (std::ostream &os, const BitUnionType< T > &bu)
 A default << operator which casts a bitunion to its underlying type and passes it to bitfield_backend::bitfieldBackendPrinter.
 

Macro Definition Documentation

◆ __BitUnion

#define __BitUnion ( type,
name )
Value:
class BitfieldUnderlyingClasses##name : \
{ \
protected: \
typedef type __StorageType; \
BitfieldUnderlyingClasses##name> >; \
BitfieldUnderlyingClasses##name>; \
public: \
union { \
type __storage;
const std::string & name()
Definition trace.cc:48

Definition at line 405 of file bitunion.hh.

◆ __SubBitUnion

#define __SubBitUnion ( name,
fieldType,
... )
Value:
class \
{ \
public: \
union { \
fieldType<__VA_ARGS__> __storage;

Definition at line 439 of file bitunion.hh.

◆ BitUnion16

#define BitUnion16 ( name)    __BitUnion(uint16_t, name)

Definition at line 496 of file bitunion.hh.

◆ BitUnion32

#define BitUnion32 ( name)    __BitUnion(uint32_t, name)

Definition at line 495 of file bitunion.hh.

Referenced by gem5::SparcISA::SparcStaticInst::passesCondition().

◆ BitUnion8

#define BitUnion8 ( name)    __BitUnion(uint8_t, name)

Definition at line 497 of file bitunion.hh.


Generated on Tue Jun 18 2024 16:24:08 for gem5 by doxygen 1.11.0