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
87dd3823
Commit
87dd3823
authored
Oct 10, 2014
by
peastman
Browse files
Optimizations to AMOEBA
parent
3d1b2186
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
21 deletions
+11
-21
plugins/amoeba/platforms/cuda/src/kernels/multipoleInducedField.cu
...moeba/platforms/cuda/src/kernels/multipoleInducedField.cu
+7
-11
plugins/amoeba/platforms/cuda/src/kernels/pmeElectrostaticPairForce.cu
...a/platforms/cuda/src/kernels/pmeElectrostaticPairForce.cu
+2
-5
plugins/amoeba/platforms/cuda/src/kernels/pmeElectrostaticPairForceNoQuadrupoles.cu
...uda/src/kernels/pmeElectrostaticPairForceNoQuadrupoles.cu
+2
-5
No files found.
plugins/amoeba/platforms/cuda/src/kernels/multipoleInducedField.cu
View file @
87dd3823
...
@@ -87,17 +87,13 @@ __device__ void computeOneInteraction(AtomData& atom1, AtomData& atom2, real3 de
...
@@ -87,17 +87,13 @@ __device__ void computeOneInteraction(AtomData& atom1, AtomData& atom2, real3 de
real
scale3
=
1
;
real
scale3
=
1
;
real
scale5
=
1
;
real
scale5
=
1
;
real
damp
=
atom1
.
damp
*
atom2
.
damp
;
real
damp
=
atom1
.
damp
*
atom2
.
damp
;
if
(
damp
!=
0
)
{
real
ratio
=
(
r
/
damp
);
real
ratio
=
(
r
/
damp
);
ratio
=
ratio
*
ratio
*
ratio
;
ratio
=
ratio
*
ratio
*
ratio
;
float
pgamma
=
atom1
.
thole
<
atom2
.
thole
?
atom1
.
thole
:
atom2
.
thole
;
float
pgamma
=
atom1
.
thole
<
atom2
.
thole
?
atom1
.
thole
:
atom2
.
thole
;
damp
=
damp
==
0
?
0
:
-
pgamma
*
ratio
;
damp
=
-
pgamma
*
ratio
;
real
expdamp
=
EXP
(
damp
);
if
(
damp
>
-
50
)
{
scale3
=
1
-
expdamp
;
real
expdamp
=
EXP
(
damp
);
scale5
=
1
-
expdamp
*
(
1
-
damp
);
scale3
=
1
-
expdamp
;
scale5
=
1
-
expdamp
*
(
1
-
damp
);
}
}
real
dsc3
=
scale3
;
real
dsc3
=
scale3
;
real
dsc5
=
scale5
;
real
dsc5
=
scale5
;
real
r3
=
(
r
*
r2
);
real
r3
=
(
r
*
r2
);
...
...
plugins/amoeba/platforms/cuda/src/kernels/pmeElectrostaticPairForce.cu
View file @
87dd3823
...
@@ -211,7 +211,6 @@ computeOneInteractionF2NoScale(
...
@@ -211,7 +211,6 @@ computeOneInteractionF2NoScale(
real
pgamma
=
atom1
.
thole
<
atom2
.
thole
?
atom1
.
thole
:
atom2
.
thole
;
real
pgamma
=
atom1
.
thole
<
atom2
.
thole
?
atom1
.
thole
:
atom2
.
thole
;
real
ratio
=
RECIP
(
rr1
*
damp
);
real
ratio
=
RECIP
(
rr1
*
damp
);
damp
=
-
pgamma
*
ratio
*
ratio
*
ratio
;
damp
=
-
pgamma
*
ratio
*
ratio
*
ratio
;
damp
=
damp
<
-
50
?
0
:
damp
;
}
}
real
scale5
=
(
damp
==
0
)
?
1
:
(
1
-
(
1
-
damp
)
*
EXP
(
damp
));
real
scale5
=
(
damp
==
0
)
?
1
:
(
1
-
(
1
-
damp
)
*
EXP
(
damp
));
...
@@ -358,8 +357,7 @@ computeOneInteractionF2NoScale(
...
@@ -358,8 +357,7 @@ computeOneInteractionF2NoScale(
ftm22
+=
gfi1
*
yr
;
ftm22
+=
gfi1
*
yr
;
ftm23
+=
gfi1
*
zr
;
ftm23
+=
gfi1
*
zr
;
if
(
damp
!=
0
)
{
{
real
expdamp
=
EXP
(
damp
);
real
expdamp
=
EXP
(
damp
);
real
temp3
=
-
1.5
f
*
damp
*
expdamp
*
rr1
*
rr1
;
real
temp3
=
-
1.5
f
*
damp
*
expdamp
*
rr1
*
rr1
;
real
temp5
=
-
damp
;
real
temp5
=
-
damp
;
...
@@ -556,8 +554,7 @@ computeOneInteractionF2NoScale(
...
@@ -556,8 +554,7 @@ computeOneInteractionF2NoScale(
ftm22
+=
gfi1
*
yr
;
ftm22
+=
gfi1
*
yr
;
ftm23
+=
gfi1
*
zr
;
ftm23
+=
gfi1
*
zr
;
if
(
damp
!=
0
)
{
{
real
expdamp
=
EXP
(
damp
);
real
expdamp
=
EXP
(
damp
);
real
temp3
=
-
1.5
f
*
damp
*
expdamp
*
rr1
*
rr1
;
real
temp3
=
-
1.5
f
*
damp
*
expdamp
*
rr1
*
rr1
;
real
temp5
=
-
damp
;
real
temp5
=
-
damp
;
...
...
plugins/amoeba/platforms/cuda/src/kernels/pmeElectrostaticPairForceNoQuadrupoles.cu
View file @
87dd3823
...
@@ -129,7 +129,6 @@ computeOneInteractionF2NoScale(
...
@@ -129,7 +129,6 @@ computeOneInteractionF2NoScale(
real
pgamma
=
atom1
.
thole
<
atom2
.
thole
?
atom1
.
thole
:
atom2
.
thole
;
real
pgamma
=
atom1
.
thole
<
atom2
.
thole
?
atom1
.
thole
:
atom2
.
thole
;
real
ratio
=
RECIP
(
rr1
*
damp
);
real
ratio
=
RECIP
(
rr1
*
damp
);
damp
=
-
pgamma
*
ratio
*
ratio
*
ratio
;
damp
=
-
pgamma
*
ratio
*
ratio
*
ratio
;
damp
=
damp
<
-
50
?
0
:
damp
;
}
}
real
scale5
=
(
damp
==
0
)
?
1
:
(
1
-
(
1
-
damp
)
*
EXP
(
damp
));
real
scale5
=
(
damp
==
0
)
?
1
:
(
1
-
(
1
-
damp
)
*
EXP
(
damp
));
...
@@ -232,8 +231,7 @@ computeOneInteractionF2NoScale(
...
@@ -232,8 +231,7 @@ computeOneInteractionF2NoScale(
ftm22
+=
gfi1
*
yr
;
ftm22
+=
gfi1
*
yr
;
ftm23
+=
gfi1
*
zr
;
ftm23
+=
gfi1
*
zr
;
if
(
damp
!=
0
)
{
{
real
expdamp
=
EXP
(
damp
);
real
expdamp
=
EXP
(
damp
);
real
temp3
=
-
1.5
f
*
damp
*
expdamp
*
rr1
*
rr1
;
real
temp3
=
-
1.5
f
*
damp
*
expdamp
*
rr1
*
rr1
;
real
temp5
=
-
damp
;
real
temp5
=
-
damp
;
...
@@ -376,8 +374,7 @@ computeOneInteractionF2NoScale(
...
@@ -376,8 +374,7 @@ computeOneInteractionF2NoScale(
ftm22
+=
gfi1
*
yr
;
ftm22
+=
gfi1
*
yr
;
ftm23
+=
gfi1
*
zr
;
ftm23
+=
gfi1
*
zr
;
if
(
damp
!=
0
)
{
{
real
expdamp
=
EXP
(
damp
);
real
expdamp
=
EXP
(
damp
);
real
temp3
=
-
1.5
f
*
damp
*
expdamp
*
rr1
*
rr1
;
real
temp3
=
-
1.5
f
*
damp
*
expdamp
*
rr1
*
rr1
;
real
temp5
=
-
damp
;
real
temp5
=
-
damp
;
...
...
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