"vscode:/vscode.git/clone" did not exist on "2abfbb43e7a537e8d262c3d51e2c56dd0094899b"
Commit b6790d94 authored by Mark Friedrichs's avatar Mark Friedrichs
Browse files

maxTorqueBufferIndex was off by 1; affected small systems

parent e7f2cc29
...@@ -2818,6 +2818,7 @@ void amoebaGpuBuildOutputBuffers( amoebaGpuContext amoebaGpu, int hasAmoebaGener ...@@ -2818,6 +2818,7 @@ void amoebaGpuBuildOutputBuffers( amoebaGpuContext amoebaGpu, int hasAmoebaGener
// use the Cuda force output buffers for mapping torques onto forces, if max torque buffer count < number of buffers // use the Cuda force output buffers for mapping torques onto forces, if max torque buffer count < number of buffers
amoebaGpu->amoebaSim.maxTorqueBufferIndex++;
if( amoebaGpu->amoebaSim.maxTorqueBufferIndex > outputBuffers ){ if( amoebaGpu->amoebaSim.maxTorqueBufferIndex > outputBuffers ){
amoebaGpu->psTorqueMapForce4 = new CUDAStream<float4>(paddedNumberOfAtoms, amoebaGpu->amoebaSim.maxTorqueBufferIndex, "torqueMapForce"); amoebaGpu->psTorqueMapForce4 = new CUDAStream<float4>(paddedNumberOfAtoms, amoebaGpu->amoebaSim.maxTorqueBufferIndex, "torqueMapForce");
amoebaGpu->torqueMapForce4Delete = 1; amoebaGpu->torqueMapForce4Delete = 1;
......
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