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
dc387bc7
Commit
dc387bc7
authored
6 years ago
by
Josh Borrow
Committed by
Matthieu Schaller
6 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fixed more compiler warnings with GIZMO in runner
parent
c06291ad
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/runner.c
+18
-13
18 additions, 13 deletions
src/runner.c
with
18 additions
and
13 deletions
src/runner.c
+
18
−
13
View file @
dc387bc7
...
...
@@ -719,13 +719,10 @@ void runner_do_ghost(struct runner *r, struct cell *c, int timer) {
const
struct
hydro_space
*
hs
=
&
s
->
hs
;
const
struct
cosmology
*
cosmo
=
e
->
cosmology
;
const
struct
chemistry_global_data
*
chemistry
=
e
->
chemistry
;
const
double
time_base
=
e
->
time_base
;
const
integertime_t
ti_end
=
e
->
ti_current
;
const
float
hydro_h_max
=
e
->
hydro_properties
->
h_max
;
const
float
eps
=
e
->
hydro_properties
->
h_tolerance
;
const
float
hydro_eta_dim
=
pow_dimension
(
e
->
hydro_properties
->
eta_neighbours
);
const
int
with_cosmology
=
(
e
->
policy
&
engine_policy_cosmology
);
const
int
max_smoothing_iter
=
e
->
hydro_properties
->
max_smoothing_iterations
;
int
redo
=
0
,
count
=
0
;
...
...
@@ -820,12 +817,14 @@ void runner_do_ghost(struct runner *r, struct cell *c, int timer) {
hydro_reset_gradient
(
p
);
#else
/* As of here, particle force variables will be set. */
/* Calculate the time-step for passing to hydro_prepare_force.
* This is the physical time between the start and end of the
* time-step without any scale-factor powers. */
/* Calculate the time-step for passing to hydro_prepare_force, used
* for the evolution of alpha factors (i.e. those involved in the
* artificial viscosity and thermal conduction terms) */
const
int
with_cosmology
=
(
e
->
policy
&
engine_policy_cosmology
);
const
double
time_base
=
e
->
time_base
;
const
integertime_t
ti_end
=
e
->
ti_current
;
double
dt_alpha
;
if
(
with_cosmology
)
{
const
integertime_t
ti_step
=
get_integer_timestep
(
p
->
time_bin
);
dt_alpha
=
...
...
@@ -834,6 +833,8 @@ void runner_do_ghost(struct runner *r, struct cell *c, int timer) {
dt_alpha
=
get_timestep
(
p
->
time_bin
,
time_base
);
}
/* As of here, particle force variables will be set. */
/* Compute variables required for the force loop */
hydro_prepare_force
(
p
,
xp
,
cosmo
,
dt_alpha
);
...
...
@@ -914,12 +915,14 @@ void runner_do_ghost(struct runner *r, struct cell *c, int timer) {
hydro_reset_gradient
(
p
);
#else
/* As of here, particle force variables will be set. */
/* Calculate the time-step for passing to hydro_prepare_force.
* This is the physical time between the start and end of the time-step
* without any scale-factor powers. */
/* Calculate the time-step for passing to hydro_prepare_force, used for
* the evolution of alpha factors (i.e. those involved in the artificial
* viscosity and thermal conduction terms) */
const
int
with_cosmology
=
(
e
->
policy
&
engine_policy_cosmology
);
const
integertime_t
ti_end
=
e
->
ti_current
;
const
double
time_base
=
e
->
time_base
;
double
dt_alpha
;
if
(
with_cosmology
)
{
const
integertime_t
ti_step
=
get_integer_timestep
(
p
->
time_bin
);
dt_alpha
=
cosmology_get_delta_time
(
cosmo
,
ti_end
-
ti_step
,
ti_end
);
...
...
@@ -927,6 +930,8 @@ void runner_do_ghost(struct runner *r, struct cell *c, int timer) {
dt_alpha
=
get_timestep
(
p
->
time_bin
,
time_base
);
}
/* As of here, particle force variables will be set. */
/* Compute variables required for the force loop */
hydro_prepare_force
(
p
,
xp
,
cosmo
,
dt_alpha
);
...
...
This diff is collapsed.
Click to expand it.
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