53 #ifndef ETISS_INCLUDE_INTERRUPTVECTOR_H_
54 #define ETISS_INCLUDE_INTERRUPTVECTOR_H_
57 #include "etiss/jit/types.h"
76 virtual void setBit(
unsigned bit,
bool state) = 0;
80 virtual bool getBit(
unsigned bit)
const = 0;
84 virtual unsigned width()
const = 0;
97 template <
typename INT>
105 typedef typename std::vector<INT *>
Vector;
111 if (
vector_.size() > mask.size())
116 if (
vector_.size() < mask.size())
123 virtual void setBit(
unsigned bit,
bool state)
125 unsigned o = bit % (
sizeof(
INT) * 8);
126 unsigned i = (bit - o) / (
sizeof(
INT) * 8);
138 unsigned o = bit % (
sizeof(
INT) * 8);
139 unsigned i = (bit - o) / (
sizeof(
INT) * 8);
143 return ((*
vector_[i] & mask) & (*
mask_[i] & mask)) != 0;
150 for (
unsigned i = 0; i <
vector_.size(); i++)
159 for (
unsigned i = 0; i <
vector_.size(); i++)
general configuration and logging
interface to set interrupt bits
virtual void clear()
sets every bit to false
virtual unsigned width() const =0
number of interrupt bits
virtual bool isActive() const
virtual bool getBit(unsigned bit) const =0
get the bit of an interrupt line
bool consumed_by_interruptlistener_
virtual void setBit(unsigned bit, bool state)=0
set the bit of an interrupt line to state (true = raised)
virtual ~InterruptVector()
template implementation of an InterruptVector that uses integer variables to store interrupt bit valu...
virtual bool isActive() const
virtual void clear()
sets every bit to false
std::vector< INT * > Vector
virtual ~MappedInterruptVector()
virtual void setBit(unsigned bit, bool state)
set the bit of an interrupt line to state (true = raised)
virtual bool getBit(unsigned bit) const
get the bit of an interrupt line
MappedInterruptVector(Vector vec, Vector mask)
pass two equally long integer pointer vectors that will be used for interrupt bit vectors and masks
virtual unsigned width() const
number of interrupt bits
Page Table Entry (PTE) defines the composition of Page Frame Number (PFN) and relavant flags.
void log(Verbosity level, std::string msg)
write log message at the given level.