MOAB: Mesh Oriented datABase  (version 5.4.1)
WriteHDF5.cpp File Reference
#include <cassert>
#include <ctime>
#include <cstdlib>
#include <cstring>
#include <cstdarg>
#include <limits>
#include <cstdio>
#include <iostream>
#include "WriteHDF5.hpp"
#include <H5Tpublic.h>
#include <H5Ppublic.h>
#include <H5Epublic.h>
#include "moab/Interface.hpp"
#include "Internals.hpp"
#include "MBTagConventions.hpp"
#include "moab/CN.hpp"
#include "moab/FileOptions.hpp"
#include "moab/CpuTimer.hpp"
#include "IODebugTrack.hpp"
#include "mhdf.h"
+ Include dependency graph for WriteHDF5.cpp:

Go to the source code of this file.

Classes

class  moab::CheckOpenWriteHDF5Handles

Namespaces

namespace  moab
 

Class representing axis-aligned bounding box.


Defines

#define VALGRIND_CHECK_MEM_IS_DEFINED(a, b)   ( (void)0 )
#define VALGRIND_CHECK_MEM_IS_ADDRESSABLE(a, b)   ( (void)0 )
#define VALGRIND_MAKE_MEM_UNDEFINED(a, b)   ( (void)0 )
#define WRITE_HDF5_BUFFER_SIZE   ( 40 * 1024 * 1024 )
#define CHK_MHDF_ERR_0(A)
#define CHK_MHDF_ERR_1(A, B)
#define CHK_MHDF_ERR_2(A, B)
#define CHK_MHDF_ERR_3(A, B)
#define CHK_MHDF_ERR_2C(A, B, C, D)
#define CHK_MB_ERR_0(A)
#define CHK_MB_ERR_1(A, B, C)
#define CHK_MB_ERR_2(A, B, C)
#define CHK_MB_ERR_3(A, B, C)
#define CHK_MB_ERR_2C(A, B, C, D, E)
#define debug_barrier()   debug_barrier_line( __LINE__ )
#define CHECK_OPEN_HANDLES   CheckOpenWriteHDF5Handles check_open_handles_( filePtr, __LINE__ )

Functions

template<typename T >
void VALGRIND_MAKE_VEC_UNDEFINED (std::vector< T > &)
static hid_t moab::get_id_type ()
static ErrorCode moab::error (ErrorCode rval)
static herr_t moab::handle_hdf5_error (void *data)
template<class HandleRangeIter >
size_t moab::count_num_handles (HandleRangeIter iter, HandleRangeIter end)
template<class HandleRangeIter >
ErrorCode moab::range_to_id_list_templ (HandleRangeIter begin, HandleRangeIter end, const RangeMap< EntityHandle, WriteHDF5::wid_t > &idMap, WriteHDF5::wid_t *array)
template<class HandleRangeIter >
ErrorCode moab::range_to_blocked_list_templ (HandleRangeIter begin, HandleRangeIter end, const RangeMap< EntityHandle, WriteHDF5::wid_t > &idMap, std::vector< WriteHDF5::wid_t > &output_id_list, bool &ranged_list)

Define Documentation

#define CHK_MB_ERR_1 (   A,
  B,
 
)
Value:
do                                                \
    {                                                 \
        if( MB_SUCCESS != ( A ) )                     \
        {                                             \
            MB_CHK_ERR_CONT( ( A ) );                 \
            mhdf_closeData( filePtr, ( B ), &( C ) ); \
            assert( 0 );                              \
            return error( A );                        \
        }                                             \
    } while( false )

Definition at line 237 of file WriteHDF5.cpp.

Referenced by moab::WriteHDF5::write_adjacencies(), moab::WriteHDF5::write_elems(), moab::WriteHDF5::write_nodes(), moab::WriteHDF5::write_sets(), and moab::WriteHDF5::write_var_len_tag().

#define CHK_MB_ERR_2 (   A,
  B,
 
)
Value:
do                                                   \
    {                                                    \
        if( MB_SUCCESS != ( A ) )                        \
        {                                                \
            MB_CHK_ERR_CONT( ( A ) );                    \
            mhdf_closeData( filePtr, ( B )[0], &( C ) ); \
            mhdf_closeData( filePtr, ( B )[1], &( C ) ); \
            write_finished();                            \
            assert( 0 );                                 \
            return error( A );                           \
        }                                                \
    } while( false )

Definition at line 249 of file WriteHDF5.cpp.

Referenced by moab::WriteHDF5::write_sparse_tag(), and moab::WriteHDF5::write_var_len_tag().

#define CHK_MB_ERR_2C (   A,
  B,
  C,
  D,
 
)
Value:
do                                                        \
    {                                                         \
        if( MB_SUCCESS != ( A ) )                             \
        {                                                     \
            MB_CHK_ERR_CONT( ( A ) );                         \
            mhdf_closeData( filePtr, ( B ), &( E ) );         \
            if( C ) mhdf_closeData( filePtr, ( D ), &( E ) ); \
            write_finished();                                 \
            assert( 0 );                                      \
            return error( A );                                \
        }                                                     \
    } while( false )

