-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathmpihelper.cpp
More file actions
31 lines (24 loc) · 730 Bytes
/
Copy pathmpihelper.cpp
File metadata and controls
31 lines (24 loc) · 730 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#include "libhipeless.h"
#include <mpi.h>
int main(int argc, char* argv[]) {
unsigned int flags = USE_MPI | MPI_SPAWN;
int function;
MPI_Init(&argc, &argv);
MPI_Comm parent;
MPI_Comm_get_parent(&parent);
MPI_Bcast(&function, 1, MPI_INTEGER, 0, parent);
if(function == SGEMM) {
blas_sgemm('0', '0', 0, 0, 0, 0, NULL, 0, NULL, 0, 0, NULL, 0, flags);
}
else if (function == DGEMM) {
blas_dgemm('0', '0', 0, 0, 0, 0, NULL, 0, NULL, 0, 0, NULL, 0, flags);
}
else if(function == STRMM) {
blas_strmm('0', '0', '0', '0', 0, 0, 0, NULL, 0, NULL, 0, flags);
}
else if(function == DTRMM) {
blas_dtrmm('0', '0', '0', '0', 0, 0, 0, NULL, 0, NULL, 0, flags);
}
MPI_Finalize();
return 0;
}