• 2019 Update 7
  • 03/31/2020
Contents

async_progress_sample.c

Intel® MPI Library Developer Guide for Linux* OS
#define PROGRESS_THREAD_COUNT 4 MPI_Comm comms[PROGRESS_THREAD_COUNT]; MPI_Request requests[PROGRESS_THREAD_COUNT]; MPI_Info info; int idx; /* create “per-thread” communicators and assign thread id for each communicator */ for (idx = 0; idx < PROGRESS_THREAD_COUNT; idx++) { MPI_Comm_dup(MPI_COMM_WORLD, &comms[idx]); char thread_id_str[256] = { 0 }; sprintf(thread_id_str, "%d", idx); MPI_Info_create(&info); MPI_Info_set(info, "thread_id", thread_id_str); MPI_Comm_set_info(comms[idx], info); MPI_Info_free(&info); } /* distribute MPI operations between communicators – i.e. between progress threads */ for (idx = 0; idx < PROGRESS_THREAD_COUNT; idx++) { MPI_Iallreduce(…, comms[idx], &requests[idx]); } MPI_Waitall(PROGRESS_THREAD_COUNT, requests, …)

Product and Performance Information

1

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804