| 594 | | success = MPI_Bcast( &buff[0], buff_size, MPI_UNSIGNED_CHAR, from_proc, procConfig.proc_comm() ); |
| 595 | | if (MPI_SUCCESS != success) { |
| 596 | | result = MB_FAILURE; |
| 597 | | RRA("MPI_Bcast of buffer failed."); |
| | 595 | size_t offset = 0; |
| | 596 | while (buff_size) { |
| | 597 | int size = std::min( buff_size, MAX_BCAST_SIZE ); |
| | 598 | success = MPI_Bcast( &buff[offset], size, MPI_UNSIGNED_CHAR, from_proc, procConfig.proc_comm() ); |
| | 599 | if (MPI_SUCCESS != success) { |
| | 600 | result = MB_FAILURE; |
| | 601 | RRA("MPI_Bcast of buffer failed."); |
| | 602 | } |
| | 603 | |
| | 604 | offset += size; |
| | 605 | buff_size -= size; |