Definition at line 278 of file WriteHDF5.cpp.

#define CHK_MB_ERR_3 (   A,
  B,
 
)
Value:
do                                                   \
    {                                                    \
        if( MB_SUCCESS != ( A ) )                        \
        {                                                \
            MB_CHK_ERR_CONT( ( A ) );                    \
            mhdf_closeData( filePtr, ( B )[0], &( C ) ); \
            mhdf_closeData( filePtr, ( B )[1], &( C ) ); \
            mhdf_closeData( filePtr, ( B )[2], &( C ) ); \
            write_finished();                            \
            assert( 0 );                                 \
            return error( A );                           \
        }                                                \
    } while( false )

Definition at line 263 of file WriteHDF5.cpp.

#define CHK_MHDF_ERR_1 (   A,
 
)
Value:
do                                                 \
    {                                                  \
        if( mhdf_isError( &( A ) ) )                   \
        {                                              \
            MB_SET_ERR_CONT( mhdf_message( &( A ) ) ); \
            assert( 0 );                               \
            mhdf_closeData( filePtr, ( B ), &( A ) );  \
            return error( MB_FAILURE );                \
        }                                              \
    } while( false )

Definition at line 175 of file WriteHDF5.cpp.

Referenced by moab::WriteHDF5::write_adjacencies(), moab::WriteHDF5::write_elems(), moab::WriteHDF5::write_nodes(), moab::WriteHDF5::write_sets(), moab::WriteHDF5::write_sparse_tag(), and moab::WriteHDF5::write_var_len_tag().

#define CHK_MHDF_ERR_2 (   A,
 
)
Value:
do                                                   \
    {                                                    \
        if( mhdf_isError( &( A ) ) )                     \
        {                                                \
            MB_SET_ERR_CONT( mhdf_message( &( A ) ) );   \
            assert( 0 );                                 \
            mhdf_closeData( filePtr, ( B )[0], &( A ) ); \
            mhdf_closeData( filePtr, ( B )[1], &( A ) ); \
            return error( MB_FAILURE );                  \
        }                                                \
    } while( false )

Definition at line 187 of file WriteHDF5.cpp.

Referenced by moab::WriteHDF5::write_var_len_tag().

#define CHK_MHDF_ERR_2C (   A,
  B,
  C,
 
)
Value:
do                                                        \
    {                                                         \
        if( mhdf_isError( &( A ) ) )                          \
        {                                                     \
            MB_SET_ERR_CONT( mhdf_message( &( A ) ) );        \
            assert( 0 );                                      \
            mhdf_closeData( filePtr, ( B ), &( A ) );         \
            if( C ) mhdf_closeData( filePtr, ( D ), &( A ) ); \
            return error( MB_FAILURE );                       \
        }                                                     \
    } while( false )

Definition at line 214 of file WriteHDF5.cpp.

#define CHK_MHDF_ERR_3 (   A,
 
)
Value:
do                                                   \
    {                                                    \
        if( mhdf_isError( &( A ) ) )                     \
        {                                                \
            MB_SET_ERR_CONT( mhdf_message( &( A ) ) );   \
            assert( 0 );                                 \
            mhdf_closeData( filePtr, ( B )[0], &( A ) ); \
            mhdf_closeData( filePtr, ( B )[1], &( A ) ); \
            mhdf_closeData( filePtr, ( B )[2], &( A ) ); \
            return error( MB_FAILURE );                  \
        }                                                \
    } while( false )

Definition at line 200 of file WriteHDF5.cpp.

#define VALGRIND_CHECK_MEM_IS_ADDRESSABLE (   a,
 
)    ( (void)0 )

Definition at line 76 of file WriteHDF5.cpp.

#define VALGRIND_CHECK_MEM_IS_DEFINED (   a,
 
)    ( (void)0 )

MOAB, a Mesh-Oriented datABase, is a software component for creating, storing and accessing finite element mesh data.

Copyright 2004 Sandia Corporation. Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains certain rights in this software.

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.

Definition at line 73 of file WriteHDF5.cpp.

#define WRITE_HDF5_BUFFER_SIZE   ( 40 * 1024 * 1024 )

Definition at line 93 of file WriteHDF5.cpp.

Referenced by moab::WriteHDF5::write_file().


Function Documentation

template<typename T >
void VALGRIND_MAKE_VEC_UNDEFINED ( std::vector< T > &  ) [inline]

Definition at line 83 of file WriteHDF5.cpp.

References VALGRIND_MAKE_MEM_UNDEFINED.

{
    (void)VALGRIND_MAKE_MEM_UNDEFINED( 0, 0 );
}
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines