"...git@developer.sourcefind.cn:2222/OpenDAS/flashmla.git" did not exist on "7949f854f4029d242c7bc72525de31ab050a8c0d"
Commit 59e00d79 authored by Peter Eastman's avatar Peter Eastman
Browse files

Fixed error in previous checkin

parent df5654ef
...@@ -45,6 +45,10 @@ ...@@ -45,6 +45,10 @@
using namespace OpenMM; using namespace OpenMM;
using namespace std; using namespace std;
#ifndef CL_DEVICE_COMPUTE_CAPABILITY_MAJOR_NV
#define CL_DEVICE_COMPUTE_CAPABILITY_MAJOR_NV 0x4000
#endif
OpenCLContext::OpenCLContext(int numParticles, int deviceIndex) : time(0.0), stepCount(0), computeForceCount(0), posq(NULL), velm(NULL), OpenCLContext::OpenCLContext(int numParticles, int deviceIndex) : time(0.0), stepCount(0), computeForceCount(0), posq(NULL), velm(NULL),
forceBuffers(NULL), energyBuffer(NULL), atomIndex(NULL), integration(NULL), nonbonded(NULL) { forceBuffers(NULL), energyBuffer(NULL), atomIndex(NULL), integration(NULL), nonbonded(NULL) {
try { try {
...@@ -63,7 +67,6 @@ OpenCLContext::OpenCLContext(int numParticles, int deviceIndex) : time(0.0), ste ...@@ -63,7 +67,6 @@ OpenCLContext::OpenCLContext(int numParticles, int deviceIndex) : time(0.0), ste
int processingElementsPerComputeUnit = 1; int processingElementsPerComputeUnit = 1;
if (devices[i].getInfo<CL_DEVICE_EXTENSIONS>().find("cl_nv_device_attribute_query") != string::npos) { if (devices[i].getInfo<CL_DEVICE_EXTENSIONS>().find("cl_nv_device_attribute_query") != string::npos) {
cl_uint computeCapabilityMajor; cl_uint computeCapabilityMajor;
const cl_device_info CL_DEVICE_COMPUTE_CAPABILITY_MAJOR_NV = 0x4000;
clGetDeviceInfo(devices[i](), CL_DEVICE_COMPUTE_CAPABILITY_MAJOR_NV, sizeof(cl_uint), &computeCapabilityMajor, NULL); clGetDeviceInfo(devices[i](), CL_DEVICE_COMPUTE_CAPABILITY_MAJOR_NV, sizeof(cl_uint), &computeCapabilityMajor, NULL);
processingElementsPerComputeUnit = (computeCapabilityMajor < 2 ? 8 : 32); processingElementsPerComputeUnit = (computeCapabilityMajor < 2 ? 8 : 32);
} }
......
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