Skip to content
Snippets Groups Projects
Commit 3033c29c authored by Martin Nolte's avatar Martin Nolte
Browse files

allow looping use STLPolyAllocator< PoolAllocator >

run ./polyallocator 2 10000000

and you notice a growth in memory use

[[Imported from SVN: r6231]]
parent 9e9f3f75
No related branches found
No related tags found
No related merge requests found
......@@ -5,6 +5,7 @@
#include <iostream>
#include <memory>
#include <dune/common/poolallocator.hh>
#include <dune/common/polyallocator.hh>
// A test of the PolyAllocator as used in the GenericGeometries:
......@@ -132,5 +133,15 @@ int main ( int argc, char **argv )
h.test();
}
if( argc > 2 )
{
const int numLoops = atoi( argv[ 2 ] );
for( int i = 0; i < numLoops; ++i )
{
G< Dune::STLPolyAllocator< Dune::PoolAllocator< A, 4096 > > > g( k );
g.test();
}
}
return 0;
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment