PadicoTM

Documentation

« back to PM2 home.

Internal structures definition for the VLink/Packet component – This is not a public API. More...

#include <Padico/Puk.h>
#include <Padico/PadicoTM.h>
#include <Padico/PM2.h>
#include <Padico/Topology.h>
#include <Padico/PSP.h>
#include <Padico/VLink-internals.h>
Include dependency graph for VLink-Packet.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  vopw_address_s
 Address for a VLink_Packet endpoint. More...
 
struct  sockaddr_padico_vopw
 Serialized form of a vopw_address_s (in network byte order) More...
 
struct  vopw_buffer_s
 automatic buffers with sliding pointers More...
 
struct  vopw_dynres_entry_s
 
struct  vopw_dynres_s
 Dynamic address resolution manager. More...
 
struct  vopw_hdr_info_connect_s
 
struct  vopw_hdr_info_accepted_s
 
struct  vopw_hdr_info_gettag_s
 
struct  vopw_hdr_info_givetag_s
 
struct  vopw_hdr_info_data_s
 
struct  vopw_hdr_info_rendezvous_s
 
struct  vopw_hdr_info_oktosend_s
 
struct  vopw_hdr_info_packet_s
 
struct  vopw_hdr_s
 Header for all outgoing messages through VSock/Madeleine wrapper. More...
 
union  vopw_hdr_s::vopw_hdr_info_u
 
union  vopw_hdr_info_u
 
struct  vopw_deferred_req_s
 Structure to describe deferred operations to be executed in a different thread than the receiving one. More...
 

Macros

#define AF_PADICO_VOPW   AF_PADICO_MAGIC('V', 'O', 'P', 'W')
 the AF_PADICO_VOPW magic number as an uint32_t
 
#define VOPW_IBOX_DATA   0x01
 
#define VOPW_IBOX_RENDEZVOUS   0x02
 
#define VOPW_IBOX_OKTOSEND   0x04
 
#define VOPW_IBOX_PACKET   0x08
 
#define VOPW_IBOX_EOS   0x10
 
#define VOPW_BUF_MEMTOBUFFER(BUF, MEM, SIZ)
 
#define VOPW_BUF_PUMPTOBUFFER(BUF, SIZ, TOKEN, PUMP)
 
#define VOPW_BUF_BUFFERTOMEM(MEM, BUF, SIZ)
 
#define VOPW_BUF_ALLOC(BUF, SIZ)
 
#define VOPW_BUF_CURRENTSIZE(BUF)    ((BUF).size-(BUF).offset)
 
#define VOPW_BUF_FREE(BUF)    padico_free((BUF).data)
 
#define VOPW_VNODES_MAX   256
 
#define VOPW_TAG_NOTAG   -1
 
#define VOPW_TAG_ANY   0
 
#define VOPW_TAG_FIRST   1
 
#define VOPW_TAG_LAST   (VOPW_VNODES_MAX-1)
 
#define VOPW_TAG_NEXT(T)   (((T)==VOPW_TAG_LAST)?(VOPW_TAG_FIRST):((T)+1))
 
#define VOPW_OP_NONE   0x00
 
#define VOPW_OP_CONNECT   0x01
 
#define VOPW_OP_CONNREFUSED   0x02
 
#define VOPW_OP_ACCEPTED   0x03
 
#define VOPW_OP_CLOSE   0x04 /* the sender will not receive anymore */
 
#define VOPW_OP_EOS   0x05 /* end-of-stream: the sender will not send anymore */
 
#define VOPW_OP_GET_TAG   0x06 /* Port-to-tag resolution request */
 
#define VOPW_OP_GIVE_TAG   0x07 /* Port-to-tag resolution reply */
 
#define VOPW_OP_DATA   0x11 /* streamed data */
 
#define VOPW_OP_RENDEZVOUS   0x12
 
#define VOPW_OP_OKTOSEND   0x14
 
#define VOPW_OP_PACKET   0x15 /* packet-based data */
 

Functions

struct vopw_hdr_info_connect_s __attribute__ ((packed))
 

Variables

 vopw_ibox
 incoming buffering box for Madeleine wrapper
 
int what
 rendezvous or buffer (VOPW_IBOX_* defines)
 
padico_topo_node_t node_from
 
uint16_t port
 originating port number ('host' byte order)
 
size_t rendezvous_size
 size of the rendez-vous, if present
 
struct vopw_buffer_s buffer
 raw data received by copy
 
typdef struct vopw_dynres_vect_s * vopw_dynres_vect_t
 
uint32_t my_addr
 IP address of the client side.
 
uint16_t my_tag
 tag of the client side
 
uint16_t your_tag
 tag of the server socket
 
uint16_t domain
 domain of the virtual socket.
 
uint16_t type
 SOCK_STREAM, SOCK_DGRAM.
 
uint16_t your_port
 port number requested
 
uint32_t my_rank
 
uint16_t my_port
 
