message passing interface a brief introduction

Post on 16-Mar-2022

2 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Experts in numerical software andHigh Performance Computing

Message Passing Interfacea brief introduction

University of Birmingham

30th January 2017

Ning Li - Senior Technical Consultant

Sally Bridgwater – HPC Application Analyst

2High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

3High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

4High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

5High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

6High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

7High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

8High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

9High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

10High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

11High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

12High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

13High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

14High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

15High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

16High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

17High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

18High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

Best domain decomposition is dependent on algorithm.

19High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

3rd party partitioning software often required

20High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

A subset of processes responsible for each model

Atmospheric Model

Hydrology

Model

Ocean

Model

Land Surface Model

21High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

From: source rankLetter # 1234 (tag)

To: destination rank

The message has:

A type - integer, real, etc.

A count

A location – memory address

Both source and destination

ranks need to provide these

Please send count number data of this type, located at memory address a on the source rank, to the destination rank and write to memory address b there.

22High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

23High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

24High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

25High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

26High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

27High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

MPI_Recv()

MPI_Send()

Process 0

MPI_Recv()

MPI_Send()

Process 1

Tim

e

28High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

29High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

30High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

MPI_Barrier

Tim

eT

31High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

Root

10010110

0

10010110

2

10010110

1

10010110

Size-1

10010110

32High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

Proc 0

01101

Proc 1

10101

Proc 2

11001

Proc 3

01011

Proc 4

11101

01101 10101 11001 01011 11101

33High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

34High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

35High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

36High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

37High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

38High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

Basic datatype

col_type: a derived datatype that is strided

row_type: a derived datatype that is contiguous

39High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

40High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

41High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

Rank=0

Coord=(0,0)

Rank=1

Coord=(0,1)

Rank=2

Coord=(0,2)

Rank=3

Coord=(1,0)

Rank=4

Coord=(1,1)

Rank=5

Coord=(1,2)

42High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

43High Performance Computing Consulting | Numerical Algorithms | Software Engineering Services | www.nag.com

Experts in High Performance Computing, Algorithms and Numerical Software Engineering

www.nag.com | blog.nag.com | @NAGtalk

top related