Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
tsoc
openmm
Commits
55ffb75f
Commit
55ffb75f
authored
Aug 05, 2016
by
peastman
Committed by
GitHub
Aug 05, 2016
Browse files
Merge pull request #1550 from peastman/cpuerror
Fixed compilation error with OpenCL on CPU
parents
5782cb5c
2f024f11
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
platforms/opencl/src/kernels/nonbonded_cpu.cl
platforms/opencl/src/kernels/nonbonded_cpu.cl
+6
-0
No files found.
platforms/opencl/src/kernels/nonbonded_cpu.cl
View file @
55ffb75f
...
...
@@ -28,6 +28,7 @@ __kernel void computeNonbonded(
#
endif
PARAMETER_ARGUMENTS
)
{
mixed
energy
=
0
;
INIT_DERIVATIVES
__local
AtomData
localData[TILE_SIZE]
;
//
First
loop:
process
tiles
that
contain
exclusions.
...
...
@@ -87,6 +88,7 @@ __kernel void computeNonbonded(
bool
isExcluded
=
(
atom1
>=
NUM_ATOMS
|
| atom2 >= NUM_ATOMS || !(excl & 0x1));
#endif
real tempEnergy = 0;
const real interactionScale = 0.5f;
COMPUTE_INTERACTION
energy += 0.5f*tempEnergy;
#ifdef USE_SYMMETRIC
...
...
@@ -155,6 +157,7 @@ __kernel void computeNonbonded(
bool isExcluded = (atom1 >= NUM_ATOMS || atom2 >= NUM_ATOMS || !(excl & 0x1));
#endif
real tempEnergy = 0;
const real interactionScale = 1.0f;
COMPUTE_INTERACTION
energy += tempEnergy;
#ifdef USE_SYMMETRIC
...
...
@@ -318,6 +321,7 @@ __kernel void computeNonbonded(
bool isExcluded = (atom1 >= NUM_ATOMS || atom2 >= NUM_ATOMS);
#endif
real tempEnergy = 0;
const real interactionScale = 1.0f;
COMPUTE_INTERACTION
energy += tempEnergy;
#ifdef USE_SYMMETRIC
...
...
@@ -382,6 +386,7 @@ __kernel void computeNonbonded(
bool isExcluded = (atom1 >= NUM_ATOMS |
|
atom2
>=
NUM_ATOMS
)
;
#
endif
real
tempEnergy
=
0
;
const
real
interactionScale
=
1.0f
;
COMPUTE_INTERACTION
energy
+=
tempEnergy
;
#
ifdef
USE_SYMMETRIC
...
...
@@ -441,4 +446,5 @@ __kernel void computeNonbonded(
pos++
;
}
energyBuffer[get_global_id
(
0
)
]
+=
energy
;
SAVE_DERIVATIVES
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment