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
9b411518
Commit
9b411518
authored
Jul 09, 2015
by
Peter Eastman
Browse files
Updated AMOEBA code to reflect changes to CudaNonbondedUtilities
parent
f065df01
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
plugins/amoeba/platforms/cuda/src/AmoebaCudaKernels.cpp
plugins/amoeba/platforms/cuda/src/AmoebaCudaKernels.cpp
+4
-4
No files found.
plugins/amoeba/platforms/cuda/src/AmoebaCudaKernels.cpp
View file @
9b411518
...
@@ -2407,7 +2407,7 @@ void CudaCalcAmoebaVdwForceKernel::initialize(const System& system, const Amoeba
...
@@ -2407,7 +2407,7 @@ void CudaCalcAmoebaVdwForceKernel::initialize(const System& system, const Amoeba
replacements
[
"TAPER_C5"
]
=
cu
.
doubleToString
(
6
/
pow
(
taperCutoff
-
cutoff
,
5.0
));
replacements
[
"TAPER_C5"
]
=
cu
.
doubleToString
(
6
/
pow
(
taperCutoff
-
cutoff
,
5.0
));
bool
useCutoff
=
(
force
.
getNonbondedMethod
()
!=
AmoebaVdwForce
::
NoCutoff
);
bool
useCutoff
=
(
force
.
getNonbondedMethod
()
!=
AmoebaVdwForce
::
NoCutoff
);
nonbonded
->
addInteraction
(
useCutoff
,
useCutoff
,
true
,
force
.
getCutoff
(),
exclusions
,
nonbonded
->
addInteraction
(
useCutoff
,
useCutoff
,
true
,
force
.
getCutoff
(),
exclusions
,
cu
.
replaceStrings
(
CudaAmoebaKernelSources
::
amoebaVdwForce2
,
replacements
),
force
.
getForceGroup
()
);
cu
.
replaceStrings
(
CudaAmoebaKernelSources
::
amoebaVdwForce2
,
replacements
),
0
);
// Create the other kernels.
// Create the other kernels.
...
@@ -2429,8 +2429,8 @@ double CudaCalcAmoebaVdwForceKernel::execute(ContextImpl& context, bool includeF
...
@@ -2429,8 +2429,8 @@ double CudaCalcAmoebaVdwForceKernel::execute(ContextImpl& context, bool includeF
void
*
prepareArgs
[]
=
{
&
cu
.
getForce
().
getDevicePointer
(),
&
cu
.
getPosq
().
getDevicePointer
(),
&
tempPosq
->
getDevicePointer
(),
void
*
prepareArgs
[]
=
{
&
cu
.
getForce
().
getDevicePointer
(),
&
cu
.
getPosq
().
getDevicePointer
(),
&
tempPosq
->
getDevicePointer
(),
&
bondReductionAtoms
->
getDevicePointer
(),
&
bondReductionFactors
->
getDevicePointer
()};
&
bondReductionAtoms
->
getDevicePointer
(),
&
bondReductionFactors
->
getDevicePointer
()};
cu
.
executeKernel
(
prepareKernel
,
prepareArgs
,
cu
.
getPaddedNumAtoms
());
cu
.
executeKernel
(
prepareKernel
,
prepareArgs
,
cu
.
getPaddedNumAtoms
());
nonbonded
->
prepareInteractions
();
nonbonded
->
prepareInteractions
(
1
);
nonbonded
->
computeInteractions
();
nonbonded
->
computeInteractions
(
1
);
void
*
spreadArgs
[]
=
{
&
cu
.
getForce
().
getDevicePointer
(),
&
tempForces
->
getDevicePointer
(),
&
bondReductionAtoms
->
getDevicePointer
(),
&
bondReductionFactors
->
getDevicePointer
()};
void
*
spreadArgs
[]
=
{
&
cu
.
getForce
().
getDevicePointer
(),
&
tempForces
->
getDevicePointer
(),
&
bondReductionAtoms
->
getDevicePointer
(),
&
bondReductionFactors
->
getDevicePointer
()};
cu
.
executeKernel
(
spreadKernel
,
spreadArgs
,
cu
.
getPaddedNumAtoms
());
cu
.
executeKernel
(
spreadKernel
,
spreadArgs
,
cu
.
getPaddedNumAtoms
());
tempPosq
->
copyTo
(
cu
.
getPosq
());
tempPosq
->
copyTo
(
cu
.
getPosq
());
...
@@ -2534,7 +2534,7 @@ void CudaCalcAmoebaWcaDispersionForceKernel::initialize(const System& system, co
...
@@ -2534,7 +2534,7 @@ void CudaCalcAmoebaWcaDispersionForceKernel::initialize(const System& system, co
// just so that CudaNonbondedUtilities will keep track of the tiles.
// just so that CudaNonbondedUtilities will keep track of the tiles.
vector
<
vector
<
int
>
>
exclusions
;
vector
<
vector
<
int
>
>
exclusions
;
cu
.
getNonbondedUtilities
().
addInteraction
(
false
,
false
,
false
,
cu
.
getNonbondedUtilities
().
getCutoffDistance
()
,
exclusions
,
""
,
force
.
getForceGroup
());
cu
.
getNonbondedUtilities
().
addInteraction
(
false
,
false
,
false
,
1.0
,
exclusions
,
""
,
force
.
getForceGroup
());
cu
.
addForce
(
new
ForceInfo
(
force
));
cu
.
addForce
(
new
ForceInfo
(
force
));
}
}
...
...
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