Skip to content

Commit 2cd8499

Browse files
committed
ompi: remove MPI functions and datatypes removed in MPI-3.0
This commit removes the functions that were removed from MPI-3.0 back in 2012. Signed-off-by: Nathan Hjelm <[email protected]>
1 parent 093b55a commit 2cd8499

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+120
-3046
lines changed

ompi/datatype/ompi_datatype_args.c

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* Copyright (c) 2004-2006 The Regents of the University of California.
1212
* All rights reserved.
1313
* Copyright (c) 2009 Oak Ridge National Labs. All rights reserved.
14-
* Copyright (c) 2013-2017 Los Alamos National Security, LLC. All rights
14+
* Copyright (c) 2013-2018 Los Alamos National Security, LLC. All rights
1515
* reserved.
1616
* Copyright (c) 2015-2017 Research Organization for Information Science
1717
* and Technology (RIST). All rights reserved.
@@ -839,19 +839,17 @@ ompi_datatype_t* ompi_datatype_get_single_predefined_type_from_args( ompi_dataty
839839
return NULL;
840840
}
841841
}
842-
if (current_predef != MPI_LB && current_predef != MPI_UB) {
843-
if( NULL == predef ) { /* This is the first iteration */
844-
predef = current_predef;
845-
} else {
846-
/**
847-
* What exactly should we consider as identical types?
848-
* If they are the same MPI level type, or if they map
849-
* to the same OPAL datatype? In other words, MPI_FLOAT
850-
* and MPI_REAL4 are they identical?
851-
*/
852-
if( predef != current_predef ) {
853-
return NULL;
854-
}
842+
if( NULL == predef ) { /* This is the first iteration */
843+
predef = current_predef;
844+
} else {
845+
/**
846+
* What exactly should we consider as identical types?
847+
* If they are the same MPI level type, or if they map
848+
* to the same OPAL datatype? In other words, MPI_FLOAT
849+
* and MPI_REAL4 are they identical?
850+
*/
851+
if( predef != current_predef ) {
852+
return NULL;
855853
}
856854
}
857855
}

ompi/datatype/ompi_datatype_internal.h

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
* reserved.
66
* Copyright (c) 2009 Oak Ridge National Labs. All rights reserved.
77
* Copyright (c) 2010-2012 Cisco Systems, Inc. All rights reserved.
8-
* Copyright (c) 2013 Los Alamos National Security, LLC. All rights
8+
* Copyright (c) 2013-2018 Los Alamos National Security, LLC. All rights
99
* reserved.
1010
* Copyright (c) 2015-2018 Research Organization for Information Science
1111
* and Technology (RIST). All rights reserved.
@@ -91,9 +91,6 @@
9191
#define OMPI_DATATYPE_MPI_C_DOUBLE_COMPLEX 0x2A
9292
#define OMPI_DATATYPE_MPI_C_LONG_DOUBLE_COMPLEX 0x2B
9393

94-
#define OMPI_DATATYPE_MPI_LB 0x2C
95-
#define OMPI_DATATYPE_MPI_UB 0x2D
96-
9794
/*
9895
* Datatypes from the MPI 3.0 standard
9996
*/

ompi/datatype/ompi_datatype_module.c

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
* Copyright (c) 2007-2012 Cisco Systems, Inc. All rights reserved.
1414
* Copyright (c) 2009 Sun Microsystems, Inc. All rights reserved.
1515
* Copyright (c) 2009 Oak Ridge National Labs. All rights reserved.
16-
* Copyright (c) 2013 Los Alamos National Security, LLC. All rights
16+
* Copyright (c) 2013-2018 Los Alamos National Security, LLC. All rights
1717
* reserved.
1818
* Copyright (c) 2015-2018 Research Organization for Information Science
1919
* and Technology (RIST). All rights reserved.
@@ -67,8 +67,6 @@ ompi_predefined_datatype_t ompi_mpi_datatype_null =
6767

6868
ompi_predefined_datatype_t ompi_mpi_unavailable = OMPI_DATATYPE_INIT_PREDEFINED (UNAVAILABLE, 0);
6969

70-
ompi_predefined_datatype_t ompi_mpi_lb = OMPI_DATATYPE_INIT_PREDEFINED (LB, 0);
71-
ompi_predefined_datatype_t ompi_mpi_ub = OMPI_DATATYPE_INIT_PREDEFINED (UB, 0);
7270
ompi_predefined_datatype_t ompi_mpi_char = OMPI_DATATYPE_INIT_PREDEFINED (CHAR, OMPI_DATATYPE_FLAG_DATA_C);
7371
ompi_predefined_datatype_t ompi_mpi_signed_char = OMPI_DATATYPE_INIT_PREDEFINED (SIGNED_CHAR, OMPI_DATATYPE_FLAG_DATA_C | OMPI_DATATYPE_FLAG_DATA_INT );
7472
ompi_predefined_datatype_t ompi_mpi_unsigned_char = OMPI_DATATYPE_INIT_PREDEFINED (UNSIGNED_CHAR, OMPI_DATATYPE_FLAG_DATA_C | OMPI_DATATYPE_FLAG_DATA_INT );
@@ -357,9 +355,6 @@ const ompi_datatype_t* ompi_datatype_basicDatatypes[OMPI_DATATYPE_MPI_MAX_PREDEF
357355
[OMPI_DATATYPE_MPI_C_DOUBLE_COMPLEX] = &ompi_mpi_c_double_complex.dt,
358356
[OMPI_DATATYPE_MPI_C_LONG_DOUBLE_COMPLEX] = &ompi_mpi_c_long_double_complex.dt,
359357

360-
[OMPI_DATATYPE_MPI_LB] = &ompi_mpi_lb.dt,
361-
[OMPI_DATATYPE_MPI_UB] = &ompi_mpi_ub.dt,
362-
363358
/* MPI 3.0 types */
364359
[OMPI_DATATYPE_MPI_COUNT] = &ompi_mpi_count.dt,
365360

ompi/include/mpi.h.in

Lines changed: 1 addition & 103 deletions
Large diffs are not rendered by default.

ompi/mca/coll/portals4/coll_portals4_component.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,9 +110,6 @@ ptl_datatype_t ompi_coll_portals4_atomic_datatype [OMPI_DATATYPE_MPI_MAX_PREDEFI
110110
[OMPI_DATATYPE_MPI_C_DOUBLE_COMPLEX] = COLL_PORTALS4_NO_DTYPE,
111111
[OMPI_DATATYPE_MPI_C_LONG_DOUBLE_COMPLEX] = COLL_PORTALS4_NO_DTYPE,
112112

113-
[OMPI_DATATYPE_MPI_LB] = COLL_PORTALS4_NO_DTYPE,
114-
[OMPI_DATATYPE_MPI_UB] = COLL_PORTALS4_NO_DTYPE,
115-
116113
/* MPI 3.0 types */
117114
[OMPI_DATATYPE_MPI_COUNT] = COLL_PORTALS4_NO_DTYPE,
118115

ompi/mpi/c/#alloc_mem.c#

Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
/* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil -*- */
2+
/*
3+
* Copyright (c) 2004-2007 The Trustees of Indiana University and Indiana
4+
* University Research and Technology
5+
* Corporation. All rights reserved.
6+
* Copyright (c) 2004-2005 The University of Tennessee and The University
7+
* of Tennessee Research Foundation. All rights
8+
* reserved.
9+
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
10+
* University of Stuttgart. All rights reserved.
11+
* Copyright (c) 2004-2005 The Regents of the University of California.
12+
* All rights reserved.
13+
* Copyright (c) 2007 Cisco Systems, Inc. All rights reserved.
14+
* Copyright (c) 2015 Research Organization for Information Science
15+
* and Technology (RIST). All rights reserved.
16+
* Copyright (c) 2015 Los Alamos National Security, LLC. All rights
17+
* reserved.
18+
* $COPYRIGHT$
19+
*
20+
* Additional copyrights may follow
21+
*
22+
* $HEADER$
23+
*/
24+
25+
#include "ompi_config.h"
26+
27+
#include <stdio.h>
28+
#include <stdlib.h>
29+
30+
#include "ompi/mpi/c/bindings.h"
31+
#include "ompi/runtime/params.h"
32+
#include "ompi/communicator/communicator.h"
33+
#include "ompi/errhandler/errhandler.h"
34+
#include "ompi/info/info.h"
35+
#include "opal/mca/mpool/mpool.h"
36+
37+
#if OMPI_BUILD_MPI_PROFILING
38+
#if OPAL_HAVE_WEAK_SYMBOLS
39+
#pragma weak MPI_Alloc_mem = PMPI_Alloc_mem
40+
#endif
41+
#define MPI_Alloc_mem PMPI_Alloc_mem
42+
#endif
43+
44+
static const char FUNC_NAME[] = "MPI_Alloc_mem";
45+
46+
47+
int MPI_Alloc_mem(MPI_Aint size, MPI_Info info, void *baseptr)
48+
{
49+
char info_value[MPI_MAX_INFO_VAL + 1];
50+
char *mpool_hints = NULL;
51+
52+
if (MPI_PARAM_CHECK) {
53+
OMPI_ERR_INIT_FINALIZE(FUNC_NAME);
54+
if (size < 0 || NULL == baseptr) {
55+
return OMPI_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_ARG,
56+
FUNC_NAME);
57+
} else if (NULL == info || ompi_info_is_freed(info)) {
58+
return OMPI_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_INFO,
59+
FUNC_NAME);
60+
}
61+
}
62+
63+
/* Per these threads:
64+
65+
http://www.open-mpi.org/community/lists/devel/2007/07/1977.php
66+
http://www.open-mpi.org/community/lists/devel/2007/07/1979.php
67+
68+
If you call MPI_ALLOC_MEM with a size of 0, you get NULL
69+
back .*/
70+
if (0 == size) {
71+
*((void **) baseptr) = NULL;
72+
return MPI_SUCCESS;
73+
}
74+
75+
OPAL_CR_ENTER_LIBRARY();
76+
77+
if (MPI_INFO_NULL != info) {
78+
int flag;
79+
(void) ompi_info_get (info, "mpool_hints", MPI_MAX_INFO_VAL, info_value, &flag);
80+
if (flag) {
81+
mpool_hints = info_value;
82+
}
83+
}
84+
85+
*((void **) baseptr) = mca_mpool_base_alloc ((size_t) size, (struct opal_info_t*)info,
86+
mpool_hints);
87+
OPAL_CR_EXIT_LIBRARY();
88+
if (NULL == *((void **) baseptr)) {
89+
return OMPI_ERRHANDLER_INVOKE(MPI_COMM_WORLD, MPI_ERR_NO_MEM,
90+
FUNC_NAME);
91+
}
92+
93+
/* All done */
94+
return MPI_SUCCESS;
95+
}
96+

ompi/mpi/c/.#alloc_mem.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
hjelmn@mordor.lanl.gov.595

ompi/mpi/c/Makefile.am

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,6 @@ libmpi_c_mpi_la_SOURCES = \
6565
add_error_class.c \
6666
add_error_code.c \
6767
add_error_string.c \
68-
address.c \
6968
allgather.c \
7069
iallgather.c \
7170
allgatherv.c \
@@ -79,9 +78,6 @@ libmpi_c_mpi_la_SOURCES = \
7978
ialltoallv.c \
8079
alltoallw.c \
8180
ialltoallw.c \
82-
attr_delete.c \
83-
attr_get.c \
84-
attr_put.c \
8581
barrier.c \
8682
ibarrier.c \
8783
bcast.c \
@@ -144,11 +140,8 @@ libmpi_c_mpi_la_SOURCES = \
144140
compare_and_swap.c \
145141
dims_create.c \
146142
errhandler_c2f.c \
147-
errhandler_create.c \
148143
errhandler_f2c.c \
149144
errhandler_free.c \
150-
errhandler_get.c \
151-
errhandler_set.c \
152145
error_class.c \
153146
error_string.c \
154147
exscan.c \
@@ -277,8 +270,6 @@ libmpi_c_mpi_la_SOURCES = \
277270
is_thread_main.c \
278271
isend.c \
279272
issend.c \
280-
keyval_create.c \
281-
keyval_free.c \
282273
lookup_name.c \
283274
message_f2c.c \
284275
message_c2f.c \
@@ -370,7 +361,6 @@ libmpi_c_mpi_la_SOURCES = \
370361
type_create_subarray.c \
371362
type_delete_attr.c \
372363
type_dup.c \
373-
type_extent.c \
374364
type_f2c.c \
375365
type_free.c \
376366
type_free_keyval.c \
@@ -382,17 +372,12 @@ libmpi_c_mpi_la_SOURCES = \
382372
type_get_name.c \
383373
type_get_true_extent.c \
384374
type_get_true_extent_x.c \
385-
type_hindexed.c \
386-
type_hvector.c \
387375
type_indexed.c \
388-
type_lb.c \
389376
type_match_size.c \
390377
type_set_attr.c \
391378
type_set_name.c \
392379
type_size.c \
393380
type_size_x.c \
394-
type_struct.c \
395-
type_ub.c \
396381
type_vector.c \
397382
unpack_external.c \
398383
unpack.c \

ompi/mpi/c/address.c

Lines changed: 0 additions & 53 deletions
This file was deleted.

ompi/mpi/c/attr_delete.c

Lines changed: 0 additions & 65 deletions
This file was deleted.

0 commit comments

Comments
 (0)