Understand the main loop of message-passing-interface software

In video games, the main loop usually looks like this:


1
2
3
4
5
while(running){
    processInput();
    updateGameState();
    drawScreen();
}


(from higherorderfun.com)

Message-passing-interface (MPI) software can be designed in a similar fashion.

Each message-passing-interface rank of an MPI software has its own message inbox and its own message outbox.

Like for emails, received messages go in the inbox and sent messages go in the outbox.

The main loop of an MPI rank usually looks like this:

1
2
3
4
5
6
while(running){
    receiveMessages();
    processMessages();
    processData();
    sendMessages();
}

This general architecture is utilised in the Ray de novo genome assembler.

Read the code: github.com/sebhtml/ray

Comments

Popular posts from this blog

The Thorium actor engine is operational now, we can start to work on actor applications for metagenomics

Learning to solve the example 1 of puzzle 3aa6fb7a in the ARC prize

Adding ZVOL VIRTIO disks to a guest running on a host with the FreeBSD BHYVE hypervisor