|
Boost : |
Subject: Re: [boost] boost atomic question
From: Janek Kozicki (janek_listy_at_[hidden])
Date: 2010-04-30 12:26:28
Vicente Botet Escriba said: (by the date of Fri, 30 Apr 2010 08:33:04 -0700 (PDT))
> > What would it take to get this code to work?
> > std::vector<boost::atomic<Something> > v;
> > v.resize(100);
> Hi, just to understand better your concern.
>
> What kind of problems do you expect to have?
A dynamic simulation of thousands / millions of elements.
> have you already tried it?
It is already implemented, with OPEN MP and several global locks. We
have a speed-up of x5 times on 8 cores.
https://yade-dem.org/wiki/Screenshots_and_videos#Ball_Mill_-_125_000_spheres
> What do you expect from the atomic library?
I would like to simplify our current code, shorten it by replacing
mutexes with boost::atomic in places where I could do that. Mainly
I am hoping to remove global container locks.
The fact is that when calculating the dynamic equations for thousands
of elements, there is no conflict about the order in which they are
processed, it can be done simultaneously (so we divide whole
container into equal parts and process them in parallel). But also,
while being calculated the elements are drawn on a screen by separate
thread (a read-only). And also they can be accessed (read-write) from
python shell, in realtime, during the calculation.
An example of accessing the data in realtime, during calculation is
shown on this video:
http://geo.hmg.inpg.fr/~janek/yade-videos/buldozer.mpg
http://geo.hmg.inpg.fr/~janek/yade-videos/longer-yade-builtin-help.mpg
(there are other videos too in that directory).
You can read about our software here:
https://yade-dem.org/
https://www.yade-dem.org/sphinx/index.html
https://www.yade-dem.org/epydoc/
https://www.yade-dem.org/doxygen/
best regards
-- Janek Kozicki http://janek.kozicki.pl/ |
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk