Fenix @develop
 
Loading...
Searching...
No Matches
fenix_data_recovery.hpp
1/*
2//@HEADER
3// ************************************************************************
4//
5//
6// _|_|_|_| _|_|_|_| _| _| _|_|_| _| _|
7// _| _| _|_| _| _| _| _|
8// _|_|_| _|_|_| _| _| _| _| _|
9// _| _| _| _|_| _| _| _|
10// _| _|_|_|_| _| _| _|_|_| _| _|
11//
12//
13//
14//
15// Copyright (C) 2016 Rutgers University and Sandia Corporation
16//
17// Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
18// the U.S. Government retains certain rights in this software.
19//
20// Redistribution and use in source and binary forms, with or without
21// modification, are permitted provided that the following conditions are
22// met:
23//
24// 1. Redistributions of source code must retain the above copyright
25// notice, this list of conditions and the following disclaimer.
26//
27// 2. Redistributions in binary form must reproduce the above copyright
28// notice, this list of conditions and the following disclaimer in the
29// documentation and/or other materials provided with the distribution.
30//
31// 3. Neither the name of the Corporation nor the names of the
32// contributors may be used to endorse or promote products derived from
33// this software without specific prior written permission.
34//
35// THIS SOFTWARE IS PROVIDED BY SANDIA CORPORATION "AS IS" AND ANY
36// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
37// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
38// PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL SANDIA CORPORATION OR THE
39// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
40// EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
41// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
42// PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
43// LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
44// NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
45// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
46//
47// Author Marc Gamell, Eric Valenzuela, Keita Teranishi, Manish Parashar,
48// Michael Heroux, and Matthew Whitlock
49//
50// Questions? Contact Keita Teranishi (knteran@sandia.gov) and
51// Marc Gamell (mgamell@cac.rutgers.edu)
52//
53// ************************************************************************
54//@HEADER
55*/
56
57#ifndef __FENIX_DATA_RECOVERY__
58#define __FENIX_DATA_RECOVERY__
59
60
61#include "fenix_data_group.hpp"
62#include "fenix_data_member.hpp"
63#include "fenix_data_subset.h"
64#include "fenix_util.hpp"
65#include <mpi.h>
66#include <stdio.h>
67#include <stdlib.h>
68#include <stdbool.h>
69#include <string.h>
70#include <sys/time.h>
71
72#define __FENIX_COMMIT_MODE 1
73#define __GROUP_ENTRY_ATTR_SIZE 4
74#define __NUM_MEMBER_ATTR_SIZE 3
75#define __GRP_MEMBER_LENTRY_ATTR_SIZE 11
76
77
78
79
80
81
82#define STORE_RANK_TAG 2000
83#define STORE_COUNT_TAG 2001
84#define STORE_SIZE_TAG 2002
85#define STORE_DATA_TAG 2003
86#define STORE_PAYLOAD_TAG 2004
87
88#define PARTNER_STATUS_TAG 1900
89#define RECOVER_GROUP_TAG 1901
90#define RECOVER_GROUP_ENTRY_TAG 1902
91#define RECOVER_MEMBER_TAG 1903
92#define RECOVER_MEMBER_ENTRY_TAG 1904
93#define RECOVERY_VERSION_TAG 1905
94#define RECOVER_SIZE_TAG 1906
95#define RECOVER_DATA_TAG 1907
96
97
98
99
100
101
102
103typedef struct __data_entry_packet {
104 int count;
105 int datatype_size;
107
108
109int __fenix_group_create(int, MPI_Comm, int, int, int, void*, int*);
110int __fenix_group_get_redundancy_policy(int, int*, int*, int*);
111int __fenix_member_create(int, int, void *, int, int);
112int __fenix_data_wait(Fenix_Request);
113int __fenix_data_test(Fenix_Request, int *);
114int __fenix_member_store(int, int, Fenix_Data_subset);
115int __fenix_member_storev(int, int, Fenix_Data_subset);
116int __fenix_member_istore(int, int, Fenix_Data_subset, Fenix_Request *);
117int __fenix_member_istorev(int, int, Fenix_Data_subset, Fenix_Request *);
118int __fenix_data_commit(int, int *);
119int __fenix_data_commit_barrier(int, int *);
120int __fenix_data_barrier(int);
121int __fenix_member_restore(int, int, void *, int, int, Fenix_Data_subset*);
122int __fenix_member_lrestore(int, int, void *, int, int, Fenix_Data_subset*);
123int __fenix_member_restore_from_rank(int, int, void *, int, int, int);
124int __fenix_get_number_of_members(int, int *);
125int __fenix_get_member_at_position(int, int *, int);
126int __fenix_get_number_of_snapshots(int, int *);
127int __fenix_get_snapshot_at_position(int, int, int *);
128int __fenix_member_get_attribute(int, int, int, void *, int *, int);
129int __fenix_member_set_attribute(int, int, int, void *, int *);
130int __fenix_snapshot_delete(int groupid, int timestamp);
131
132int __fenix_group_delete(int);
133int __fenix_member_delete(int, int);
134
135void __fenix_init_data_recovery();
136void __fenix_init_partner_copy_recovery();
137
138
139void __fenix_dr_print_store();
140void __fenix_dr_print_restore();
141void __fenix_dr_print_datastructure();
142void __fenix_store_single();
143void __fenix_store_all();
144
145#endif
Definition fenix_data_subset.h:71
<span class="mlabel"> UNIMPLEMENTED </span> As MPI_Request, but for Fenix asynchronous data recove...
Definition fenix.h:346
Definition fenix_data_recovery.hpp:103