Visible to Intel only — GUID: GUID-7814A4CE-5EA5-4087-A01E-C29C9C6DE8C7
Error Message: Bad Termination
Error Message: No such file or Directory
Error Message: Permission Denied
Error Message: Fatal Error
Error Message: Bad File Descriptor
Error Message: Too Many Open Files
Problem: High Memory Consumption Readings
Problem: MPI Application Hangs
Problem: Password Required
Problem: Cannot Execute Binary File
Problem: MPI limitation for Docker*
Visible to Intel only — GUID: GUID-7814A4CE-5EA5-4087-A01E-C29C9C6DE8C7
thread_split_omp_for.c
#include <mpi.h> #include <omp.h> #define n 2 MPI_Comm split_comm[n]; int main() { int i, provided; MPI_Init_thread(NULL, NULL, MPI_THREAD_MULTIPLE, &provided); for (i = 0; i < n; i++) MPI_Comm_dup(MPI_COMM_WORLD, &split_comm[i]); #pragma omp parallel for num_threads(n) for (i = 0; i < n; i++) { int j = i; MPI_Allreduce(MPI_IN_PLACE, &j, 1, MPI_INT, MPI_SUM, split_comm[i]); printf("Thread %d: allreduce returned %d\n", i, j); } MPI_Finalize(); }
Parent topic: Examples