|
PULSAR
2.0.0
Parallel Ultra-Light Systolic Array Runtime
|
PRT data packet. More...
#include "prt_packet.h"Go to the source code of this file.
Functions | |
| prt_packet_t * | prt_packet_new_host (size_t size, void *data) |
| Creates a new packet in host memory. Allocates the size amount of data if a NULL pointer is passed. More... | |
| prt_packet_t * | prt_packet_new_device (size_t size, void *data, prt_vdp_t *vdp) |
| Creates a new packet in device memory. Allocates the size amount of data if a NULL pointer is passed. More... | |
| void | prt_packet_resize_host (prt_packet_t *packet, size_t size) |
| Resizes a packet in host memory. Used to resize placeholder packets for incoming MPI messages, wich initially are allocated with the maximum packet size. More... | |
| void | prt_packet_release_host (prt_packet_t *packet) |
| Releases a packet located in host memory. Decrements the number of active references. Destroys the packet when the last reference is removed. More... | |
| void | prt_packet_release_device (prt_packet_t *packet) |
| Releases a packet located in device memory. Decrements the number of active references. Destroys the packet when the last reference is removed. More... | |
| void | prt_packet_host_to_device (prt_packet_t *src_packet, prt_channel_t *channel) |
| Transfers a packet from the host to a device. More... | |
| void | prt_packet_device_to_host (prt_packet_t *src_packet, prt_channel_t *channel) |
| Transfers a packet from the host to a device. More... | |
| void | prt_packet_device_to_device (prt_packet_t *src_packet, prt_channel_t *channel) |
| Transfers a packet from a device to another device. More... | |
| void | prt_packet_device_to_device_direct (prt_packet_t *src_packet, prt_channel_t *channel) |
| Transfers a packet from a device to another device. Uses a direct copy, without involving the host. More... | |
| void | prt_packet_device_mpi_to_host (prt_packet_t *src_packet, prt_channel_t *channel, int agent) |
| Initiates an MPI transfer from a device. Sends a packet from a device to the host. Then requests an MPI transfer from the host. More... | |
PRT data packet.
PULSAR Runtime http://icl.utk.edu/pulsar/ Copyright (C) 2012-2015 University of Tennessee.
Definition in file prt_packet.c.
| void prt_packet_device_mpi_to_host | ( | prt_packet_t * | src_packet, |
| prt_channel_t * | channel, | ||
| int | agent | ||
| ) |
Initiates an MPI transfer from a device. Sends a packet from a device to the host. Then requests an MPI transfer from the host.
| src_packet | – The packet to transfer. |
| channel | – The destination channel. |
Definition at line 306 of file prt_packet.c.
| void prt_packet_device_to_device | ( | prt_packet_t * | src_packet, |
| prt_channel_t * | channel | ||
| ) |
Transfers a packet from a device to another device.
| src_packet | – The packet to transfer. |
| channel | – The destination channel. |
Definition at line 238 of file prt_packet.c.
| void prt_packet_device_to_device_direct | ( | prt_packet_t * | src_packet, |
| prt_channel_t * | channel | ||
| ) |
Transfers a packet from a device to another device. Uses a direct copy, without involving the host.
| src_packet | – The packet to transfer. |
| channel | – The destination channel. |
Definition at line 270 of file prt_packet.c.
| void prt_packet_device_to_host | ( | prt_packet_t * | src_packet, |
| prt_channel_t * | channel | ||
| ) |
Transfers a packet from the host to a device.
| packet | – The packet to transfer. |
| channel | – The destination channel. |
| kind | – The direction of the transfer. |
Definition at line 207 of file prt_packet.c.
| void prt_packet_host_to_device | ( | prt_packet_t * | src_packet, |
| prt_channel_t * | channel | ||
| ) |
Transfers a packet from the host to a device.
| packet | – The packet to transfer. |
| channel | – The destination channel. |
| kind | – The direction of the transfer. |
Definition at line 174 of file prt_packet.c.
| prt_packet_t* prt_packet_new_device | ( | size_t | size, |
| void * | data, | ||
| prt_vdp_t * | vdp | ||
| ) |
Creates a new packet in device memory. Allocates the size amount of data if a NULL pointer is passed.
Registers increased memory usage in both cases. This way the ending balance is expected to be zero. Packet release does not care (know) how the data was allocated.
| size | – The size of the packet's data. |
| data | – The pointer to the packet's data. |
| vdp | – The VDP creating the packet. |
Definition at line 68 of file prt_packet.c.
| prt_packet_t* prt_packet_new_host | ( | size_t | size, |
| void * | data | ||
| ) |
Creates a new packet in host memory. Allocates the size amount of data if a NULL pointer is passed.
Registers increased memory usage in both cases. This way the ending balance is expected to be zero. Packet release does not care (know) how the data was allocated.
| size | – The size of packet's data. |
| data | – The pointer to the packet's data. |
Definition at line 27 of file prt_packet.c.
| void prt_packet_release_device | ( | prt_packet_t * | packet) |
Releases a packet located in device memory. Decrements the number of active references. Destroys the packet when the last reference is removed.
| packet | – The device packet to release. |
Definition at line 148 of file prt_packet.c.
| void prt_packet_release_host | ( | prt_packet_t * | packet) |
Releases a packet located in host memory. Decrements the number of active references. Destroys the packet when the last reference is removed.
| packet | – The host packet to release. |
Definition at line 127 of file prt_packet.c.
| void prt_packet_resize_host | ( | prt_packet_t * | packet, |
| size_t | size | ||
| ) |
Resizes a packet in host memory. Used to resize placeholder packets for incoming MPI messages, wich initially are allocated with the maximum packet size.
| packet | – The packet to resize. |
| size | – The new size in bytes. |
Definition at line 105 of file prt_packet.c.