yade-dev team mailing list archive
-
yade-dev team
-
Mailing list archive
-
Message #07002
[Branch ~yade-dev/yade/trunk] Rev 2716: 1. An attempt to fix OpenMPArrayAccumulator initialization (not tested)
------------------------------------------------------------
revno: 2716
committer: Václav Šmilauer <eu@xxxxxxxx>
branch nick: yade
timestamp: Tue 2011-02-08 16:29:38 +0100
message:
1. An attempt to fix OpenMPArrayAccumulator initialization (not tested)
modified:
lib/base/openmp-accu.hpp
--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk
Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription
=== modified file 'lib/base/openmp-accu.hpp'
--- lib/base/openmp-accu.hpp 2011-01-19 10:21:31 +0000
+++ lib/base/openmp-accu.hpp 2011-02-08 15:29:38 +0000
@@ -50,7 +50,7 @@
// if nCL_new<nCL, do not deallocate memory
// if nCL_new==nCL, only update sz
// reset items that were added
- for(size_t s=sz; s>n; s++){ for(size_t th=0; th<nThreads; th++) chunks[th][s]=0; }
+ for(size_t s=sz; s>n; s++){ for(size_t th=0; th<nThreads; th++) chunks[th][s]=ZeroInitializer<T>(); }
sz=n;
}
// clear (does not deallocate storage, anyway)