BF: Limit maximum RAM allocation size and change datatypes to avoid memory overflow

This change limits the maximum GPU RAM allocation size used by probtrackx2_gpu, and changes some datatypes to avoid overflows. The maximum memory used is clamped at 32GiB.

This fix was contributed by Chris Rorden

Merge request reports

Loading