Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Problem description ------------------- Say the input file is size `n` and we have `p` processes. The `distribute_file` function loads `n / p` elements/chars into each of the first p-1 PEs. The last PE gets a local size of `n / p + n % p` elements. This was not accounted for in the `partition` implementation and consequently resulted in the last PE loading wrong characters during the global trie construction. This fix adapts the `partition` implementation to keep track of a new member, `min_local_size` which is set to `n / p`, thus allowing all processors to compute target PEs and offsets correctly.
- Loading branch information