ETISS 0.8.0
Extendable Translating Instruction Set Simulator (version 0.8.0)
Public Member Functions | Static Public Member Functions | Private Types | List of all members
etiss::instr::BitArray Class Reference

stores a bit vector More...

#include <Instruction.h>

Inheritance diagram for etiss::instr::BitArray:
Inheritance graph
[legend]
Collaboration diagram for etiss::instr::BitArray:
Collaboration graph
[legend]

Public Member Functions

 BitArray (const super &a)
 
unsigned byteCount () const
 
unsigned intCount () const
 
void set_value (size_type width, unsigned long value)
 change the value the object is holding More...
 
void set_value (unsigned long value)
 
BitArray get_range (size_type end, size_type start) const
 get the interval [end, start] More...
 
void set_range (unsigned long val, size_type end, size_type start)
 set the value to the interval [end, start] More...
 
std::string to_string () const
 string representation of the BitArray More...
 

Static Public Member Functions

static std::vector< BitArraypermutate (const BitArray &input, std::vector< size_type > indexes)
 permutates the given input at the specified indexes. More...
 

Private Types

typedef boost::dynamic_bitset super
 

Detailed Description

stores a bit vector

Definition at line 160 of file Instruction.h.

Member Typedef Documentation

◆ super

typedef boost::dynamic_bitset etiss::instr::BitArray::super
private

Definition at line 163 of file Instruction.h.

Constructor & Destructor Documentation

◆ BitArray()

etiss::instr::BitArray::BitArray ( const super a)
inline

Definition at line 166 of file Instruction.h.

Member Function Documentation

◆ byteCount()

unsigned etiss::instr::BitArray::byteCount ( ) const
Returns
number of bytes stored in this array (rounded up if neccessary)

Definition at line 134 of file Instruction.cpp.

Referenced by RV32IMACFDArch::initInstrSet(), RV64IMACFDArch::initInstrSet(), and etiss::Translation::translateBlock().

Here is the caller graph for this function:

◆ get_range()

BitArray etiss::instr::BitArray::get_range ( size_type  end,
size_type  start 
) const

get the interval [end, start]

Definition at line 172 of file Instruction.cpp.

Referenced by etiss::instr::InstructionSet::compile(), etiss::instr::BitArrayRange::read(), and etiss::instr::InstructionSet::resolve().

Here is the caller graph for this function:

◆ intCount()

unsigned etiss::instr::BitArray::intCount ( ) const
Returns
number of I's required to store the data

Definition at line 140 of file Instruction.cpp.

Referenced by etiss::CPUArch::compensateEndianess(), etiss::Translation::disasm(), and etiss::Translation::translateBlock().

Here is the caller graph for this function:

◆ permutate()

std::vector< BitArray > etiss::instr::BitArray::permutate ( const BitArray input,
std::vector< size_type indexes 
)
static

permutates the given input at the specified indexes.

Ex: the bit array of 0101 with indexes 1 and 3 will be permutated to 0101, 0111, 1101, 1111

Returns
List of BitArray

Definition at line 147 of file Instruction.cpp.

References get_metrics::results.

Referenced by etiss::instr::InstructionSet::compile().

Here is the caller graph for this function:

◆ set_range()

void etiss::instr::BitArray::set_range ( unsigned long  val,
size_type  end,
size_type  start 
)

set the value to the interval [end, start]

Definition at line 181 of file Instruction.cpp.

Referenced by etiss::instr::BitArrayRange::write().

Here is the caller graph for this function:

◆ set_value() [1/2]

void etiss::instr::BitArray::set_value ( size_type  width,
unsigned long  value 
)

change the value the object is holding

Definition at line 163 of file Instruction.cpp.

References b.

Referenced by etiss::CPUArch::compensateEndianess(), etiss::Translation::disasm(), set_value(), and etiss::Translation::translateBlock().

Here is the caller graph for this function:

◆ set_value() [2/2]

void etiss::instr::BitArray::set_value ( unsigned long  value)

Definition at line 168 of file Instruction.cpp.

References set_value().

Here is the call graph for this function:

◆ to_string()

std::string etiss::instr::BitArray::to_string ( ) const

string representation of the BitArray

Definition at line 188 of file Instruction.cpp.

References s.


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