Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
codes-dev
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Xin Wang
codes-dev
Commits
3435735f
Commit
3435735f
authored
Aug 28, 2017
by
Misbah Mubarak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixing memory allocation with wait-time
parent
c5642c7f
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
5 deletions
+5
-5
src/networks/model-net/dragonfly-custom.C
src/networks/model-net/dragonfly-custom.C
+1
-1
src/networks/model-net/dragonfly.c
src/networks/model-net/dragonfly.c
+2
-2
src/networks/model-net/slimfly.c
src/networks/model-net/slimfly.c
+1
-1
src/networks/model-net/torus.c
src/networks/model-net/torus.c
+1
-1
No files found.
src/networks/model-net/dragonfly-custom.C
View file @
3435735f
...
...
@@ -871,7 +871,7 @@ terminal_custom_init( terminal_state * s,
rc_stack_create
(
&
s
->
st
);
s
->
num_vcs
=
1
;
s
->
vc_occupancy
=
(
int
*
)
malloc
(
s
->
num_vcs
*
sizeof
(
int
));
s
->
last_buf_full
=
(
tw_stime
*
)
malloc
(
s
->
num_vcs
*
sizeof
(
int
));
s
->
last_buf_full
=
(
tw_stime
*
)
malloc
(
s
->
num_vcs
*
sizeof
(
tw_stime
));
for
(
i
=
0
;
i
<
s
->
num_vcs
;
i
++
)
{
...
...
src/networks/model-net/dragonfly.c
View file @
3435735f
...
...
@@ -790,15 +790,15 @@ terminal_init( terminal_state * s,
s
->
finished_packets
=
0
;
s
->
total_time
=
0
.
0
;
s
->
total_msg_size
=
0
;
s
->
num_vcs
=
1
;
s
->
last_buf_full
=
(
tw_stime
*
)
malloc
(
s
->
num_vcs
*
sizeof
(
int
));
s
->
last_buf_full
=
(
tw_stime
*
)
malloc
(
s
->
num_vcs
*
sizeof
(
tw_stime
));
s
->
busy_time
=
0
.
0
;
s
->
fwd_events
=
0
;
s
->
rev_events
=
0
;
rc_stack_create
(
&
s
->
st
);
s
->
num_vcs
=
1
;
s
->
vc_occupancy
=
(
int
*
)
malloc
(
s
->
num_vcs
*
sizeof
(
int
));
for
(
i
=
0
;
i
<
s
->
num_vcs
;
i
++
)
...
...
src/networks/model-net/slimfly.c
View file @
3435735f
...
...
@@ -784,11 +784,11 @@ void slim_terminal_init( terminal_state * s,
s
->
total_time
=
0
.
0
;
s
->
total_msg_size
=
0
;
s
->
last_buf_full
=
(
tw_stime
*
)
malloc
(
s
->
num_vcs
*
sizeof
(
int
));
s
->
busy_time
=
0
;
rc_stack_create
(
&
s
->
st
);
s
->
num_vcs
=
1
;
s
->
last_buf_full
=
(
tw_stime
*
)
malloc
(
s
->
num_vcs
*
sizeof
(
tw_stime
));
s
->
vc_occupancy
=
(
int
*
)
malloc
(
s
->
num_vcs
*
sizeof
(
int
));
for
(
i
=
0
;
i
<
s
->
num_vcs
;
i
++
)
...
...
src/networks/model-net/torus.c
View file @
3435735f
...
...
@@ -1297,7 +1297,7 @@ static void packet_send( nodes_state * s,
if
(
cur_entry
==
NULL
)
{
bf
->
c4
=
1
;
if
(
!
s
->
last_buf_full
[
queue
]
)
if
(
s
->
queued_msgs
[
queue
][
STATICQ
]
!=
NULL
&&
s
->
last_buf_full
[
queue
]
==
0
.
0
)
{
bf
->
c24
=
1
;
msg
->
saved_busy_time
=
s
->
last_buf_full
[
queue
];
...
...
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