Commit aeb2f4ac authored by Peter Eastman's avatar Peter Eastman
Browse files

Reduced memory use for random numbers. Also reduced the frequency of reordering water molecules.

parent 8055a541
......@@ -47,7 +47,7 @@ using namespace std;
static void calcForces(OpenMMContextImpl& context, CudaPlatform::PlatformData& data) {
_gpuContext* gpu = data.gpu;
if (data.stepCount%100 == 0)
if (data.stepCount%200 == 0)
gpuReorderAtoms(gpu);
data.stepCount++;
kClearForces(gpu);
......
......@@ -1198,7 +1198,7 @@ int gpuAllocateInitialBuffers(gpuContext gpu)
gpu->psAtomIndex->Upload();
// Determine randoms
gpu->seed = 1;
gpu->sim.randomFrames = 95;
gpu->sim.randomFrames = 20;
gpu->sim.randomIterations = gpu->sim.randomFrames;
gpu->sim.randoms = gpu->sim.randomFrames * gpu->sim.paddedNumberOfAtoms - 5 * GRID;
gpu->sim.totalRandoms = gpu->sim.randoms + gpu->sim.paddedNumberOfAtoms;
......
......@@ -48,7 +48,7 @@ static const float RGAS = BOLTZMANN * AVOGADRO; // (J
static const float BOLTZ = (RGAS / KILO); // (kJ/(mol K))
void testGaussian() {
_gpuContext* gpu = (_gpuContext*) gpuInit(1000);
_gpuContext* gpu = (_gpuContext*) gpuInit(5000);
gpu->sim.Yv = 1.0;
gpu->sim.Yx = 1.0;
gpu->sim.V = 1.0;
......
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