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
7a7092e1
Commit
7a7092e1
authored
Nov 02, 2015
by
Misbah Mubarak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixing reverse computation bug + non minimal routing
parent
0cd09451
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
6 deletions
+7
-6
src/models/networks/model-net/dragonfly.c
src/models/networks/model-net/dragonfly.c
+7
-6
No files found.
src/models/networks/model-net/dragonfly.c
View file @
7a7092e1
...
...
@@ -2041,7 +2041,7 @@ get_next_stop(router_state * s,
/* Generate inter-mediate destination for non-minimal routing (selecting a random group) */
if
(
msg
->
last_hop
==
TERMINAL
&&
path
==
NON_MINIMAL
)
{
if
(
(
dest_router_id
/
s
->
params
->
num_routers
)
!=
s
->
group_id
)
if
(
dest_group_id
!=
s
->
group_id
)
{
msg
->
intm_group_id
=
intm_id
;
}
...
...
@@ -2053,20 +2053,21 @@ get_next_stop(router_state * s,
msg
->
intm_group_id
=
-
1
;
//no inter-mediate group
}
/* Intermediate group ID is set. Divert the packet to the intermediate group. */
if
(
path
==
NON_MINIMAL
&&
msg
->
intm_group_id
>=
0
)
if
(
path
==
NON_MINIMAL
&&
msg
->
intm_group_id
>=
0
&&
(
dest_group_id
!=
s
->
group_id
))
{
dest_group_id
=
msg
->
intm_group_id
;
}
else
/* direct the packet to the destination group */
{
dest_group_id
=
dest_router_id
/
s
->
params
->
num_routers
;
}
/********************** DECIDE THE ROUTER IN THE DESTINATION GROUP ***************/
/* It means the packet has arrived at the destination group. Now divert it to the destination router. */
if
(
s
->
group_id
==
dest_group_id
)
{
if
(
msg
->
last_hop
==
TERMINAL
&&
path
==
NON_MINIMAL
)
{
dest_lp
=
(
s
->
group_id
*
s
->
params
->
num_routers
)
+
intm_id
%
s
->
params
->
num_routers
;
}
else
{
dest_lp
=
dest_router_id
;
}
}
else
{
...
...
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