Merge pull request #2983 from blattms/stdwell-comm-works-on-spe9-2

use random access to simplify code at second occasion
This commit is contained in:
Markus Blatt
2020-12-11 17:00:07 +01:00
committed by GitHub

View File

@@ -153,7 +153,7 @@ public:
{ return val1.first < val2; });
assert(global_pair != global_pairs.end());
assert(global_pair->first == pair.global());
*(begin + static_cast<const int&>(pair.local())) = sums[global_pair - global_pairs.begin()];
begin[pair.local()] = sums[global_pair - global_pairs.begin()];
}
#else
OPM_THROW(std::logic_error, "In a sequential run the size of the communicator should be 1!");