File: vprotocol_pessimist_request.h

package info (click to toggle)
openmpi 5.0.7-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 202,312 kB
  • sloc: ansic: 612,441; makefile: 42,495; sh: 11,230; javascript: 9,244; f90: 7,052; java: 6,404; perl: 5,154; python: 1,856; lex: 740; fortran: 61; cpp: 20; tcl: 12
file content (53 lines) | stat: -rw-r--r-- 1,758 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
/*
 * Copyright (c) 2004-2007 The Trustees of the University of Tennessee.
 *                         All rights reserved.
 * $COPYRIGHT$
 *
 * Additional copyrights may follow
 *
 * $HEADER$
 */

#ifndef __INCLUDE_VPROTOCOL_PESSIMIST_REQUEST_H_
#define __INCLUDE_VPROTOCOL_PESSIMIST_REQUEST_H_

#include "ompi_config.h"
#include "ompi/request/request.h"
#include "../base/vprotocol_base_request.h"
#include "vprotocol_pessimist_event.h"
#include "vprotocol_pessimist_sender_based_types.h"

BEGIN_C_DECLS

typedef struct mca_vprotocol_pessimist_request_t {
    opal_list_item_t list_item; /* must always be first field */
    ompi_request_free_fn_t pml_req_free;
    vprotocol_pessimist_clock_t reqid;
    mca_vprotocol_pessimist_event_t *event;
    vprotocol_pessimist_sender_based_request_t sb;
} mca_vprotocol_pessimist_request_t;

typedef mca_vprotocol_pessimist_request_t mca_vprotocol_pessimist_recv_request_t;
typedef mca_vprotocol_pessimist_request_t mca_vprotocol_pessimist_send_request_t;

OBJ_CLASS_DECLARATION(mca_vprotocol_pessimist_recv_request_t);
OBJ_CLASS_DECLARATION(mca_vprotocol_pessimist_send_request_t);

#define VPESSIMIST_FTREQ(req) \
    ((mca_vprotocol_pessimist_request_t *) VPROTOCOL_FTREQ(req))

#define VPESSIMIST_RECV_FTREQ(req) \
    ((mca_vprotocol_pessimist_recv_request_t *) VPROTOCOL_RECV_FTREQ(req))

#define VPESSIMIST_SEND_FTREQ(req) \
    ((mca_vprotocol_pessimist_send_request_t *) VPROTOCOL_SEND_FTREQ(req))

#define VPESSIMIST_FTREQ_INIT(req) do {                                         \
        VPESSIMIST_FTREQ(req)->reqid = mca_vprotocol_pessimist.clock++;        \
} while(0)

int mca_vprotocol_pessimist_request_free(ompi_request_t **req);

END_C_DECLS

#endif /* __INCLUDE_VPROTOCOL_PESSIMIST_REQUEST_H_ */