I'm preparing a college exam in parallel computing. The main purpose is to speedup as much as possible a Montecarlo simulation about electron drift in earth magnetic field. I've already developed something with two layers of parallelization:
- MPI used to make te code run on several machines
- OpenMP to run parallel simulation inside the single computer
Now comes the question: I would like to keep on-demand the task execution. The fastest computer must be able to execute more work the the slower ones. The problem partition is done via master-worker cycle, so there is no actual struggle about achieving this result.
Since the number of tasks (a block of n electrons to simulate) executed by a worker is not prior defined I have two roads to follow:
every thread in every worker has is own RNG initialized with random generated seed (different generation method). The unbalancing of the cluster will change results, but in this approach the result is as casual as possible.
every electron has his own seed, granting reproducibility of the simulation despite of which worker runs the single task. Must have a better RNG.
Lets's poll about this. What's your suggestion?
Have fun
gf