uint32_t len
 length of data (including data in header)
 
uint32_t tlen
 length of data in message body
 
char data [4]
 place holder for a pointer- actually, more space is used
 
uint32_t proposed_len
 length of the data ready to be sent
 
uint32_t accepted_len
 accepted_len <= proposed_len - DATA_IN_HEADER
 
uint16_t op
 operator code
 
uint16_t tag
 destination MAD tag
 
union vopw_hdr_info_u info
 variable part of the header
 
struct vopw_deferred_req_s __attribute__
 

Detailed Description

Internal structures definition for the VLink/Packet component – This is not a public API.

Definition in file VLink-Packet.h.

Macro Definition Documentation

◆ AF_PADICO_VOPW

#define AF_PADICO_VOPW   AF_PADICO_MAGIC('V', 'O', 'P', 'W')

the AF_PADICO_VOPW magic number as an uint32_t

Definition at line 56 of file VLink-Packet.h.

◆ VOPW_BUF_ALLOC

#define VOPW_BUF_ALLOC (   BUF,
  SIZ 
)
Value:
(BUF).offset=0; \
(BUF).size=0; \
(BUF).total_size=(SIZ); }
static int done
Definition console-mod.c:49
static int size
Definition datacheck.c:34

Definition at line 103 of file VLink-Packet.h.

◆ VOPW_BUF_BUFFERTOMEM

#define VOPW_BUF_BUFFERTOMEM (   MEM,
  BUF,
  SIZ 
)
Value:
{ memcpy(MEM, (BUF).data+(BUF).offset, SIZ); \
(BUF).offset += SIZ; }

Definition at line 99 of file VLink-Packet.h.

◆ VOPW_BUF_CURRENTSIZE

#define VOPW_BUF_CURRENTSIZE (   BUF)     ((BUF).size-(BUF).offset)

Definition at line 109 of file VLink-Packet.h.

◆ VOPW_BUF_FREE

#define VOPW_BUF_FREE (   BUF)     padico_free((BUF).data)

Definition at line 112 of file VLink-Packet.h.

◆ VOPW_BUF_MEMTOBUFFER

#define VOPW_BUF_MEMTOBUFFER (   BUF,
  MEM,
  SIZ 
)
Value:
{ memcpy((BUF).data+(BUF).size, (MEM), (SIZ)); \
(BUF).size += (SIZ); }

Definition at line 91 of file VLink-Packet.h.

◆ VOPW_BUF_PUMPTOBUFFER

#define VOPW_BUF_PUMPTOBUFFER (   BUF,
  SIZ,
  TOKEN,
  PUMP 
)
Value:
{ (*(PUMP))((TOKEN), ((BUF).data +(BUF).size), (SIZ)); \
(BUF).size += (SIZ); }

Definition at line 95 of file VLink-Packet.h.

◆ VOPW_IBOX_DATA

#define VOPW_IBOX_DATA   0x01

Definition at line 82 of file VLink-Packet.h.

◆ VOPW_IBOX_EOS

#define VOPW_IBOX_EOS   0x10

Definition at line 86 of file VLink-Packet.h.

◆ VOPW_IBOX_OKTOSEND

#define VOPW_IBOX_OKTOSEND   0x04

Definition at line 84 of file VLink-Packet.h.

◆ VOPW_IBOX_PACKET

#define VOPW_IBOX_PACKET   0x08

Definition at line 85 of file VLink-Packet.h.

◆ VOPW_IBOX_RENDEZVOUS

#define VOPW_IBOX_RENDEZVOUS   0x02

Definition at line 83 of file VLink-Packet.h.

◆ VOPW_OP_ACCEPTED

#define VOPW_OP_ACCEPTED   0x03

Definition at line 168 of file VLink-Packet.h.

◆ VOPW_OP_CLOSE

#define VOPW_OP_CLOSE   0x04 /* the sender will not receive anymore */

Definition at line 175 of file VLink-Packet.h.

◆ VOPW_OP_CONNECT

#define VOPW_OP_CONNECT   0x01

Definition at line 155 of file VLink-Packet.h.

◆ VOPW_OP_CONNREFUSED

#define VOPW_OP_CONNREFUSED   0x02

Definition at line 166 of file VLink-Packet.h.

◆ VOPW_OP_DATA

#define VOPW_OP_DATA   0x11 /* streamed data */

Definition at line 196 of file VLink-Packet.h.

◆ VOPW_OP_EOS

#define VOPW_OP_EOS   0x05 /* end-of-stream: the sender will not send anymore */

Definition at line 177 of file VLink-Packet.h.

◆ VOPW_OP_GET_TAG

#define VOPW_OP_GET_TAG   0x06 /* Port-to-tag resolution request */

Definition at line 179 of file VLink-Packet.h.

◆ VOPW_OP_GIVE_TAG

#define VOPW_OP_GIVE_TAG   0x07 /* Port-to-tag resolution reply */

