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
ebef35a4
Unverified
Commit
ebef35a4
authored
Feb 17, 2021
by
Peter Eastman
Committed by
GitHub
Feb 17, 2021
Browse files
Reduced padding on cutoff (#3025)
parent
6d4abc54
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
platforms/cuda/src/CudaNonbondedUtilities.cpp
platforms/cuda/src/CudaNonbondedUtilities.cpp
+1
-1
platforms/cuda/src/kernels/findInteractingBlocks.cu
platforms/cuda/src/kernels/findInteractingBlocks.cu
+2
-2
No files found.
platforms/cuda/src/CudaNonbondedUtilities.cpp
View file @
ebef35a4
...
@@ -369,7 +369,7 @@ double CudaNonbondedUtilities::getMaxCutoffDistance() {
...
@@ -369,7 +369,7 @@ double CudaNonbondedUtilities::getMaxCutoffDistance() {
}
}
double
CudaNonbondedUtilities
::
padCutoff
(
double
cutoff
)
{
double
CudaNonbondedUtilities
::
padCutoff
(
double
cutoff
)
{
double
padding
=
(
usePadding
?
0.
1
*
cutoff
:
0.0
);
double
padding
=
(
usePadding
?
0.
08
*
cutoff
:
0.0
);
return
cutoff
+
padding
;
return
cutoff
+
padding
;
}
}
...
...
platforms/cuda/src/kernels/findInteractingBlocks.cu
View file @
ebef35a4
...
@@ -304,10 +304,10 @@ extern "C" __global__ __launch_bounds__(GROUP_SIZE,3) void findBlocksWithInterac
...
@@ -304,10 +304,10 @@ extern "C" __global__ __launch_bounds__(GROUP_SIZE,3) void findBlocksWithInterac
int
atomFlags
=
BALLOT
(
forceInclude
||
atomDelta
.
x
*
atomDelta
.
x
+
atomDelta
.
y
*
atomDelta
.
y
+
atomDelta
.
z
*
atomDelta
.
z
<
(
PADDED_CUTOFF
+
blockCenterY
.
w
)
*
(
PADDED_CUTOFF
+
blockCenterY
.
w
));
int
atomFlags
=
BALLOT
(
forceInclude
||
atomDelta
.
x
*
atomDelta
.
x
+
atomDelta
.
y
*
atomDelta
.
y
+
atomDelta
.
z
*
atomDelta
.
z
<
(
PADDED_CUTOFF
+
blockCenterY
.
w
)
*
(
PADDED_CUTOFF
+
blockCenterY
.
w
));
int
interacts
=
0
;
int
interacts
=
0
;
if
(
atom2
<
NUM_ATOMS
&&
atomFlags
!=
0
)
{
if
(
atom2
<
NUM_ATOMS
&&
atomFlags
!=
0
)
{
int
first
=
__ffs
(
atomFlags
)
-
1
;
int
last
=
32
-
__clz
(
atomFlags
);
#ifdef USE_PERIODIC
#ifdef USE_PERIODIC
if
(
!
singlePeriodicCopy
)
{
if
(
!
singlePeriodicCopy
)
{
int
first
=
__ffs
(
atomFlags
)
-
1
;
int
last
=
32
-
__clz
(
atomFlags
);
for
(
int
j
=
first
;
j
<
last
;
j
++
)
{
for
(
int
j
=
first
;
j
<
last
;
j
++
)
{
real3
delta
=
trimTo3
(
pos2
)
-
trimTo3
(
posBuffer
[
warpStart
+
j
]);
real3
delta
=
trimTo3
(
pos2
)
-
trimTo3
(
posBuffer
[
warpStart
+
j
]);
APPLY_PERIODIC_TO_DELTA
(
delta
)
APPLY_PERIODIC_TO_DELTA
(
delta
)
...
...
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