Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
arbd
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tbgl
tools
arbd
Commits
faa3954e
Commit
faa3954e
authored
8 years ago
by
cmaffeo2
Browse files
Options
Downloads
Patches
Plain Diff
fixed bug in pairlist update
parent
6de38e02
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
ComputeForce.cu
+9
-0
9 additions, 0 deletions
ComputeForce.cu
with
9 additions
and
0 deletions
ComputeForce.cu
+
9
−
0
View file @
faa3954e
...
...
@@ -403,6 +403,14 @@ void ComputeForce::decompose(Vector3* pos, int type[]) {
/* sys_d, decomp_d, nCells, blocksPerCell, */
/* numPairs_d, pairListListI_d, pairListListJ_d); */
/* gpuErrchk(cudaDeviceSynchronize()); */
{
int
tmp
=
0
;
gpuErrchk
(
cudaMemcpyAsync
(
numPairs_d
,
&
tmp
,
sizeof
(
int
),
cudaMemcpyHostToDevice
));
gpuErrchk
(
cudaDeviceSynchronize
());
/* RBTOOD: maybe unnecessary */
}
createPairlists
<<<
nBlocks
,
NUMTHREADS
>>>
(
pos
,
num
,
numReplicas
,
sys_d
,
decomp_d
,
nCells
,
blocksPerCell
,
numPairs_d
,
pairListsI_d
,
pairListsJ_d
,
...
...
@@ -533,6 +541,7 @@ float ComputeForce::computeTabulated(Vector3* force, Vector3* pos, int* type,
// Call the kernel to calculate the forces
// int nb = (decomp.nCells.x * decomp.nCells.y * decomp.nCells.z);
int
nb
=
(
decomp
.
nCells
.
x
*
decomp
.
nCells
.
y
*
decomp
.
nCells
.
z
)
*
1000
;
/* RBTODO: number of pairLists */
printf
(
"ComputeTabulated
\n
"
);
computeTabulatedKernel
<<<
nb
,
numThreads
>>>
(
force
,
pos
,
type
,
tablePot_d
,
tableBond_d
,
num
,
numParts
,
sys_d
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment