yade-dev team mailing list archive
-
yade-dev team
-
Mailing list archive
-
Message #00490
run faster by +16% (and enlarge your p*n*s size ; -) ) with r1402
I just commited ParallelEngine class that uses openmp to run engines in
parallel. I have 16% speedup on simple-scene.py vs.
simple-scene-parallel.py (dual-core machine, but the second core is 100%
used). I think the impact will be bigger on larger simulations. If you
get mysterious crashes while useing ParallelEngine, run with
OMP_NUM_THREADS=1 to make sure. Do not use it unless you are sure the
engines you run in parallel do not touch the same data.
I will soon start to parallelize inner loops of engines where it makes
sense - like gravity engine, InteractingGeometryMetaEngine,
InteractionPhysicsMetaEngine. None of the changes will be intrusive,
though, and compiling without openmp enabled (or /setting
OMP_NUM_THREADS=1 in the shell) /will keep the old behavior.
For engines that loop over physical actions, that will be more
complicated, since openmp needs const-time random access to
integer-indexed elements; we will see.
Please let me know if you get some speedups. Ah, not to forget: use
gcc>=4.2 to compile.
Vaclav
_______________________________________________
yade-dev mailing list
yade-dev@xxxxxxxxxxxxxxxx
https://lists.berlios.de/mailman/listinfo/yade-dev
Follow ups