Skip to content
Snippets Groups Projects
Commit cfcbfed4 authored by Mactavish Zhan's avatar Mactavish Zhan
Browse files

update slides

parent b7d49064
No related branches found
No related tags found
No related merge requests found
......@@ -13,7 +13,7 @@ Any questions about:
<br/>
### Materials
### References
- [The difference between modes of MPI send](https://iamsorush.com/posts/mpi-send-types/)
- [Message Passing with MPI - PPCES 2017](https://blog.rwth-aachen.de/itc-events/en/event/ppces-2017/)
......
......@@ -58,3 +58,66 @@ Single Program Multiple Data:
- Abstractions make programming and understanding easier
- Multiple instruction flows (instances) from a Single Program working on Multiple (different parts of) Data
- Instances could be threads (OpenMP) and/or processes (MPI)
---
title: MPI I
---
## MPI
A language-agnostic specification of a set of communication and I/O operations.
Standard bindings for C and Fortran. Non-standard bindings for other languages: C++, Java, Python etc.
<v-click>
### Differences between MPI and OpenMP
Unlike OpenMP, MPI does not extend the base language, but provides a set of library functions and a specialised runtime. It also makes use of existing compilers.
</v-click>
<v-click>
### Documentation
- [The MPI Forum document archive (the standards)](https://www.mpi-forum.org/docs/)
- [OpenMPI documentation](https://www.open-mpi.org/doc/)
- [MPICH documentation](https://www.mpich.org/documentation/guides/)
</v-click>
---
title: MPI II
---
## General Structure of an MPI Program
Start-up, initialisation, finalisation, and shutdown in C:
```c
#include <mpi.h>
int main(int argc, char **argv) {
// some code
// initialization of the MPI runtime environment
MPI_Init(&argc, &argv);
// code that handles computation & communication
// finalization of the MPI runtime enviroment, internal buffers are flushed etc.
MPI_Finalize();
// wrap-up code
return 0;
}
```
---
title: MPI III
---
## MPI Example: Hello World
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment