Commit 32131eee authored by Francois Tessier's avatar Francois Tessier

In case of aggregation onto NVRAM, dynamically create a number of files equal...

In case of aggregation onto NVRAM, dynamically create a number of files equal to the number of aggregation buffers.
parent 43e3e4f8
......@@ -72,8 +72,21 @@ void Tapioca::Init (int64_t *chunkCount, int *chunkSize, int64_t *chunkOffset,
void Tapioca::setAggregationTier ( mem_t mem, char* fileName )
{
char file1[100], file2[100];
if ( mem == NVR ) {
strcpy ( file1, fileName );
strcat ( file1, "1.agg");
strcpy ( file2, fileName );
strcat ( file2, "2.agg");
this->memBuffer0.memAlloc ( this->bufferSize_, mem, this->amAnAggr_, file1, this->subComm_ );
this->memBuffer1.memAlloc ( this->bufferSize_, mem, this->amAnAggr_, file2, this->subComm_ );
}
else {
this->memBuffer0.memAlloc ( this->bufferSize_, mem, this->amAnAggr_, fileName, this->subComm_ );
this->memBuffer1.memAlloc ( this->bufferSize_, mem, this->amAnAggr_, fileName, this->subComm_ );
}
}
......@@ -95,6 +108,7 @@ void Tapioca::Finalize ()
this->memBuffer0.memFree ();
this->memBuffer1.memFree ();
this->memTarget.memFlush ();
this->memTarget.memFree ();
MPI_Comm_free (&this->subComm_);
}
......
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