Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
SWIFTsim
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
SWIFT
SWIFTsim
Commits
8f149250
Commit
8f149250
authored
1 year ago
by
Mladen Ivkovic
Committed by
Matthieu Schaller
1 year ago
Browse files
Options
Downloads
Patches
Plain Diff
skip particle timestep data collection in space_split.c when running without RT
parent
c029e413
No related branches found
No related tags found
3 merge requests
!1887
Updating . . .
,
!1878
updating working branch
,
!1774
skip particle timestep data collection in space_split.c when running without RT
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/space_split.c
+20
-8
20 additions, 8 deletions
src/space_split.c
with
20 additions
and
8 deletions
src/space_split.c
+
20
−
8
View file @
8f149250
...
...
@@ -94,6 +94,7 @@ void space_split_recursive(struct space *s, struct cell *c,
struct
sink
*
sinks
=
c
->
sinks
.
parts
;
struct
engine
*
e
=
s
->
e
;
const
integertime_t
ti_current
=
e
->
ti_current
;
const
int
with_rt
=
e
->
policy
&
engine_policy_rt
;
/* Set the top level cell tpid. Doing it here ensures top level cells
* have the same tpid as their progeny. */
...
...
@@ -468,6 +469,10 @@ void space_split_recursive(struct space *s, struct cell *c,
ti_black_holes_end_max
=
0
;
ti_black_holes_beg_max
=
0
;
ti_rt_end_min
=
max_nr_timesteps
;
ti_rt_beg_max
=
0
;
ti_rt_min_step_size
=
max_nr_timesteps
;
/* parts: Get dt_min/dt_max and h_max. */
for
(
int
k
=
0
;
k
<
count
;
k
++
)
{
#ifdef SWIFT_DEBUG_CHECKS
...
...
@@ -482,19 +487,26 @@ void space_split_recursive(struct space *s, struct cell *c,
const
timebin_t
time_bin_rt
=
parts
[
k
].
rt_time_data
.
time_bin
;
const
integertime_t
ti_end
=
get_integer_time_end
(
ti_current
,
time_bin
);
const
integertime_t
ti_beg
=
get_integer_time_begin
(
ti_current
,
time_bin
);
const
integertime_t
ti_rt_end
=
get_integer_time_end
(
ti_current
,
time_bin_rt
);
const
integertime_t
ti_rt_beg
=
get_integer_time_begin
(
ti_current
,
time_bin_rt
);
const
integertime_t
ti_rt_step
=
get_integer_timestep
(
time_bin_rt
);
ti_hydro_end_min
=
min
(
ti_hydro_end_min
,
ti_end
);
ti_hydro_end_max
=
max
(
ti_hydro_end_max
,
ti_end
);
ti_hydro_beg_max
=
max
(
ti_hydro_beg_max
,
ti_beg
);
ti_rt_end_min
=
min
(
ti_rt_end_min
,
ti_rt_end
);
ti_rt_beg_max
=
max
(
ti_rt_beg_max
,
ti_rt_beg
);
ti_rt_min_step_size
=
min
(
ti_rt_min_step_size
,
ti_rt_step
);
if
(
with_rt
)
{
/* Contrary to other physics, RT doesn't have its own particle type.
* So collect time step data from particles only when we're running
* with RT. Otherwise, we may find cells which are active or in
* impossible timezones. Skipping this check results in cells having
* RT times = max_nr_timesteps or zero, respecively. */
const
integertime_t
ti_rt_end
=
get_integer_time_end
(
ti_current
,
time_bin_rt
);
const
integertime_t
ti_rt_beg
=
get_integer_time_begin
(
ti_current
,
time_bin_rt
);
const
integertime_t
ti_rt_step
=
get_integer_timestep
(
time_bin_rt
);
ti_rt_end_min
=
min
(
ti_rt_end_min
,
ti_rt_end
);
ti_rt_beg_max
=
max
(
ti_rt_beg_max
,
ti_rt_beg
);
ti_rt_min_step_size
=
min
(
ti_rt_min_step_size
,
ti_rt_step
);
}
h_max
=
max
(
h_max
,
parts
[
k
].
h
);
...
...
This diff is collapsed.
Click to expand it.
Yolan Uyttenhove
@yuyttenhove
mentioned in commit
8dc73448
·
1 year ago
mentioned in commit
8dc73448
mentioned in commit 8dc734482f426cc764b0b2ed86ed73f0f26cda91
Toggle commit list
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment