During some convergence/performance studies with the example DamBreak3D on a single GPU, I reduced the interparticle distance dp until the compilation of the attending executable has been stopped because of the following condition:
FATAL: thread 0 needs 120671192 (and up to 120671192) particles, but we can only store 39130316 in 14.87 GiB available of 15.9 GiB total with 508.71 MiB safety margin
Estimated memory consumption: 408B/particle
NOTE: device 0 can allocate 39130316 particles, while the whole simulation might require 120671192
The message is clear and acceptable. It does invite some questions:
- what is the rationale of maintaining a safety margin for memory consumption?
- would this safety margin be a benefit to running multi-GPU simulations?
- is there a possibility to customize the margin size and, as a special case, bring it down to 0 units or 0%?
I have had a glance at the options to make executables and to steer them, and I cannot seem to find any serving this end. Perhaps there is some keyword in the source file of the example or, most probably, deeper in the code. Directions and corrections appreciated.