Transaction-Level Modeling Framework for Space Applications
#include <irqmp.h>
Public Member Functions | |
SC_HAS_PROCESS (Irqmp) | |
SR_HAS_SIGNALS (Irqmp) | |
GC_HAS_CALLBACKS () | |
Irqmp (sc_module_name name, int32_t paddr=0, int32_t pmask=0xFFF, int32_t ncpu=2, int32_t eirq=1, uint32_t pindex=0, bool powmon=false) | |
Constructor. More... | |
~Irqmp () | |
void | init_generics () |
void | init_registers () |
void | start_of_simulation () |
Automatically called at start of simulation. More... | |
void | end_of_elaboration () |
SystemC end of elaboration implementation. More... | |
void | end_of_simulation () |
SystemC end of simulation. More... | |
void | power_model () |
Calculate power/energy values from normalized input data. More... | |
gs::cnf::callback_return_type | sta_power_cb (gs::gs_param_base &changed_param, gs::cnf::callback_type reason) |
Static power callback. More... | |
gs::cnf::callback_return_type | int_power_cb (gs::gs_param_base &changed_param, gs::cnf::callback_type reason) |
Dynamic/Internal power callback. More... | |
void | launch_irq () |
void | clear_write () |
void | force_write () |
void | mpstat_read () |
Prepare reading of the MP status register. More... | |
void | mpstat_write () |
Write to MP status register. More... | |
void | pending_write () |
void | dorst () |
void | incomming_irq (const std::pair< uint32_t, bool > &value, const sc_time &time) |
void | acknowledged_irq (const uint32_t &irq, const uint32_t &cpu, const sc_time &time) |
Public Member Functions inherited from APBSlave | |
APBSlave (ModuleName mn, uint32_t bus_id, uint8_t vendorid, uint16_t deviceid, uint8_t version, uint8_t irq, AMBADeviceType type, uint16_t mask, bool cacheable, bool prefetchable, uint16_t address) | |
APBSlave (ModuleName mn) | |
~APBSlave () | |
Public Member Functions inherited from APBDevice< BaseModule< DefaultBase > > | |
APBDevice (ModuleName mn, uint32_t bus_id, uint8_t vendorid, uint16_t deviceid, uint8_t version, uint8_t irq, AMBADeviceType type, uint16_t mask, bool cacheable, bool prefetchable, uint16_t address) | |
APBDevice (ModuleName mn) | |
void | init_apb (uint32_t pindex, uint8_t vendorid, uint16_t deviceid, uint8_t version, uint8_t irq, AMBADeviceType type, uint16_t mask, bool cacheable, bool prefetchable, uint16_t address) |
void | init_apb_generics () |
Initialize the APBDevice generics. More... | |
virtual | ~APBDevice () |
Empty destructor. More... | |
virtual uint16_t | get_apb_device_id () const |
Returns the device id. More... | |
virtual uint8_t | get_apb_vendor_id () const |
Returns the vendor id. More... | |
virtual const uint32_t * | get_apb_device_info () |
virtual const AMBADeviceType | get_apb_type () const |
virtual uint32_t | get_apb_base () const |
virtual uint32_t | get_apb_mask () const |
virtual sc_dt::uint64 | get_apb_base_addr () |
virtual uint32_t | get_apb_base_addr_ () const |
virtual sc_dt::uint64 | get_apb_size () |
virtual uint32_t | get_apb_size_ () const |
virtual uint32_t | get_apb_relative_addr (uint32_t addr) const |
virtual uint32_t | get_apb_pindex () const |
Returns the bus id of the module (pindex) More... | |
virtual void | print_apb_device_info (char *name) const |
Prints the device info of the device. More... | |
Public Member Functions inherited from BaseModule< DefaultBase > | |
BaseModule (ModuleName mn) | |
virtual | ~BaseModule () |
virtual void | init_counters () |
virtual void | init_power () |
Public Member Functions inherited from APBDeviceBase | |
virtual | ~APBDeviceBase () |
Empty destructor. More... | |
Public Member Functions inherited from CLKDevice | |
SR_HAS_SIGNALS (CLKDevice) | |
CLKDevice () | |
virtual | ~CLKDevice () |
virtual void | onrst (const bool &value, const sc_core::sc_time &time) |
virtual void | onclk (const sc_core::sc_time &value, const sc_core::sc_time &time) |
void | set_clk (sc_core::sc_clock &clk) |
void | set_clk (sc_core::sc_time period) |
void | set_clk (double period, sc_core::sc_time_unit base) |
virtual void | clkcng () |
Static Public Member Functions | |
static const uint32_t | PROC_IR_MASK (int CPU_INDEX) |
static const uint32_t | PROC_IR_FORCE (int CPU_INDEX) |
static const uint32_t | PROC_EXTIR_ID (int CPU_INDEX) |
Public Attributes | |
signal< bool >::selector | cpu_rst |
CPU reset out signals. More... | |
signal< bool >::infield | cpu_stat |
CPU reset out signals. More... | |
signal< std::pair< uint32_t, bool > >::selector | irq_req |
IRQ Request out signals. More... | |
signal< uint32_t >::infield | irq_ack |
IRQ Acknowledge input signals. More... | |
signal< std::pair< uint32_t, bool > >::in | irq_in |
IRQ input signals from other devices. More... | |
sc_event | e_signal |
Internal signal to decouple inputs and outputs. Furthermore it addes the needed delays. More... | |
sr_param< int > | g_ncpu |
sr_param< uint32_t > | g_eirq |
sr_param< double > | sta_power_norm |
Normalized static power of controller. More... | |
sr_param< double > | int_power_norm |
Normalized dynamic power of controller. More... | |
sr_param< double > | sta_power |
Controller static power. More... | |
sr_param< double > | int_power |
Controller dynamic power. More... | |
Public Attributes inherited from APBSlave | |
sr_register_bank< unsigned int, unsigned int > | r |
APBSlaveSocket< 32, unsigned int, unsigned int > | apb |
Public Attributes inherited from CLKDevice | |
signal< bool >::in | rst |
Reset input signal. More... | |
signal< sc_core::sc_time >::in | clk |
Clock input signal. More... | |
Static Public Attributes | |
static const uint32_t | IR_LEVEL = 0x00 |
static const uint32_t | IR_PENDING = 0x04 |
static const uint32_t | IR_FORCE = 0x08 |
static const uint32_t | IR_CLEAR = 0x0C |
static const uint32_t | MP_STAT = 0x10 |
static const uint32_t | BROADCAST = 0x14 |
static const uint32_t | IR_LEVEL_IL = 0x0000FFFE |
static const uint32_t | IR_PENDING_EIP = 0xFFFF0000 |
static const uint32_t | IR_PENDING_IP = 0x0000FFFE |
interrupt pending (true or false) More... | |
static const uint32_t | IR_FORCE_IF = 0x0000FFFE |
static const uint32_t | IR_CLEAR_IC = 0xFFFFFFFE |
static const uint32_t | MP_STAT_WMASK = 0x0000FFFF |
static const uint32_t | MP_STAT_NCPU = 0xF0000000 |
number of CPUs in the system More... | |
static const uint32_t | MP_STAT_EIRQ = 0x000F0000 |
interrupt number used for extended interrupts More... | |
static const uint32_t | BROADCAST_BM = 0x0000FFFE |
static const uint32_t | PROC_MASK_EIM = 0xFFFF0000 |
static const uint32_t | PROC_MASK_IM = 0x0000FFFE |
interrupt mask (0 = masked) More... | |
static const uint32_t | PROC_IR_FORCE_IFC = 0xFFFE0000 |
static const uint32_t | PROC_IR_FORCE_IF = 0x0000FFFE |
interrupt force More... | |
static const uint32_t | PROC_EXTIR_ID_EID = 0x0000001F |
static const uint32_t | LEVEL_DEFAULT = 0x00000000 |
static const uint32_t | PENDING_DEFAULT = 0x00000000 |
interrupt pending register More... | |
static const uint32_t | FORCE_DEFAULT = 0x00000000 |
interrupt force register More... | |
static const uint32_t | CLEAR_DEFAULT = 0x00000000 |
interrupt clear register More... | |
static const uint32_t | MP_STAT_DEFAULT = 0x00000001 |
multiprocessor status register More... | |
static const uint32_t | BROADCAST_DEFAULT = 0x00000000 |
broadcast register More... | |
static const uint32_t | MASK_DEFAULT = 0xFFFFFFFE |
interrupt mask register More... | |
static const uint32_t | PROC_FORCE_DEFAULT = 0x00000000 |
processor interrupt force register More... | |
static const uint32_t | EXTIR_ID_DEFAULT = 0x00000000 |
extended interrupt identification register More... | |
Additional Inherited Members | |
Protected Attributes inherited from APBDevice< BaseModule< DefaultBase > > | |
uint32_t | m_register [2] |
Impementation of the device register file. More... | |
sr_param< uint32_t > | g_pindex |
sr_param< uint8_t > | g_pvendorid |
sr_param< uint16_t > | g_pdeviceid |
sr_param< uint8_t > | g_pversion |
sr_param< uint8_t > | g_pirq |
sr_param< uint32_t > | g_paddr |
sr_param< uint32_t > | g_pmask |
sr_param< uint32_t > | g_ptype |
sr_param< bool > | g_pcacheable |
sr_param< bool > | g_pprefetchable |
Protected Attributes inherited from BaseModule< DefaultBase > | |
ParameterAPI * | m_api |
Internal module gs param api instance. More... | |
ParameterArray | m_generics |
Configuration generic container. More... | |
ParameterArray | m_counters |
Performance counter container. More... | |
ParameterArray | m_power |
Power counters container. More... | |
Protected Attributes inherited from CLKDevice | |
sc_core::sc_time | clock_cycle |
Irqmp::GC_HAS_CALLBACKS | ( | ) |
Referenced by acknowledged_irq(), clear_write(), dorst(), and force_write().
Referenced by acknowledged_irq(), dorst(), force_write(), incomming_irq(), and launch_irq().
Referenced by dorst(), and launch_irq().
Irqmp::SC_HAS_PROCESS | ( | Irqmp | ) |
Irqmp::SR_HAS_SIGNALS | ( | Irqmp | ) |
Referenced by dorst(), and incomming_irq().
broadcast register (applicable if NCPU>1) broadcast mask: if n=1, interrupt n is broadcasted
Referenced by init_registers().
broadcast register
Referenced by dorst().
interrupt clear register
Referenced by dorst().
signal<bool>::selector Irqmp::cpu_rst |
CPU reset out signals.
Referenced by dorst(), mpstat_write(), and sc_main().
signal<bool>::infield Irqmp::cpu_stat |
CPU reset out signals.
Referenced by mpstat_read(), mpstat_write(), and sc_main().
sc_event Irqmp::e_signal |
Internal signal to decouple inputs and outputs. Furthermore it addes the needed delays.
Referenced by acknowledged_irq(), clear_write(), force_write(), incomming_irq(), launch_irq(), and pending_write().
extended interrupt identification register
Referenced by dorst().
interrupt force register
Referenced by dorst().
Extended Interrupt Number Behind this interrupt are all extended interrupt cascaded.
Referenced by acknowledged_irq(), clear_write(), dorst(), force_write(), init_generics(), launch_irq(), and mpstat_read().
Number of CPUs in the System Needet to determ the number of receiver lines.
Referenced by clear_write(), dorst(), end_of_simulation(), force_write(), incomming_irq(), init_generics(), init_registers(), Irqmp(), launch_irq(), mpstat_read(), and mpstat_write().
Controller dynamic power.
Referenced by Irqmp(), and power_model().
Normalized dynamic power of controller.
Referenced by power_model().
Referenced by clear_write(), and dorst().
interrupt clear register n=1 to clear interrupt n
Referenced by init_registers().
Referenced by acknowledged_irq(), clear_write(), dorst(), and launch_irq().
interrupt force register force interrupt (true or false)
Referenced by init_registers(), and launch_irq().
Referenced by dorst(), and launch_irq().
register contents (config bit masks) interrupt level register interrupt priority level (0 or 1)
Referenced by init_registers().
Referenced by acknowledged_irq(), clear_write(), dorst(), force_write(), incomming_irq(), and launch_irq().
interrupt pending register extended interrupt pending (true or false)
Referenced by init_registers(), and launch_irq().
interrupt pending (true or false)
Referenced by init_registers(), and launch_irq().
IRQ input signals from other devices.
Referenced by sc_main().
IRQ Request out signals.
Referenced by acknowledged_irq(), clear_write(), force_write(), launch_irq(), and sc_main().
register default values interrupt level register
Referenced by dorst().
interrupt mask register
Referenced by dorst().
Referenced by dorst(), mpstat_read(), and mpstat_write().
interrupt number used for extended interrupts
multiprocessor status register multiprocessor status register write mask
Referenced by init_registers().
interrupt pending register
Referenced by dorst().
extended interrupt identification register ID of the acknowledged extended interrupt (16..31)
Referenced by init_registers().
processor interrupt force register
Referenced by dorst().
interrupt force
Referenced by force_write(), and init_registers().
processor interrupt force register interrupt force clear
Referenced by init_registers().
processor mask register interrupt mask for extended interrupts
Referenced by init_registers().
interrupt mask (0 = masked)
Referenced by init_registers().
Controller static power.
Referenced by Irqmp(), and power_model().
Normalized static power of controller.
Referenced by power_model().