#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <pvm3.h>
#include "main.h"
#include "error.h"
#include "assert.h"
#include "chromo.h"
#include "transfer.h"
Functions | |
int | file_recv (char *filename, int sender, int msgtag) |
Wait for file sent from sender. | |
int | file_mcast (char *filename, int *recipients, int num, int msgtag) |
Multicast file to all recipients. | |
int | file_send (char *filename, int recipient, int msgtag) |
Send file to one recipient. | |
int | table_recv (population *pop, int num, int sender, int msgtag) |
Wait for timetables from sender. | |
int | table_send (population *pop, int num, int recipient, int msgtag) |
Send timetables to a recipient. | |
population * | population_recv (int sender, int msgtag) |
Receive the entire population. | |
int | population_send (population *pop, int recipient, int msgtag) |
Send the entire population. |
int file_mcast | ( | char * | filename, | |
int * | recipients, | |||
int | num, | |||
int | msgtag | |||
) |
Multicast file to all recipients.
filename | File to multicast. | |
recipients | Array of num task IDs. | |
num | Number of recipients. | |
msgtag | Message tag. |
int file_recv | ( | char * | filename, | |
int | sender, | |||
int | msgtag | |||
) |
Wait for file sent from sender.
filename | File will be saved under this name. | |
sender | Task ID of the sender task. | |
msgtag | Message tag. |
int file_send | ( | char * | filename, | |
int | recipient, | |||
int | msgtag | |||
) |
Send file to one recipient.
filename | File to multicast. | |
recipient | Task ID of the recipient task. | |
msgtag | Message tag. |
population* population_recv | ( | int | sender, | |
int | msgtag | |||
) |
Receive the entire population.
sender | Task ID of the sender task. | |
msgtag | Message tag. |
int population_send | ( | population * | pop, | |
int | recipient, | |||
int | msgtag | |||
) |
Send the entire population.
pop | Pointer to the population struct. | |
recipient | Task ID of the recipient task. | |
msgtag | Message tag. |
int table_recv | ( | population * | pop, | |
int | num, | |||
int | sender, | |||
int | msgtag | |||
) |
Wait for timetables from sender.
Received timetables are stored at the end of the population.
pop | Pointer to the population struct. | |
num | Number of chromosomes to receive. | |
sender | Task ID of the sender task. | |
msgtag | Message tag. |
int table_send | ( | population * | pop, | |
int | num, | |||
int | recipient, | |||
int | msgtag | |||
) |
Send timetables to a recipient.
Timetables are read from the start of the population.
pop | Pointer to the population struct. | |
num | Number of chromosomes to send. | |
recipient | Task ID of the recipient task. | |
msgtag | Message tag. |