RRMap broken for >1D chare arrays
The built-in RRMap CkArrayMap only does a true round-robin mapping for 1D arrays. For >1D arrays it hashes the indices of each element modulo a big prime number and the number of PEs. This leads to unbalanced mappings of chares to PEs (some PEs might not get any chares in some cases or some PEs will have more than others), and the behavior is not true to the API.
This is seemingly because the map interface does not know the extent of the array dimensions, only the indices of each chare array element.
#3 Updated by Sam White over 2 years ago
- Assignee deleted (
Abandoned patch for this: https://charm.cs.illinois.edu/gerrit/#/c/1053/
BlockLB similarly does not take into account the dimensionality of a chare array.
CkArrayOptions already provides an interface (opts.setBounds()) to let users gives us the number of chares per dimension of their array, but this information is not passed through the location manager to the ArrayMap and LB objects.
A further cleanup for this issue is that section 13.2.1 of the manual should be rewritten to encourage users to use setBounds and the other things that CkArrayOptions exposes.
#6 Updated by Sam White over 2 years ago
- Assignee changed from Eric Mikida to Dong Hun Lee
The real work here is in passing the bounds from CkArrayOptions through to CkArrayMap, so that RRMap can linearize the index space of multidimensional arrays for a true round-robin mapping.
The case of BlockLB is basically the same, BlockLB needs to know the bounds but currently doesn't.