GitLab maintenance scheduled for Today, 2019-09-24, from 12:00 to 13:00 CT - Services will be unavailable during this time.

...
  View open merge request
Commits (3)
  • RAM's avatar
    dragonfly-link-stat file: · 34f4b541
    RAM authored
    1.router_final_function()
    [global connection offset was not correct] -> offset+intra-group_index
    2.terminal_final_function()
    changed source to router and dest to terminal because LLU(s->total_msg_size) is message received
    34f4b541
  • RAM's avatar
    dragonfly-link-stat file: · 4c12cfcb
    RAM authored
    1.Terminal final function:
      added link_traffic to terminal state and print terminal to router flow
    2.Router final function:
      Router to terminal flow print added
    4c12cfcb
  • RAM's avatar
    fb6b89c0
...@@ -309,6 +309,7 @@ struct terminal_state ...@@ -309,6 +309,7 @@ struct terminal_state
tw_stime last_buf_full; tw_stime last_buf_full;
tw_stime busy_time; tw_stime busy_time;
int64_t link_traffic;
tw_stime max_latency; tw_stime max_latency;
tw_stime min_latency; tw_stime min_latency;
...@@ -1422,6 +1423,7 @@ terminal_dally_init( terminal_state * s, ...@@ -1422,6 +1423,7 @@ terminal_dally_init( terminal_state * s,
s->total_msg_size = 0; s->total_msg_size = 0;
s->busy_time = 0.0; s->busy_time = 0.0;
s->link_traffic=0.0;
s->fwd_events = 0; s->fwd_events = 0;
s->rev_events = 0; s->rev_events = 0;
...@@ -2152,6 +2154,7 @@ static void packet_send_rc(terminal_state * s, tw_bf * bf, terminal_dally_messag ...@@ -2152,6 +2154,7 @@ static void packet_send_rc(terminal_state * s, tw_bf * bf, terminal_dally_messag
s->terminal_length[vcg] += s->params->chunk_size; s->terminal_length[vcg] += s->params->chunk_size;
/*TODO: MM change this to the vcg */ /*TODO: MM change this to the vcg */
s->vc_occupancy[vcg] -= s->params->chunk_size; s->vc_occupancy[vcg] -= s->params->chunk_size;
s->link_traffic-=s->params->chunk_size;
terminal_dally_message_list* cur_entry = (terminal_dally_message_list *)rc_stack_pop(s->st); terminal_dally_message_list* cur_entry = (terminal_dally_message_list *)rc_stack_pop(s->st);
...@@ -2291,6 +2294,8 @@ static void packet_send(terminal_state * s, tw_bf * bf, terminal_dally_message * ...@@ -2291,6 +2294,8 @@ static void packet_send(terminal_state * s, tw_bf * bf, terminal_dally_message *
cur_entry = return_head(s->terminal_msgs, s->terminal_msgs_tail, vcg); cur_entry = return_head(s->terminal_msgs, s->terminal_msgs_tail, vcg);
rc_stack_push(lp, cur_entry, delete_terminal_dally_message_list, s->st); rc_stack_push(lp, cur_entry, delete_terminal_dally_message_list, s->st);
s->terminal_length[vcg] -= s->params->chunk_size; s->terminal_length[vcg] -= s->params->chunk_size;
//adds link traffic of terminal to router
s->link_traffic+=s->params->chunk_size;
cur_entry = NULL; cur_entry = NULL;
if(next_vcg >= 0) if(next_vcg >= 0)
...@@ -3157,8 +3162,9 @@ dragonfly_dally_terminal_final( terminal_state * s, ...@@ -3157,8 +3162,9 @@ dragonfly_dally_terminal_final( terminal_state * s,
written += sprintf(s->output_buf + written, "# Format <source_id> <source_type> <dest_id> < dest_type> <link_type> <link_traffic> <link_saturation> <stalled_chunks>"); written += sprintf(s->output_buf + written, "# Format <source_id> <source_type> <dest_id> < dest_type> <link_type> <link_traffic> <link_saturation> <stalled_chunks>");
// fprintf(fp, "# Format <LP id> <Terminal ID> <Total Data Size> <Avg packet latency> <# Flits/Packets finished> <Avg hops> <Busy Time> <Max packet Latency> <Min packet Latency >\n"); // fprintf(fp, "# Format <LP id> <Terminal ID> <Total Data Size> <Avg packet latency> <# Flits/Packets finished> <Avg hops> <Busy Time> <Max packet Latency> <Min packet Latency >\n");
} }
written += sprintf(s->output_buf + written, "\n%u %s %llu %s %s %llu %lf %d", //since LLU(s->total_msg_size) is total message size a terminal received from a router so source is router and destination is terminal
s->terminal_id, "T", s->router_id, "R", "CN", LLU(s->total_msg_size), s->busy_time, -1); //note that terminals don't have stalled chuncks because of model net scheduling only gives a terminal what it can handle (-1 to show N/A) written += sprintf(s->output_buf + written, "\n%llu %s %u %s %s %llu %lf %d",
s->terminal_id, "T",s->router_id, "R","CN", s->link_traffic, s->busy_time, -1); //note that terminals don't have stalled chuncks because of model net scheduling only gives a terminal what it can handle (-1 to show N/A)
lp_io_write(lp->gid, (char*)"dragonfly-link-stats", written, s->output_buf); lp_io_write(lp->gid, (char*)"dragonfly-link-stats", written, s->output_buf);
...@@ -3257,12 +3263,24 @@ void dragonfly_dally_router_final(router_state * s, ...@@ -3257,12 +3263,24 @@ void dragonfly_dally_router_final(router_state * s,
dest_rtr_id, dest_rtr_id,
"R", "R",
"G", "G",
s->link_traffic[offset], s->link_traffic[p->intra_grp_radix+offset],
s->busy_time[offset], s->busy_time[p->intra_grp_radix+offset],
s->stalled_chunks[offset]); s->stalled_chunks[p->intra_grp_radix+offset]);
} }
} }
for(int d = 0; d < p->num_cn; d++)
{
written += sprintf(s->output_buf + written, "\n%d %s %d %s %s %llu %lf %lu",
s->router_id,
"R",
((s->router_id)*(p->num_cn))+d,
"T",
"CN",
s->link_traffic[p->intra_grp_radix+p->num_global_channels+d],
s->busy_time[p->intra_grp_radix+p->num_global_channels+d],
s->stalled_chunks[p->intra_grp_radix+p->num_global_channels+d]);
}
sprintf(s->output_buf + written, "\n"); sprintf(s->output_buf + written, "\n");
lp_io_write(lp->gid, (char*)"dragonfly-link-stats", written, s->output_buf); lp_io_write(lp->gid, (char*)"dragonfly-link-stats", written, s->output_buf);
...@@ -4329,9 +4347,7 @@ if(cur_chunk->msg.path_type == NON_MINIMAL) ...@@ -4329,9 +4347,7 @@ if(cur_chunk->msg.path_type == NON_MINIMAL)
msg->saved_busy_time = s->last_buf_full[output_port]; msg->saved_busy_time = s->last_buf_full[output_port];
s->last_buf_full[output_port] = tw_now(lp); s->last_buf_full[output_port] = tw_now(lp);
} }
} }
msg->saved_vc = output_port; msg->saved_vc = output_port;
msg->saved_channel = output_chan; msg->saved_channel = output_chan;
return; return;
......