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
543530f0
Commit
543530f0
authored
8 years ago
by
Matthieu Schaller
Browse files
Options
Downloads
Patches
Plain Diff
Same for the serial i/o version.
parent
b7187582
No related branches found
No related tags found
1 merge request
!310
Star particles and gparts links over MPI
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/serial_io.c
+4
-4
4 additions, 4 deletions
src/serial_io.c
with
4 additions
and
4 deletions
src/serial_io.c
+
4
−
4
View file @
543530f0
...
...
@@ -434,8 +434,8 @@ void read_ic_serial(char* fileName, const struct UnitSystem* internal_units,
/* GADGET has only cubic boxes (in cosmological mode) */
double
boxSize
[
3
]
=
{
0
.
0
,
-
1
.
0
,
-
1
.
0
};
/* GADGET has 6 particle types. We only keep the type 0 & 1 for now*/
int
numParticles
[
NUM_PARTICLE_TYPES
]
=
{
0
};
int
numParticles_highWord
[
NUM_PARTICLE_TYPES
]
=
{
0
};
long
long
numParticles
[
NUM_PARTICLE_TYPES
]
=
{
0
};
long
long
numParticles_highWord
[
NUM_PARTICLE_TYPES
]
=
{
0
};
size_t
N
[
NUM_PARTICLE_TYPES
]
=
{
0
};
long
long
N_total
[
NUM_PARTICLE_TYPES
]
=
{
0
};
long
long
offset
[
NUM_PARTICLE_TYPES
]
=
{
0
};
...
...
@@ -482,8 +482,8 @@ void read_ic_serial(char* fileName, const struct UnitSystem* internal_units,
readAttribute
(
h_grp
,
"Flag_Entropy_ICs"
,
INT
,
flag_entropy_temp
);
*
flag_entropy
=
flag_entropy_temp
[
0
];
readAttribute
(
h_grp
,
"BoxSize"
,
DOUBLE
,
boxSize
);
readAttribute
(
h_grp
,
"NumPart_Total"
,
UINT
,
numParticles
);
readAttribute
(
h_grp
,
"NumPart_Total_HighWord"
,
UINT
,
numParticles_highWord
);
readAttribute
(
h_grp
,
"NumPart_Total"
,
LONGLONG
,
numParticles
);
readAttribute
(
h_grp
,
"NumPart_Total_HighWord"
,
LONGLONG
,
numParticles_highWord
);
for
(
int
ptype
=
0
;
ptype
<
NUM_PARTICLE_TYPES
;
++
ptype
)
N_total
[
ptype
]
=
((
long
long
)
numParticles
[
ptype
])
+
Peter W. Draper
@pdraper
·
Feb 15, 2017
Owner
So this (long long) cast is a noop now.
So this (long long) cast is a noop now.
Please
register
or
sign in
to reply
Matthieu Schaller
@matthieu
·
Feb 15, 2017
Owner
Indeed....
Just removed it. :)
Indeed.... :cry: Just removed it. :)
Please
register
or
sign in
to reply
...
...
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