#include <genericInterfaceNB.h>
Definition at line 49 of file genericInterfaceNB.h.
GenericInterfaceNB::GenericInterfaceNB | ( | ) |
=====================================================================================
Filename: genericInterfaceNB.cc
Description: Implements the class described in genericInterfaceNB.h
Version: 1.0 Created: 02/21/2010 03:46:20 PM Revision: none Compiler: gcc
Author: Mitchelle Rasquinha (), mitchelle.rasquinha@gatech.edu Company: Georgia Institute of Technology
=====================================================================================
Definition at line 24 of file genericInterfaceNB.cc.
References NetworkComponent::name, and ticking.
GenericInterfaceNB::~GenericInterfaceNB | ( | ) |
ullint GenericInterfaceNB::get_flits_out | ( | ) | [virtual] |
uint GenericInterfaceNB::get_no_credits | ( | ) | const |
ullint GenericInterfaceNB::get_packets | ( | ) | [virtual] |
Implements Interface.
Definition at line 602 of file genericInterfaceNB.cc.
References packets_in, and packets_out.
ullint GenericInterfaceNB::get_packets_out | ( | ) | [virtual] |
void GenericInterfaceNB::handle_link_arrival | ( | IrisEvent * | e | ) | [private] |
link arrival can be for a flit or credit. FLIT: Add incoming flit to buffer and send a credit back. Credit for the tail flit is not sent here. This is held till we know the ejection port is free. ( This is modelled here for the additional MC backpressure modelling and need not be this way). CREDIT: Update state for downstream credits. Generate a TICK event at the end of it. This will restart the interface if it is blocked on a credit(outgoing path) or initiate a new packet(incoming path).
Definition at line 198 of file genericInterfaceNB.cc.
References _DBG, HeadFlit::addr, NetworkComponent::address, GenericBuffer::change_push_channel(), CREDIT_ID, downstream_credits, IrisEvent::event_data, FLIT_ID, flits_in, HEAD, in_buffer, Interface::input_connection, is_mc_interface, istat, LINK_ARRIVAL_EVENT, Simulator::Now(), ONE_FLIT_REQ, packets_in, process_event(), NetworkComponent::process_event(), LinkArrivalData::ptr, GenericBuffer::push(), Simulator::Schedule(), IrisStats::stat_link, TAIL, TICK_EVENT, ticking, total_packets_in_time, IrisEvent::type, Flit::type, LinkArrivalData::type, LinkArrivalData::valid, IrisEvent::vc, Flit::vc, and LinkArrivalData::vc.
Referenced by process_event().
void GenericInterfaceNB::handle_new_packet_event | ( | IrisEvent * | e | ) | [private] |
Definition at line 289 of file genericInterfaceNB.cc.
References _DBG, HighLevelPacket::addr, IrisEvent::event_data, is_mc_interface, Simulator::Now(), out_packet_flit_index, out_packets, NetworkComponent::process_event(), Simulator::Schedule(), TICK_EVENT, ticking, HighLevelPacket::to_low_level_packet(), HighLevelPacket::toString(), IrisEvent::vc, and HighLevelPacket::virtual_channel.
Referenced by process_event().
void GenericInterfaceNB::handle_ready_event | ( | IrisEvent * | e | ) | [private] |
These are credits from the processor and hence do not update flow control state. Flow control state is updated at the link arrival event for a credit.
Definition at line 162 of file genericInterfaceNB.cc.
References _DBG, in_ready, is_mc_interface, Simulator::Now(), NetworkComponent::process_event(), Simulator::Schedule(), TICK_EVENT, ticking, and IrisEvent::vc.
Referenced by process_event().
void GenericInterfaceNB::handle_tick_event | ( | IrisEvent * | e | ) | [private] |
Definition at line 332 of file genericInterfaceNB.cc.
References _DBG, HighLevelPacket::addr, HeadFlit::addr, NetworkComponent::address, HighLevelPacket::avg_network_latency, GenericBuffer::change_pull_channel(), GenericBuffer::change_push_channel(), GenericArbiter::clear_winner(), CREDIT_ID, downstream_credits, IrisEvent::event_data, flast_vc, FLIT_ID, flits_out, HighLevelPacket::from_low_level_packet(), GenericBuffer::get_occupancy(), HEAD, HighLevelPacket::hop_count, in_buffer, in_packet_complete, in_packets, in_packets_flit_index, in_ready, Interface::input_connection, GenericArbiter::is_empty(), is_mc_interface, istat, LINK_ARRIVAL_EVENT, NEW_PACKET_EVENT, NetworkComponent::node_ip, Simulator::Now(), ONE_FLIT_REQ, out_arbiter, out_buffer, out_packet_flit_index, out_packets, Interface::output_connection, packets_out, GenericArbiter::pick_winner(), process_event(), NetworkComponent::process_event(), Interface::processor_connection, LinkArrivalData::ptr, GenericBuffer::pull(), GenericBuffer::push(), READY_EVENT, HighLevelPacket::recv_time, HighLevelPacket::req_start_time, GenericArbiter::request(), Simulator::Schedule(), IrisEvent::src_id, IrisStats::stat_link, TAIL, TICK_EVENT, ticking, IrisEvent::type, Flit::type, LinkArrivalData::type, IrisEvent::vc, LinkArrivalData::vc, Flit::vc, vcs, HighLevelPacket::virtual_channel, and HighLevelPacket::waiting_in_ni.
Referenced by process_event().
string GenericInterfaceNB::print_stats | ( | void | ) | [virtual] |
Implements Interface.
Definition at line 574 of file genericInterfaceNB.cc.
References flits_in, flits_out, NetworkComponent::node_ip, packets_in, packets_out, and total_packets_in_time.
void GenericInterfaceNB::process_event | ( | IrisEvent * | e | ) | [virtual] |
READY_EVENT: A ready is the credit at a packet level with the injection/ejection point
LINK_ARRIVAL_EVENT: This is a flit/credit arrival from the network. (Incoming path)
NEW_PACKET_EVENT: This is a high level packet from the processor connected to this node
TICK_EVENT: Update internal state of the interface. This involves two distinct paths ( Incoming and Outgoing ). Push flits into the output buffer and send them out after all flits for a packet are moved to the output buffer(Outgoing path). Push flits from the input buffer to a low level packet. Convert the low level packet to a high level packet when complete and then send it to the injection processor connected to this node (Incoming path).
Implements Interface.
Definition at line 122 of file genericInterfaceNB.cc.
References handle_link_arrival(), handle_new_packet_event(), handle_ready_event(), handle_tick_event(), LINK_ARRIVAL_EVENT, NEW_PACKET_EVENT, READY_EVENT, TICK_EVENT, and IrisEvent::type.
Referenced by handle_link_arrival(), and handle_tick_event().
void GenericInterfaceNB::set_buffer_size | ( | uint | b | ) | [virtual] |
void GenericInterfaceNB::set_no_credits | ( | int | credits | ) | [virtual] |
void GenericInterfaceNB::set_no_vcs | ( | uint | v | ) | [virtual] |
Implements Interface.
Definition at line 37 of file genericInterfaceNB.cc.
References NetworkComponent::address, buffer_size, credits, downstream_credits, flast_vc, flits_in, flits_out, in_buffer, in_packet_complete, in_packets, in_packets_flit_index, in_packets_valid, in_ready, Component::myId(), out_arbiter, out_buffer, out_packet_flit_index, out_packets, packets_in, packets_out, GenericBuffer::resize(), GenericArbiter::set_no_requestors(), ticking, total_packets_in_time, and vcs.
string GenericInterfaceNB::toString | ( | ) | const [virtual] |
Reimplemented from Interface.
Definition at line 88 of file genericInterfaceNB.cc.
References NetworkComponent::address, in_buffer, NetworkComponent::node_ip, out_buffer, out_packets, and GenericBuffer::toString().
uint GenericInterfaceNB::buffer_size [private] |
int GenericInterfaceNB::credits [private] |
vector< int > GenericInterfaceNB::downstream_credits [private] |
Definition at line 83 of file genericInterfaceNB.h.
Referenced by handle_link_arrival(), handle_tick_event(), and setup().
uint GenericInterfaceNB::flast_vc [private] |
ullint GenericInterfaceNB::flits_in [private] |
Definition at line 103 of file genericInterfaceNB.h.
Referenced by handle_link_arrival(), print_stats(), and setup().
ullint GenericInterfaceNB::flits_out [private] |
Definition at line 105 of file genericInterfaceNB.h.
Referenced by get_flits_out(), handle_tick_event(), print_stats(), and setup().
GenericBuffer GenericInterfaceNB::in_buffer [private] |
Definition at line 81 of file genericInterfaceNB.h.
Referenced by handle_link_arrival(), handle_tick_event(), setup(), and toString().
bool GenericInterfaceNB::in_packet_cleared [private] |
Definition at line 75 of file genericInterfaceNB.h.
vector<bool> GenericInterfaceNB::in_packet_complete [private] |
vector< LowLevelPacket> GenericInterfaceNB::in_packets [private] |
Definition at line 90 of file genericInterfaceNB.h.
Referenced by handle_tick_event(), setup(), and ~GenericInterfaceNB().
vector< uint > GenericInterfaceNB::in_packets_flit_index [private] |
vector< bool> GenericInterfaceNB::in_packets_valid [private] |
vector< bool > GenericInterfaceNB::in_ready [private] |
Definition at line 94 of file genericInterfaceNB.h.
Referenced by handle_ready_event(), handle_tick_event(), and setup().
Definition at line 67 of file genericInterfaceNB.h.
Referenced by handle_link_arrival(), handle_new_packet_event(), handle_ready_event(), and handle_tick_event().
GenericBuffer GenericInterfaceNB::out_buffer [private] |
Definition at line 80 of file genericInterfaceNB.h.
Referenced by handle_tick_event(), setup(), and toString().
vector< uint > GenericInterfaceNB::out_packet_flit_index [private] |
Definition at line 87 of file genericInterfaceNB.h.
Referenced by handle_new_packet_event(), handle_tick_event(), and setup().
vector< LowLevelPacket> GenericInterfaceNB::out_packets [private] |
Definition at line 86 of file genericInterfaceNB.h.
Referenced by handle_new_packet_event(), handle_tick_event(), setup(), toString(), and ~GenericInterfaceNB().
ullint GenericInterfaceNB::packets_in [private] |
Definition at line 104 of file genericInterfaceNB.h.
Referenced by get_packets(), handle_link_arrival(), print_stats(), and setup().
ullint GenericInterfaceNB::packets_out [private] |
Definition at line 106 of file genericInterfaceNB.h.
Referenced by get_packets(), get_packets_out(), handle_tick_event(), print_stats(), and setup().
bool GenericInterfaceNB::ticking [private] |
Definition at line 79 of file genericInterfaceNB.h.
Referenced by GenericInterfaceNB(), handle_link_arrival(), handle_new_packet_event(), handle_ready_event(), handle_tick_event(), and setup().
Definition at line 107 of file genericInterfaceNB.h.
Referenced by handle_link_arrival(), print_stats(), and setup().
uint GenericInterfaceNB::vcs [private] |