Commit cb43a735 authored by BRAMAS Berenger's avatar BRAMAS Berenger

update for clang compatibility

parent fcb8e054
......@@ -41,6 +41,8 @@
#include "FCoreCommon.hpp"
#include <memory>
/**
* @author Berenger Bramas (berenger.bramas@inria.fr)
* @class FFmmAlgorithmThreadProc
......@@ -576,7 +578,7 @@ protected:
//////////////////////////////////////////////////////////////////
// pointer to send
FVector<typename OctreeClass::Iterator> toSend[nbProcess * OctreeHeight];
std::unique_ptr<FVector<typename OctreeClass::Iterator>[]> toSend(new FVector<typename OctreeClass::Iterator>[nbProcess * OctreeHeight]);
// index
long long int*const indexToSend = new long long int[nbProcess * OctreeHeight];
memset(indexToSend, 0, sizeof(long long int) * nbProcess * OctreeHeight);
......@@ -844,10 +846,10 @@ protected:
FLightOctree<CellClass> tempTree;
for(int idxProc = 0 ; idxProc < nbProcess ; ++idxProc){
if(recvBuffer[idxLevel * nbProcess + idxProc]){
const int toReceiveFromProcAtLevel = recvBuffer[idxLevel * nbProcess + idxProc]->FMpiBufferReader::getValue<int>();
const int toReceiveFromProcAtLevel = recvBuffer[idxLevel * nbProcess + idxProc]->template getValue<int>();
for(int idxCell = 0 ; idxCell < toReceiveFromProcAtLevel ; ++idxCell){
const MortonIndex cellIndex = recvBuffer[idxLevel * nbProcess + idxProc]->FMpiBufferReader::getValue<MortonIndex>();
const MortonIndex cellIndex = recvBuffer[idxLevel * nbProcess + idxProc]->template getValue<MortonIndex>();
CellClass* const newCell = new CellClass;
newCell->setMortonIndex(cellIndex);
......
......@@ -39,6 +39,8 @@
#include "FCoreCommon.hpp"
#include <memory>
/**
* @author Berenger Bramas (berenger.bramas@inria.fr)
* @class FFmmAlgorithmThreadProcPeriodic
......@@ -704,7 +706,7 @@ protected:
//////////////////////////////////////////////////////////////////
// pointer to send
FVector<typename OctreeClass::Iterator> toSend[nbProcess * OctreeHeight];
std::unique_ptr<FVector<typename OctreeClass::Iterator>[]> toSend(new FVector<typename OctreeClass::Iterator>[nbProcess * OctreeHeight]);
// index
long long int*const indexToSend = new long long int[nbProcess * OctreeHeight];
memset(indexToSend, 0, sizeof(long long int) * nbProcess * OctreeHeight);
......@@ -967,10 +969,10 @@ protected:
FLightOctree<CellClass> tempTree;
for(int idxProc = 0 ; idxProc < nbProcess ; ++idxProc){
if(recvBuffer[idxLevel * nbProcess + idxProc]){
const int toReceiveFromProcAtLevel = recvBuffer[idxLevel * nbProcess + idxProc]->FMpiBufferReader::getValue<int>();
const int toReceiveFromProcAtLevel = recvBuffer[idxLevel * nbProcess + idxProc]->template getValue<int>();
for(int idxCell = 0 ; idxCell < toReceiveFromProcAtLevel ; ++idxCell){
const MortonIndex cellIndex = recvBuffer[idxLevel * nbProcess + idxProc]->FMpiBufferReader::getValue<MortonIndex>();
const MortonIndex cellIndex = recvBuffer[idxLevel * nbProcess + idxProc]->template getValue<MortonIndex>();
CellClass* const newCell = new CellClass;
newCell->setMortonIndex(cellIndex);
......
......@@ -66,7 +66,6 @@ int main(int argc, char ** argv){
typedef FSphericalBlasKernel< CellClass, ContainerClass > KernelClass;
typedef FFmmAlgorithmThreadProc<OctreeClass, CellClass, ContainerClass, KernelClass, LeafClass > FmmClass;
typedef FFmmAlgorithmThread<OctreeClass, CellClass, ContainerClass, KernelClass, LeafClass > FmmClassNoProc;
///////////////////////What we do/////////////////////////////
......
Markdown is supported
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