Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Q
QuickSched
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
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
QuickSched
Commits
4c283d4f
Commit
4c283d4f
authored
10 years ago
by
Pedro Gonnet
Browse files
Options
Downloads
Patches
Plain Diff
more cleaning up.
parent
ed61302f
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
examples/test_bh.c
+2
-26
2 additions, 26 deletions
examples/test_bh.c
with
2 additions
and
26 deletions
examples/test_bh.c
+
2
−
26
View file @
4c283d4f
...
...
@@ -42,13 +42,11 @@
#define const_G 1 // 6.6738e-8
#define dist_min 0.5
/* Used for legacy walk only */
#define dist_cutoff_ratio 1.5
#define iact_pair_direct iact_pair_direct_sorted
#define ICHECK -1
#define NO_SANITY_CHECKS
#define NO_COM_AS_TASK
#define COUNTERS
#define MANY_MULTIPOLES
#define NO_COUNTERS
/** Data structure for the particles. */
struct
part
{
...
...
@@ -62,12 +60,6 @@ struct part {
int
id
;
};
// __attribute__((aligned(64)));
/** Data structure for the sorted particle positions. */
struct
index
{
int
ind
;
float
d
;
};
struct
multipole
{
double
com
[
3
];
float
mass
;
...
...
@@ -106,7 +98,6 @@ enum task_type {
task_type_self
=
0
,
task_type_pair
,
task_type_self_pc
,
task_type_pair_direct
,
task_type_com
,
task_type_count
};
...
...
@@ -620,18 +611,6 @@ static inline void iact_self_pc(struct cell *c, struct cell *leaf) {
}
}
/**
* @brief Starts the recursive tree walk of a given leaf
*/
void
init_multipole_walk
(
struct
cell
*
root
,
struct
cell
*
leaf
)
{
/* Pre-fetch the leaf's particles */
__builtin_prefetch
(
leaf
->
parts
,
1
,
3
);
/* Start the recursion */
iact_self_pc
(
root
,
leaf
);
}
/**
* @brief Compute the interactions between all particles in a cell
* and all particles in the other cell (N^2 algorithm)
...
...
@@ -1215,11 +1194,8 @@ void test_bh(int N, int nr_threads, int runs, char *fileName) {
case
task_type_pair
:
iact_pair
(
d
[
0
],
d
[
1
]);
break
;
case
task_type_pair_direct
:
iact_pair_direct
(
d
[
0
],
d
[
1
]);
break
;
case
task_type_self_pc
:
i
nit_multipole_walk
(
d
[
0
],
d
[
1
]);
i
act_self_pc
(
d
[
0
],
d
[
1
]);
break
;
case
task_type_com
:
comp_com
(
d
[
0
]);
...
...
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