File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
src/TiledArray/expressions Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -518,9 +518,10 @@ class Expr {
518518 // Move the data from dist_eval into the sub-block of result array.
519519 // This step may involve communication when the tiles are moved from the
520520 // sub-block distribution to the array distribution.
521- // N.B. handle the corner case of zero-volume host array, then no data needs
522- // to be moved
523- if (tsr.array ().trange ().tiles_range ().volume () != 0 ) {
521+ // N.B. handle the corner cases of zero-volume host array and zero-volume
522+ // block, then no data needs to be moved
523+ if (tsr.array ().trange ().tiles_range ().volume () != 0 &&
524+ blk_range.volume () != 0 ) {
524525 // N.B. must deep copy
525526 TA_ASSERT (tsr.array ().trange ().tiles_range ().includes (tsr.lower_bound ()));
526527 // N.B. this expression's range,
You can’t perform that action at this time.
0 commit comments