Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
codes
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
38
Issues
38
List
Boards
Labels
Milestones
Merge Requests
8
Merge Requests
8
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
codes
codes
Commits
e6f95a18
Commit
e6f95a18
authored
May 09, 2018
by
Misbah Mubarak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
adding hop count for local nodes in df-dally
parent
e7c55e0c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
6 deletions
+13
-6
src/networks/model-net/dragonfly-custom.C
src/networks/model-net/dragonfly-custom.C
+13
-6
No files found.
src/networks/model-net/dragonfly-custom.C
View file @
e6f95a18
...
...
@@ -46,8 +46,9 @@ static int BIAS_MIN = 1;
static
int
DF_DALLY
=
0
;
static
int
adaptive_threshold
=
1024
;
unsigned
long
num_local_packets
=
0
;
unsigned
long
num_remote_packets
=
0
;
static
long
num_local_packets_sr
=
0
;
static
long
num_local_packets_sg
=
0
;
static
long
num_remote_packets
=
0
;
using
namespace
std
;
struct
Link
{
int
offset
,
type
;
...
...
@@ -841,7 +842,7 @@ void dragonfly_custom_report_stats()
tw_stime
avg_time
,
max_time
;
int
total_minimal_packets
,
total_nonmin_packets
;
long
total_gen
,
total_fin
;
long
total_local_packets
,
total_remote_packets
;
long
total_local_packets
_sr
,
total_local_packets_sg
,
total_remote_packets
;
MPI_Reduce
(
&
total_hops
,
&
avg_hops
,
1
,
MPI_LONG_LONG
,
MPI_SUM
,
0
,
MPI_COMM_CODES
);
MPI_Reduce
(
&
N_finished_packets
,
&
total_finished_packets
,
1
,
MPI_LONG_LONG
,
MPI_SUM
,
0
,
MPI_COMM_CODES
);
...
...
@@ -853,7 +854,8 @@ void dragonfly_custom_report_stats()
MPI_Reduce
(
&
packet_gen
,
&
total_gen
,
1
,
MPI_LONG
,
MPI_SUM
,
0
,
MPI_COMM_CODES
);
MPI_Reduce
(
&
packet_fin
,
&
total_fin
,
1
,
MPI_LONG
,
MPI_SUM
,
0
,
MPI_COMM_CODES
);
MPI_Reduce
(
&
num_local_packets
,
&
total_local_packets
,
1
,
MPI_LONG
,
MPI_SUM
,
0
,
MPI_COMM_CODES
);
MPI_Reduce
(
&
num_local_packets_sr
,
&
total_local_packets_sr
,
1
,
MPI_LONG
,
MPI_SUM
,
0
,
MPI_COMM_CODES
);
MPI_Reduce
(
&
num_local_packets_sg
,
&
total_local_packets_sg
,
1
,
MPI_LONG
,
MPI_SUM
,
0
,
MPI_COMM_CODES
);
MPI_Reduce
(
&
num_remote_packets
,
&
total_remote_packets
,
1
,
MPI_LONG
,
MPI_SUM
,
0
,
MPI_COMM_CODES
);
if
(
routing
==
ADAPTIVE
||
routing
==
PROG_ADAPTIVE
)
{
...
...
@@ -870,7 +872,7 @@ void dragonfly_custom_report_stats()
printf
(
"
\n
ADAPTIVE ROUTING STATS: %d chunks routed minimally %d chunks routed non-minimally completed packets %lld
\n
"
,
total_minimal_packets
,
total_nonmin_packets
,
total_finished_chunks
);
printf
(
"
\n
Total packets generated %ld finished %ld Locally routed
%ld Remote (inter-group) %ld
\n
"
,
total_gen
,
total_fin
,
total_local_packets
,
total_remote_packets
);
printf
(
"
\n
Total packets generated %ld finished %ld Locally routed
- same router %ld different-router %ld Remote (inter-group) %ld
\n
"
,
total_gen
,
total_fin
,
total_local_packets_sr
,
total_local_packets_sg
,
total_remote_packets
);
}
return
;
}
...
...
@@ -1232,7 +1234,12 @@ static void packet_generate(terminal_state * s, tw_bf * bf, terminal_custom_mess
int
src_grp_id
=
s
->
router_id
/
s
->
params
->
num_routers
;
if
(
src_grp_id
==
dest_grp_id
)
num_local_packets
++
;
{
if
(
dest_router_id
==
s
->
router_id
)
num_local_packets_sr
++
;
else
num_local_packets_sg
++
;
}
else
num_remote_packets
++
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment