diff --git a/src/services/mpiwrap/wrap.py b/src/services/mpiwrap/wrap.py index ca2485bb..e1a2ee08 100755 --- a/src/services/mpiwrap/wrap.py +++ b/src/services/mpiwrap/wrap.py @@ -35,7 +35,7 @@ '''Usage: wrap.py [-Gfgd] [-i pmpi_init] [-c mpicc_name] [-o file] wrapper.w [...] Python script for creating PMPI wrappers. Roughly follows the syntax of the Argonne PMPI wrapper generator, with some enhancements. - Options:" + Options: -d Just dump function declarations parsed out of mpi.h -G Generate GOTCHA instead of PMPI wrappers -f Generate fortran wrappers in addition to C wrappers. @@ -74,7 +74,7 @@ # In general, all MPI calls we care about return int. We include double # to grab MPI_Wtick and MPI_Wtime, but we'll ignore the f2c and c2f calls # that return MPI_Datatypes and other such things. -# MPI_Aint_add and MPI_Aint_diff return MPI_Aint, so include that too. +# MPI_Aint_add and MPI_Aint_diff return MPI_Aint, so include that too. rtypes = ['int', 'double', 'MPI_Aint' ] # If we find these strings in a declaration, exclude it from consideration. @@ -145,15 +145,15 @@ #undef WRAP_PY_MPI_Fint ''' -gotcha_wrapper_includes = ''' +gotcha_wrapper_includes = ''' #include -''' +''' # Macros used to suppress MPI deprecation warnings. wrapper_diagnosics_macros = ''' /* Macros to enable and disable compiler warnings for deprecated functions. - * These macros will be used to silent warnings about deprecated MPI functions, + * These macros will be used to silence warnings about deprecated MPI functions, * as these should be wrapped, even if they are deprecated. * * Note: The macros support GCC and clang compilers only. For other compilers @@ -185,7 +185,7 @@ "MPI_Op", "MPI_Request", "MPI_Status", "MPI_Datatype", "MPI_Win" ]) # MPI Calls that have array parameters, and mappings from the array parameter positions to the position -# of the 'count' paramters that determine their size +# of the 'count' parameters that determine their size mpi_array_calls = { "MPI_Startall" : { 1:0 }, "MPI_Testall" : { 1:0, 3:0 }, @@ -393,7 +393,7 @@ def __init__(self, ctype, pointers, name, array, pos): self.pointers = pointers # Pointers self.name = name # Formal parameter name (from header or autogenerated) self.array = array # Any array type information after the name - self.pos = pos # Position of arg in declartion + self.pos = pos # Position of arg in declaration self.decl = None # This gets set later by Declaration def setDeclaration(self, decl): @@ -465,7 +465,7 @@ def castType(self): if arr.count('[') > 1: pointers += '(*)' # need extra parens for, e.g., int[][3] -> int(*)[3] else: - pointers += '*' # justa single array; can pass pointer. + pointers += '*' # just a single array; can pass pointer. arr = arr.replace('[]', '') return "%s%s%s" % (self.type, pointers, arr) @@ -676,7 +676,7 @@ def write_gotcha_c_wrapper(out, decl, return_val, write_body): def write_pmpi_c_wrapper(out, decl, return_val, write_body): """Write the C wrapper for an MPI function.""" # Write the PMPI prototype here in case mpi.h doesn't define it - # (sadly the case with some MPI implementaitons) + # (sadly the case with some MPI implementations) out.write(decl.pmpi_prototype(default_modifiers)) out.write(";\n") @@ -911,7 +911,7 @@ def handle_list(list_name, array, args): index = int(args[0]) return array[index] except ValueError: - syntax_error("Invald index value: '%s'" % args[0]) + syntax_error("Invalid index value: '%s'" % args[0]) except IndexError: syntax_error("Index out of range in '%s': %d" % (list_name, index))