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
7eded9ce
Commit
7eded9ce
authored
9 years ago
by
Matthieu Schaller
Browse files
Options
Downloads
Patches
Plain Diff
Fixed documentation and MPI-friendly output
parent
22933dc3
No related branches found
No related tags found
2 merge requests
!136
Master
,
!85
Tiny fixes to correctly accomodate the switch between SPH variations
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/debug.c
+9
-1
9 additions, 1 deletion
src/debug.c
with
9 additions
and
1 deletion
src/debug.c
+
9
−
1
View file @
7eded9ce
...
@@ -34,6 +34,7 @@
...
@@ -34,6 +34,7 @@
#include
"./hydro/Default/hydro_debug.h"
#include
"./hydro/Default/hydro_debug.h"
#endif
#endif
extern
int
engine_rank
;
/**
/**
* @brief Looks for the particle with the given id and prints its information to
* @brief Looks for the particle with the given id and prints its information to
...
@@ -55,7 +56,11 @@ void printParticle(struct part *parts, struct xpart *xparts, long long int id,
...
@@ -55,7 +56,11 @@ void printParticle(struct part *parts, struct xpart *xparts, long long int id,
/* Look for the particle. */
/* Look for the particle. */
for
(
i
=
0
;
i
<
N
;
i
++
)
for
(
i
=
0
;
i
<
N
;
i
++
)
if
(
parts
[
i
].
id
==
id
)
{
if
(
parts
[
i
].
id
==
id
)
{
#ifdef WITH_MPI
printf
(
"## [%d] Particle[%d]:
\n
id=%lld"
,
engine_rank
,
i
,
parts
[
i
].
id
);
#else
printf
(
"## Particle[%d]:
\n
id=%lld"
,
i
,
parts
[
i
].
id
);
printf
(
"## Particle[%d]:
\n
id=%lld"
,
i
,
parts
[
i
].
id
);
#endif
hydro_debug_particle
(
&
parts
[
i
],
&
xparts
[
i
]);
hydro_debug_particle
(
&
parts
[
i
],
&
xparts
[
i
]);
found
=
1
;
found
=
1
;
}
}
...
@@ -88,11 +93,14 @@ void printgParticle(struct gpart *parts, long long int id, int N) {
...
@@ -88,11 +93,14 @@ void printgParticle(struct gpart *parts, long long int id, int N) {
* @brief Prints the details of a given particle to stdout
* @brief Prints the details of a given particle to stdout
*
*
* @param p The particle to print
* @param p The particle to print
* @param xp The extended data ot the particle to print
*
*
*/
*/
void
printParticle_single
(
struct
part
*
p
,
struct
xpart
*
xp
)
{
void
printParticle_single
(
struct
part
*
p
,
struct
xpart
*
xp
)
{
printf
(
"## Particle: id=%lld"
,
p
->
id
);
hydro_debug_particle
(
p
,
xp
);
}
}
#ifdef HAVE_METIS
#ifdef HAVE_METIS
...
...
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