Definition at line 187 of file VLink-Packet.h.

◆ VOPW_OP_NONE

#define VOPW_OP_NONE   0x00

Definition at line 153 of file VLink-Packet.h.

◆ VOPW_OP_OKTOSEND

#define VOPW_OP_OKTOSEND   0x14

Definition at line 211 of file VLink-Packet.h.

◆ VOPW_OP_PACKET

#define VOPW_OP_PACKET   0x15 /* packet-based data */

Definition at line 217 of file VLink-Packet.h.

◆ VOPW_OP_RENDEZVOUS

#define VOPW_OP_RENDEZVOUS   0x12

Definition at line 204 of file VLink-Packet.h.

◆ VOPW_TAG_ANY

#define VOPW_TAG_ANY   0

Definition at line 125 of file VLink-Packet.h.

◆ VOPW_TAG_FIRST

#define VOPW_TAG_FIRST   1

Definition at line 126 of file VLink-Packet.h.

◆ VOPW_TAG_LAST

#define VOPW_TAG_LAST   (VOPW_VNODES_MAX-1)

Definition at line 127 of file VLink-Packet.h.

◆ VOPW_TAG_NEXT

#define VOPW_TAG_NEXT (   T)    (((T)==VOPW_TAG_LAST)?(VOPW_TAG_FIRST):((T)+1))

Definition at line 128 of file VLink-Packet.h.

◆ VOPW_TAG_NOTAG

#define VOPW_TAG_NOTAG   -1

Definition at line 124 of file VLink-Packet.h.

◆ VOPW_VNODES_MAX

#define VOPW_VNODES_MAX   256

Definition at line 122 of file VLink-Packet.h.

Function Documentation

◆ __attribute__()

struct vopw_hdr_info_connect_s __attribute__ ( (packed)  )

Variable Documentation

◆ __attribute__

struct vopw_deferred_req_s __attribute__

◆ accepted_len

uint32_t accepted_len

accepted_len <= proposed_len - DATA_IN_HEADER

Definition at line 0 of file VLink-Packet.h.

Referenced by vopw_oktosend_send(), and vopw_psp_callback_OKTOSEND().

◆ buffer

raw data received by copy

Definition at line 77 of file VLink-Packet.h.

◆ data

char data[4]

place holder for a pointer- actually, more space is used

place-holder for actual data

Definition at line 2 of file VLink-Packet.h.

◆ domain

uint16_t domain

domain of the virtual socket.

Note
only AF_INET is actually supported
only AF_INET supported

Definition at line 3 of file VLink-Packet.h.

Referenced by padico_sysio_socket(), padico_vio_socket(), padico_vsock_create(), and padico_vsock_init().

◆ info

variable part of the header

Referenced by padico_pmix_barrier(), padico_pmix_kvs_fence(), and padico_pmix_kvs_lookup().

◆ len

◆ my_addr

uint32_t my_addr

IP address of the client side.

IP address of the server.

Definition at line 0 of file VLink-Packet.h.

◆ my_port

uint16_t my_port

Definition at line 2 of file VLink-Packet.h.

◆ my_rank

uint32_t my_rank

Definition at line 1 of file VLink-Packet.h.

◆ my_tag

uint16_t my_tag

tag of the client side

tag for the newly created socket

Definition at line 1 of file VLink-Packet.h.

◆ node_from

◆ op

◆ port

uint16_t port

originating port number ('host' byte order)

port from where the packet is sent

Definition at line 75 of file VLink-Packet.h.

◆ proposed_len

uint32_t proposed_len

length of the data ready to be sent

Definition at line 0 of file VLink-Packet.h.

◆ rendezvous_size

size_t rendezvous_size

size of the rendez-vous, if present

Definition at line 76 of file VLink-Packet.h.

Referenced by vopw_oktosend_send(), and vopw_psp_callback_RENDEZVOUS().

◆ tag

uint16_t tag

destination MAD tag

Definition at line 1 of file VLink-Packet.h.

◆ tlen

uint32_t tlen

length of data in message body

Definition at line 1 of file VLink-Packet.h.

Referenced by vopw_data_process(), vopw_data_send(), and vopw_psp_callback_DATA().

◆ type

◆ vopw_dynres_vect_t

typdef struct vopw_dynres_vect_s* vopw_dynres_vect_t

Definition at line 139 of file VLink-Packet.h.

◆ vopw_ibox

vopw_ibox

incoming buffering box for Madeleine wrapper

Definition at line 72 of file VLink-Packet.h.

◆ what

int what

rendezvous or buffer (VOPW_IBOX_* defines)

Definition at line 73 of file VLink-Packet.h.

Referenced by padico_io_register().

◆ your_port

uint16_t your_port

port number requested

Definition at line 2 of file VLink-Packet.h.

◆ your_tag

uint16_t your_tag

tag of the server socket

Definition at line 2 of file VLink-Packet.h.