Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- cliff@ubuntu:~/Documents$ cat test.c
- #include <mpi.h>
- #include <stdio.h>
- #include <unistd.h>
- int main (int argc, char * argv[0]) {
- alarm(3);
- char message [16] = "Hello World !!";
- MPI_Init (&argc, &argv);
- printf ("%s\n", message);
- MPI_Finalize();
- pause();
- return (0); }
- cliff@ubuntu:~/Documents$
- ----------------------------------------------------------------
- cliff@ubuntu:~/Documents$ ls
- erg2 erg3.exe erg4.c MPI_NOTES.pdf
- erg3.c erg3.o mpi-1.1-report-marked.ps test.c
- cliff@ubuntu:~/Documents$ mpicc -c test.c
- cliff@ubuntu:~/Documents$ mpicc -o test.exe test.o
- cliff@ubuntu:~/Documents$ mpirun -np 5 test.exe
- Alarm clock
- cliff@ubuntu:~/Documents$
- cliff@ubuntu:~/Documents$ file test.exe
- test.exe: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.15, not stripped
- cliff@ubuntu:~/Documents$
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement