Commit 70f110b2 authored by berenger-bramas's avatar berenger-bramas
Browse files

Use precomputed FTreeCordinate in kernels.

git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/scalfmm/scalfmm/trunk@108 2616d619-271b-44dc-8df4-d4a8f33a7222
parent fa0db644
......@@ -837,14 +837,11 @@ public:
*
*/
void M2L(CellClass* const FRestrict pole, const CellClass* distantNeighbors[208],
const FTreeCoordinate& inCurrentPosition, FTreeCoordinate inNeighborsPosition[208], const int size, const int inLevel) {
const FTreeCoordinate& coordCenter, FTreeCoordinate inNeighborsPosition[208], const int size, const int inLevel) {
FTRACE( FTrace::Controller.enterFunction(FTrace::KERNELS, __FUNCTION__ , __FILE__ , __LINE__) );
FTreeCoordinate coordCenter;
coordCenter.setPositionFromMorton(pole->getMortonIndex(),inLevel);
for(int idxSize = 0 ; idxSize < size ; ++idxSize){
FTreeCoordinate coordNeighbors;
coordNeighbors.setPositionFromMorton(distantNeighbors[idxSize]->getMortonIndex(),inLevel);
const FTreeCoordinate& coordNeighbors = inNeighborsPosition[idxSize];
// printf("Morton = %lld\n",pole->getMortonIndex());
//printf("\tMorton Neighbors = %lld\n",distantNeighbors[idxSize]->getMortonIndex());
......
......@@ -909,14 +909,11 @@ public:
*
*/
void M2L(CellClass* const FRestrict pole, const CellClass* distantNeighbors[208],
const FTreeCoordinate& inCurrentPosition, FTreeCoordinate inNeighborsPosition[208], const int size, const int inLevel) {
const FTreeCoordinate& coordCenter, FTreeCoordinate inNeighborsPosition[208], const int size, const int inLevel) {
FTRACE( FTrace::Controller.enterFunction(FTrace::KERNELS, __FUNCTION__ , __FILE__ , __LINE__) );
FTreeCoordinate coordCenter;
coordCenter.setPositionFromMorton(pole->getMortonIndex(),inLevel);
for(int idxSize = 0 ; idxSize < size ; ++idxSize){
FTreeCoordinate coordNeighbors;
coordNeighbors.setPositionFromMorton(distantNeighbors[idxSize]->getMortonIndex(),inLevel);
const FTreeCoordinate& coordNeighbors = inNeighborsPosition[idxSize];
///printf("Morton = %lld\n",pole->getMortonIndex());
///printf("\tMorton Neighbors = %lld\n",distantNeighbors[idxSize]->getMortonIndex());
......
......@@ -1213,14 +1213,11 @@ public:
*
*/
void M2L(CellClass* const FRestrict pole, const CellClass* distantNeighbors[208],
const FTreeCoordinate& inCurrentPosition, FTreeCoordinate inNeighborsPosition[208], const int size, const int inLevel) {
const FTreeCoordinate& coordCenter, FTreeCoordinate inNeighborsPosition[208], const int size, const int inLevel) {
FTRACE( FTrace::Controller.enterFunction(FTrace::KERNELS, __FUNCTION__ , __FILE__ , __LINE__) );
FTreeCoordinate coordCenter;
coordCenter.setPositionFromMorton(pole->getMortonIndex(),inLevel);
for(int idxSize = 0 ; idxSize < size ; ++idxSize){
FTreeCoordinate coordNeighbors;
coordNeighbors.setPositionFromMorton(distantNeighbors[idxSize]->getMortonIndex(),inLevel);
const FTreeCoordinate& coordNeighbors = inNeighborsPosition[idxSize];
//printf("Morton = %lld\n",pole->getMortonIndex());
//printf("\tMorton Neighbors = %lld\n",distantNeighbors[idxSize]->getMortonIndex());
......
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