Commit 7006e143 authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

cell_getid() now moved to cell.h and uniquely defined there.

parent ef4609fc
...@@ -164,6 +164,12 @@ struct cell { ...@@ -164,6 +164,12 @@ struct cell {
} __attribute__((aligned(64))); } __attribute__((aligned(64)));
/* Convert cell location to ID. */
#define cell_getid(cdim, i, j, k) \
((int)(k) + (cdim)[2] * ((int)(j) + (cdim)[1] * (int)(i)))
/* Function prototypes. */ /* Function prototypes. */
void cell_split(struct cell *c); void cell_split(struct cell *c);
int cell_locktree(struct cell *c); int cell_locktree(struct cell *c);
......
...@@ -65,10 +65,6 @@ const char *engine_policy_names[10] = { ...@@ -65,10 +65,6 @@ const char *engine_policy_names[10] = {
"none", "rand", "steal", "keep", "block", "none", "rand", "steal", "keep", "block",
"fix_dt", "multi_dt", "cpu_tight", "mpi", "numa_affinity"}; "fix_dt", "multi_dt", "cpu_tight", "mpi", "numa_affinity"};
/* Convert cell location to ID. */
#define cell_getid(cdim, i, j, k) \
((int)(k) + (cdim)[2] * ((int)(j) + (cdim)[1] * (int)(i)))
/** The rank of the engine as a global variable (for messages). */ /** The rank of the engine as a global variable (for messages). */
int engine_rank; int engine_rank;
......
...@@ -37,10 +37,6 @@ struct engine; ...@@ -37,10 +37,6 @@ struct engine;
#define space_maxreldx 0.25f #define space_maxreldx 0.25f
#define space_qstack 2048 #define space_qstack 2048
/* Convert cell location to ID. */
#define cell_getid(cdim, i, j, k) \
((int)(k) + (cdim)[2] * ((int)(j) + (cdim)[1] * (int)(i)))
/* Split size. */ /* Split size. */
extern int space_splitsize; extern int space_splitsize;
extern int space_maxsize; extern int space_maxsize;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment