Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
SWIFTsim
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
69
Issues
69
List
Boards
Labels
Milestones
Merge Requests
11
Merge Requests
11
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
SWIFT
SWIFTsim
Commits
6b68ad08
Commit
6b68ad08
authored
Sep 09, 2020
by
Mladen Ivkovic
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
formatting
parent
c4228263
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
13 additions
and
14 deletions
+13
-14
src/cell.c
src/cell.c
+2
-4
src/engine_maketasks.c
src/engine_maketasks.c
+7
-5
src/engine_unskip.c
src/engine_unskip.c
+1
-2
src/rt/debug/rt_iact.h
src/rt/debug/rt_iact.h
+1
-1
src/scheduler.c
src/scheduler.c
+2
-2
No files found.
src/cell.c
View file @
6b68ad08
...
...
@@ -3877,7 +3877,7 @@ void cell_activate_subcell_rt_tasks(struct cell *ci, struct cell *cj,
const
int
ci_nodeID
=
e
->
nodeID
;
#endif
/* Only activate tasks that involve a local active cell. */
if
(
ci_active
&&
ci_nodeID
==
e
->
nodeID
){
if
(
ci_active
&&
ci_nodeID
==
e
->
nodeID
)
{
scheduler_activate
(
s
,
t
);
}
}
...
...
@@ -3932,7 +3932,6 @@ void cell_activate_subcell_rt_tasks(struct cell *ci, struct cell *cj,
}
}
/**
* @brief Un-skips all the hydro tasks associated with a given cell and checks
* if the space needs to be rebuilt.
...
...
@@ -4931,7 +4930,7 @@ int cell_unskip_rt_tasks(struct cell *c, struct scheduler *s) {
int
counter
=
0
;
for
(
struct
link
*
l
=
c
->
hydro
.
rt_inject
;
l
!=
NULL
;
l
=
l
->
next
)
{
counter
++
;
counter
++
;
struct
task
*
t
=
l
->
t
;
struct
cell
*
ci
=
t
->
ci
;
struct
cell
*
cj
=
t
->
cj
;
...
...
@@ -4964,7 +4963,6 @@ int cell_unskip_rt_tasks(struct cell *c, struct scheduler *s) {
return
rebuild
;
}
/**
* @brief Set the super-cell pointers for all cells in a hierarchy.
*
...
...
src/engine_maketasks.c
View file @
6b68ad08
...
...
@@ -1778,7 +1778,7 @@ void engine_link_gravity_tasks(struct engine *e) {
}
}
}
}
/* Otherwise M-M interaction? */
else
if
(
t_type
==
task_type_grav_mm
)
{
...
...
@@ -2461,8 +2461,9 @@ void engine_make_extra_hydroloop_tasks_mapper(void *map_data, int num_elements,
}
if
(
with_rt
)
{
t_rt_inject
=
scheduler_addtask
(
sched
,
task_type_sub_self
,
task_subtype_rt_inject
,
flags
,
0
,
ci
,
NULL
);
t_rt_inject
=
scheduler_addtask
(
sched
,
task_type_sub_self
,
task_subtype_rt_inject
,
flags
,
0
,
ci
,
NULL
);
}
/* Add the link between the new loop and the cell */
...
...
@@ -2646,8 +2647,9 @@ void engine_make_extra_hydroloop_tasks_mapper(void *map_data, int num_elements,
}
if
(
with_rt
)
{
t_rt_inject
=
scheduler_addtask
(
sched
,
task_type_sub_pair
,
task_subtype_rt_inject
,
flags
,
0
,
ci
,
cj
);
t_rt_inject
=
scheduler_addtask
(
sched
,
task_type_sub_pair
,
task_subtype_rt_inject
,
flags
,
0
,
ci
,
cj
);
}
engine_addlink
(
e
,
&
ci
->
hydro
.
force
,
t_force
);
...
...
src/engine_unskip.c
View file @
6b68ad08
...
...
@@ -46,7 +46,7 @@ enum task_broad_types {
task_broad_types_stars
,
task_broad_types_sinks
,
task_broad_types_black_holes
,
task_broad_types_rt
,
task_broad_types_rt
,
task_broad_types_count
,
};
...
...
@@ -271,7 +271,6 @@ static void engine_do_unskip_rt(struct cell *c, struct engine *e) {
if
(
forcerebuild
)
atomic_inc
(
&
e
->
forcerebuild
);
}
/**
* @brief Mapper function to unskip active tasks.
*
...
...
src/rt/debug/rt_iact.h
View file @
6b68ad08
...
...
@@ -50,7 +50,7 @@ __attribute__((always_inline)) INLINE static void runner_iact_rt_inject(
pd
->
calls_tot
+=
1
;
pd
->
calls_per_step
+=
1
;
if
(
r2
>
0
.
f
){
if
(
r2
>
0
.
f
)
{
sd
->
calls_self
+=
1
;
pd
->
calls_self
+=
1
;
}
else
{
...
...
src/scheduler.c
View file @
6b68ad08
...
...
@@ -1401,7 +1401,7 @@ void scheduler_reweight(struct scheduler *s, int verbose) {
t
->
subtype
==
task_subtype_force
||
t
->
subtype
==
task_subtype_limiter
)
cost
=
1
.
f
*
(
wscale
*
count_i
)
*
count_i
;
else
if
(
t
->
subtype
==
task_subtype_rt_inject
){
else
if
(
t
->
subtype
==
task_subtype_rt_inject
)
{
/* TODO: does this make sense? */
cost
=
1
.
f
*
wscale
*
scount_i
*
count_i
;
}
else
...
...
@@ -1503,7 +1503,7 @@ void scheduler_reweight(struct scheduler *s, int verbose) {
}
else
{
cost
=
2
.
f
*
(
wscale
*
count_i
)
*
count_j
*
sid_scale
[
t
->
flags
];
}
}
else
if
(
t
->
subtype
==
task_subtype_rt_inject
){
}
else
if
(
t
->
subtype
==
task_subtype_rt_inject
)
{
/* TODO: does this make sense? */
cost
=
1
.
f
*
wscale
*
scount_i
*
count_i
;
}
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