summaryrefslogtreecommitdiffstats
path: root/pablo
diff options
context:
space:
mode:
authorElena Pourmal <epourmal@hdfgroup.org>2005-01-20 22:50:40 (GMT)
committerElena Pourmal <epourmal@hdfgroup.org>2005-01-20 22:50:40 (GMT)
commit2cd3b4c609eb07baaa0f795983fd2ac85a7d9579 (patch)
treed49d88116f2ab7c165a9b67f31c00d966b2c7845 /pablo
parente4394cd2fb18ed8ca6f38dc3d8fb534a24a289c4 (diff)
downloadhdf5-2cd3b4c609eb07baaa0f795983fd2ac85a7d9579.zip
hdf5-2cd3b4c609eb07baaa0f795983fd2ac85a7d9579.tar.gz
hdf5-2cd3b4c609eb07baaa0f795983fd2ac85a7d9579.tar.bz2
[svn-r9852] Purpose: Maintenance
Description: Removed PABLO instrumentation from HDF5 source Solution: Platforms tested: arabica, copper (parallel), mir Misc. update:
Diffstat (limited to 'pablo')
-rw-r--r--pablo/HDFIOTrace.h423
-rw-r--r--pablo/HDFTrace.h173
-rw-r--r--pablo/HDFmpioProtos.h77
-rw-r--r--pablo/HDFrecord_RT.h215
-rw-r--r--pablo/Makefile.in314
-rw-r--r--pablo/PabloHDF.c1416
-rw-r--r--pablo/PabloHDF_MPIO.c1366
-rw-r--r--pablo/PabloHDF_RT.c1686
-rw-r--r--pablo/PabloHDF_SDDF.c820
-rw-r--r--pablo/PabloHDFff.f62
-rw-r--r--pablo/PabloSedscr31
-rw-r--r--pablo/ProcIDs.h165
-rw-r--r--pablo/ProcTrace.h108
-rw-r--r--pablo/READ_ME18
14 files changed, 0 insertions, 6874 deletions
diff --git a/pablo/HDFIOTrace.h b/pablo/HDFIOTrace.h
deleted file mode 100644
index 4c88403..0000000
--- a/pablo/HDFIOTrace.h
+++ /dev/null
@@ -1,423 +0,0 @@
-/*
- * This file is part of the Pablo Performance Analysis Environment
- *
- * (R)
- * The Pablo Performance Analysis Environment software is NOT in
- * the public domain. However, it is freely available without fee for
- * education, research, and non-profit purposes. By obtaining copies
- * of this and other files that comprise the Pablo Performance Analysis
- * Environment, you, the Licensee, agree to abide by the following
- * conditions and understandings with respect to the copyrighted software:
- *
- * 1. The software is copyrighted in the name of the Board of Trustees
- * of the University of Illinois (UI), and ownership of the software
- * remains with the UI.
- *
- * 2. Permission to use, copy, and modify this software and its documentation
- * for education, research, and non-profit purposes is hereby granted
- * to Licensee, provided that the copyright notice, the original author's
- * names and unit identification, and this permission notice appear on
- * all such copies, and that no charge be made for such copies. Any
- * entity desiring permission to incorporate this software into commercial
- * products should contact:
- *
- * Professor Daniel A. Reed reed@cs.uiuc.edu
- * University of Illinois
- * Department of Computer Science
- * 2413 Digital Computer Laboratory
- * 1304 West Springfield Avenue
- * Urbana, Illinois 61801
- * USA
- *
- * 3. Licensee may not use the name, logo, or any other symbol of the UI
- * nor the names of any of its employees nor any adaptation thereof in
- * advertizing or publicity pertaining to the software without specific
- * prior written approval of the UI.
- *
- * 4. THE UI MAKES NO REPRESENTATIONS ABOUT THE SUITABILITY OF THE
- * SOFTWARE FOR ANY PURPOSE. IT IS PROVIDED "AS IS" WITHOUT EXPRESS
- * OR IMPLIED WARRANTY.
- *
- * 5. The UI shall not be liable for any damages suffered by Licensee from
- * the use of this software.
- *
- * 6. The software was developed under agreements between the UI and the
- * Federal Government which entitle the Government to certain rights.
- *
- **************************************************************************
- *
- * Developed by: The Pablo Research Group
- * University of Illinois at Urbana-Champaign
- * Department of Computer Science
- * 1304 W. Springfield Avenue
- * Urbana, IL 61801
- *
- * http://www-pablo.cs.uiuc.edu
- *
- * Send comments to: pablo-feedback@guitar.cs.uiuc.edu
- *
- * Copyright (c) 1991-1996
- * The University of Illinois Board of Trustees.
- * All Rights Reserved.
- *
- * PABLO is a registered trademark of
- * The Board of Trustees of the University of Illinois
- * registered in the U.S. Patent and Trademark Office.
- *
- * Author: Ruth A. Aydt (aydt@cs.uiuc.edu)
- * Author: Tara M. Madhyastha (tara@cs.uiuc.edu)
- *
- * Project Manager and Principal Investigator:
- * Daniel A. Reed (reed@cs.uiuc.edu)
- *
- * Funded in part by National Science Foundation grants NSF CCR87-06653
- * and NSF CDA87-22836 (Tapestry), DARPA contracts DABT63-91-K-0004,
- * DABT63-93-C-0040, DABT63-94-C-0049 (SIO), and F30602-96-C-0161, NASA
- * contracts NAG-1-613 (ICLASS), USRA 5555-22, and NGT-51023, and a
- * collaborative research agreement with the Intel Supercomputer
- * Systems Division
- */
-
-/*
- * HDFIOTrace.h: This header file can be included in c source files to
- * automatically redefine the I/O function calls to the
- * tracing versions when "IOTRACE" is defined.
- *
- * It also contains function declarations for the I/O trace
- * routines called from user code and constant values that may
- * be needed by the user.
- *
- */
-#ifndef HDFIOTrace_h
-#define HDFIOTrace_h
-
-
-/************************************************************************/
-/* These defines and the external variable OUTPUT_SWITCH are used in */
-/* for HDF and MPI-IO tracing to govern the type of output produced. */
-/************************************************************************/
-extern int OUTPUT_SWITCH; /* default is SDDF records */
-
-#if defined(__STDC__) || defined(__cplusplus)
-#define PROTO(x) x
-#else
-#define PROTO(x) ()
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* #include <stdio.h> */
-#include <sys/types.h>
-
-void startHDFtraceEvent (int );
-void endHDFtraceEvent (int , int , char *, int );
-
-FILE *HDFtraceFOPEN( const char *filename, const char *type ) ;
-#ifndef HDFtrace3OPEN__
- int HDFtrace3OPEN( const char *path, int flags, ... ) ;
-#endif
-int HDFtraceCREAT( const char *path, mode_t mode );
-int HDFtraceFFLUSH( FILE *stream ) ;
-int HDFtraceFCLOSE( FILE *stream ) ;
-int HDFtraceCLOSE( int fd ) ;
-ssize_t HDFtraceREAD( int fd, void *buf, size_t nbyte );
-size_t HDFtraceFREAD( void *ptr, size_t size, size_t nitems, FILE *stream );
-void *HDFtraceMALLOC( size_t );
-off_t HDFtraceLSEEK( int fd, off_t offset, int whence ) ;
-int HDFtraceFSEEK( FILE *stream, long offset, int whence ) ;
-int HDFtraceFSETPOS( FILE *stream, const fpos_t *position ) ;
-void HDFtraceREWIND( FILE *stream ) ;
-ssize_t HDFtraceWRITE( int fd, const void *buf, size_t nbytes );
-size_t HDFtraceFWRITE( const void *, size_t , size_t , FILE * );
-int HDFtracePUTS( const char *s ) ;
-int HDFtraceFPUTC( int c, FILE *stream ) ;
-int HDFtraceFPUTS( const char *s, FILE *stream ) ;
-
-#ifdef HDFIOTRACE
-/*
- * If IOTRACE is defined, then redefine standard I/O routines to tracing
- * versions. Also include the appropriate .h files so the function
- * declarations from them will be redefined to traced versions.
- */
-
-#ifdef fopen
-# undef fopen
-#endif
-#ifdef open
-# undef open
-#endif
-#ifdef creat
-# undef creat
-#endif
-
-#ifdef fflush
-# undef fflush
-#endif
-#ifdef fclose
-# undef fclose
-#endif
-#ifdef close
-# undef close
-#endif
-
-#ifdef read
-# undef read
-#endif
-#ifdef fread
-# undef fread
-#endif
-#ifdef fgetc
-# undef fgetc
-#endif
-#ifdef fgets
-# undef fgets
-#endif
-#ifdef gets
-# undef gets
-#endif
-#ifdef getw
-# undef getw
-#endif
-
-#ifdef lseek
-# undef lseek
-#endif
-#ifdef fseek
-# undef fseek
-#endif
-#ifdef rewind
-# undef rewind
-#endif
-#ifdef fsetpos
-# undef fsetpos
-#endif
-
-#ifdef write
-# undef write
-#endif
-#ifdef fwrite
-# undef fwrite
-#endif
-#ifdef fputc
-# undef fputc
-#endif
-#ifdef fputs
-# undef fputs
-#endif
-#ifdef puts
-# undef puts
-#endif
-#ifdef putw
-# undef putw
-#endif
-
-#ifdef malloc
-# undef malloc
-#endif
-
-#define fopen (FILE *)HDFtraceFOPEN
-#define open HDFtrace3OPEN
-#define creat HDFtraceCREAT
-
-#define fflush HDFtraceFFLUSH
-#define fclose HDFtraceFCLOSE
-#define close HDFtraceCLOSE
-
-#define read HDFtraceREAD
-#define fread HDFtraceFREAD
-#define fgetc HDFtraceFGETC
-#define fgets HDFtraceFGETS
-#define gets HDFtraceGETS
-#define getw HDFtraceGETW
-
-#define lseek HDFtraceLSEEK
-#define fseek HDFtraceFSEEK
-#define rewind HDFtraceREWIND
-#define fsetpos HDFtraceFSETPOS
-
-#define write HDFtraceWRITE
-#define fwrite HDFtraceFWRITE
-#define fputc HDFtraceFPUTC
-#define fputs HDFtraceFPUTS
-#define puts HDFtracePUTS
-#define putw HDFtracePUTW
-
-#define malloc HDFtraceMALLOC
-
-#include <stdio.h>
-#include <fcntl.h>
-
-/*
- * On the iPSC/860 we don't include unistd.h or we get warnings about
- * SEEK_* multiply defined.
- */
-#ifndef __NX
-#include <unistd.h>
-#endif
-
-
-#include <stdio.h>
-/*
- * Function declarations for routines that can be called from user code.
- */
-void enableIOtracing( void );
-void disableIOtracing( void );
-
-void enableIOdetail( void );
-void disableIOdetail( void );
-
-void enableLifetimeSummaries( void );
-void disableLifetimeSummaries( void );
-
-void enableTimeWindowSummaries ( double );
-void disableTimeWindowSummaries( void );
-void setTimeWindowSize ( double );
-void outputTimeWindowSummaries( void );
-
-void enableFileRegionSummaries ( int );
-void disableFileRegionSummaries( void );
-void setFileRegionSize ( int );
-void outputFileRegionSummaries( void );
-
-int HDFtrace2OPEN ( char*, int );
-void HDFtraceReadBegin ( int, int, int );
-void HDFtraceReadEnd ( int );
-void HDFtraceWriteBegin ( int, int, int );
-void HDFtraceWriteEnd ( int );
-void HDFtraceIOBegin ( int, int );
-void HDFtraceIOEnd ( int, double, char * );
-
-#ifdef H5_HAVE_PARALLEL
-
-#include "HDFmpioProtos.h"
-
-/*
-#ifdef MPI_File_open
-#undef MPI_File_open
-#endif
-#ifdef MPI_File_close
-#undef MPI_File_close
-#endif
-#ifdef MPI_File_delete
-#undef MPI_File_delete
-#endif
-#ifdef MPI_File_set_size
-#undef MPI_File_set_size
-#endif
-#ifdef MPI_File_preallocate
-#undef MPI_File_preallocate
-#endif
-#ifdef MPI_File_get_size
-#undef MPI_File_get_size
-#endif
-#ifdef MPI_File_get_group
-#undef MPI_File_get_group
-#endif
-#ifdef MPI_File_get_amode
-#undef MPI_File_get_amode
-#endif
-#ifdef MPI_File_set_view
-#undef MPI_File_set_view
-#endif
-#ifdef MPI_File_get_view
-#undef MPI_File_get_view
-#endif
-#ifdef MPI_File_read_at
-#undef MPI_File_read_at
-#endif
-#ifdef MPI_File_read_at_all
-#undef MPI_File_read_at_all
-#endif
-#ifdef MPI_File_write_at
-#undef MPI_File_write_at
-#endif
-#ifdef MPI_File_write_at_all
-#undef MPI_File_write_at_all
-#endif
-#ifdef MPI_File_iread_at
-#undef MPI_File_iread_at
-#endif
-#ifdef MPI_File_iwrite_at
-#undef MPI_File_iwrite_at
-#endif
-#ifdef MPI_File_read
-#undef MPI_File_read
-#endif
-#ifdef MPI_File_read_all
-#undef MPI_File_read_all
-#endif
-#ifdef MPI_File_write
-#undef MPI_File_write
-#endif
-#ifdef MPI_File_write_all
-#undef MPI_File_write_all
-#endif
-#ifdef MPI_File_iread
-#undef MPI_File_iread
-#endif
-#ifdef MPI_File_iwrite
-#undef MPI_File_iwrite
-#endif
-#ifdef MPI_File_seek
-#undef MPI_File_seek
-#endif
-#ifdef MPI_File_get_position
-#undef MPI_File_get_position
-#endif
-#ifdef MPI_File_get_byte_offset
-#undef MPI_File_get_byte_offset
-#endif
-#ifdef MPI_File_get_type_extent
-#undef MPI_File_get_type_extent
-#endif
-#ifdef MPI_File_set_atomicity
-#undef MPI_File_set_atomicity
-#endif
-#ifdef MPI_File_get_atomicity
-#undef MPI_File_get_atomicity
-#endif
-#ifdef MPI_File_sync
-#undef MPI_File_sync
-#endif
-
-#define MPI_File_open HDF_MPI_File_open
-#define MPI_File_close HDF_MPI_File_close
-#define MPI_File_delete HDF_MPI_File_delete
-#define MPI_File_set_size HDF_MPI_File_set_size
-#define MPI_File_preallocate HDF_MPI_File_preallocate
-#define MPI_File_get_size HDF_MPI_File_get_size
-#define MPI_File_get_group HDF_MPI_File_get_group
-#define MPI_File_get_amode HDF_MPI_File_get_amode
-#define MPI_File_set_view HDF_MPI_File_set_view
-#define MPI_File_get_view HDF_MPI_File_get_view
-#define MPI_File_read_at HDF_MPI_File_read_at
-#define MPI_File_read_at_all HDF_MPI_File_read_at_all
-#define MPI_File_write_at HDF_MPI_File_write_at
-#define MPI_File_write_at_all HDF_MPI_File_write_at_all
-#define MPI_File_iread_at HDF_MPI_File_iread_at
-#define MPI_File_iwrite_at HDF_MPI_File_iwrite_at
-#define MPI_File_read HDF_MPI_File_read
-#define MPI_File_read_all HDF_MPI_File_read_all
-#define MPI_File_write HDF_MPI_File_write
-#define MPI_File_write_all HDF_MPI_File_write_all
-#define MPI_File_iread HDF_MPI_File_iread
-#define MPI_File_iwrite HDF_MPI_File_iwrite
-#define MPI_File_seek HDF_MPI_File_seek
-#define MPI_File_get_position HDF_MPI_File_get_position
-#define MPI_File_get_byte_offset HDF_MPI_File_get_byte_offset
-#define MPI_File_get_type_extent HDF_MPI_File_get_type_extent
-#define MPI_File_set_atomicity HDF_MPI_File_set_atomicity
-#define MPI_File_get_atomicity HDF_MPI_File_get_atomicity
-#define MPI_File_sync HDF_MPI_File_sync
-#endif
-*/
-#endif
-#endif
-#ifdef __cplusplus
-}
-
-#endif /* H5_HAVE_PARALLEL */
-
-#endif /* HDFIOTRACE conditional */
diff --git a/pablo/HDFTrace.h b/pablo/HDFTrace.h
deleted file mode 100644
index a8e2a47..0000000
--- a/pablo/HDFTrace.h
+++ /dev/null
@@ -1,173 +0,0 @@
-/* This file is part of the Pablo Performance Analysis Environment
-//
-// (R)
-// The Pablo Performance Analysis Environment software is NOT in
-// the public domain. However, it is freely available without fee for
-// education, research, and non-profit purposes. By obtaining copies
-// of this and other files that comprise the Pablo Performance Analysis
-// Environment, you, the Licensee, agree to abide by the following
-// conditions and understandings with respect to the copyrighted software:
-//
-// 1. The software is copyrighted in the name of the Board of Trustees
-// of the University of Illinois (UI), and ownership of the software
-// remains with the UI.
-//
-// 2. Permission to use, copy, and modify this software and its documentation
-// for education, research, and non-profit purposes is hereby granted
-// to Licensee, provided that the copyright notice, the original author's
-// names and unit identification, and this permission notice appear on
-// all such copies, and that no charge be made for such copies. Any
-// entity desiring permission to incorporate this software into commercial
-// products should contact:
-//
-// Professor Daniel A. Reed reed@cs.uiuc.edu
-// University of Illinois
-// Department of Computer Science
-// 2413 Digital Computer Laboratory
-// 1304 West Springfield Avenue
-// Urbana, Illinois 61801
-// USA
-//
-// 3. Licensee may not use the name, logo, or any other symbol of the UI
-// nor the names of any of its employees nor any adaptation thereof in
-// advertizing or publicity pertaining to the software without specific
-// prior written approval of the UI.
-//
-// 4. THE UI MAKES NO REPRESENTATIONS ABOUT THE SUITABILITY OF THE
-// SOFTWARE FOR ANY PURPOSE. IT IS PROVIDED "AS IS" WITHOUT EXPRESS
-// OR IMPLIED WARRANTY.
-//
-// 5. The UI shall not be liable for any damages suffered by Licensee from
-// the use of this software.
-//
-// 6. The software was developed under agreements between the UI and the
-// Federal Government which entitle the Government to certain rights.
-//
-// *************************************************************************
-//
-// Developed by: The Pablo Research Group
-// University of Illinois at Urbana-Champaign
-// Department of Computer Science
-// 1304 W. Springfield Avenue
-// Urbana, IL 61801
-//
-// http://www-pablo.cs.uiuc.edu
-//
-// Send comments to: pablo-feedback@guitar.cs.uiuc.edu
-//
-// Copyright (c) 1987-1998
-// The University of Illinois Board of Trustees.
-// All Rights Reserved.
-//
-// PABLO is a registered trademark of
-// The Board of Trustees of the University of Illinois
-// registered in the U.S. Patent and Trademark Office.
-//
-// Project Manager and Principal Investigator:
-// Daniel A. Reed (reed@cs.uiuc.edu)
-//
-// Funded in part by the Defense Advanced Research Projects Agency under
-// DARPA contracts DABT63-94-C0049 (SIO Initiative), F30602-96-C-0161,
-// and DABT63-96-C-0027 by the National Science Foundation under the PACI
-// program and grants NSF CDA 94-01124 and ASC 97-20202, and by the
-// Department of Energy under contracts DOE B-341494, W-7405-ENG-48, and
-// 1-B-333164.
-//======================================================================*/
-#ifndef HDFTRACE_H
-#define HDFTRACE_H
-/************************************************************************/
-/* A shared char * pointer (defined in HDF_Descriptors.c) and Macro */
-/* definitions */
-/************************************************************************/
-extern char *hdfRecordPointer;
-/************************************************************************/
-/* The following are used in tagging HDF packets. Avoid using FAMILY */
-/* tags in the range 0100000 to 0200000 */
-/************************************************************************/
-#define HDF_FAMILY 0100000
-#define HDF_SUMMARY_FAMILY 0140000
-/************************************************************************/
-/* Number of fields in the packets. */
-/************************************************************************/
-#define NUM_FIELDS 17
-/*
- * "WRITE_HDF_ATTR" macro to output an attribute pair.
- */
-#ifndef WRITE_HDF_ATTR
-#define WRITE_HDF_ATTR( attrKey, attrValue ) \
- sddfWriteString( &hdfRecordPointer, attrKey ); \
- sddfWriteString( &hdfRecordPointer, attrValue );
-#endif /* WRITE_HDF_ATTR */
-
-/*
- * "WRITE_HDF_FIELD" macro to output a field with a single attribute pair.
- */
-#ifndef WRITE_HDF_FIELD
-#define WRITE_HDF_FIELD( name, attrKey, attrValue, type, dimension ) \
- sddfWriteString( &hdfRecordPointer, name ); \
- sddfWriteInteger( &hdfRecordPointer, 1 ); \
- sddfWriteString( &hdfRecordPointer, attrKey ); \
- sddfWriteString( &hdfRecordPointer, attrValue ); \
- sddfWriteInteger( &hdfRecordPointer, type ); \
- sddfWriteInteger( &hdfRecordPointer, dimension );
-#endif /* WRITE_HDF_FIELD */
-
-/*
- * "WRITE_HDF_FIELD2" to output a field with two attribute pairs.
- */
-#ifndef WRITE_HDF_FIELD2
-#define WRITE_HDF_FIELD2( name, aKey1, aValue1, aKey2, aValue2, type, dimension ) \
- sddfWriteString( &hdfRecordPointer, name ); \
- sddfWriteInteger( &hdfRecordPointer, 2 ); \
- sddfWriteString( &hdfRecordPointer, aKey1 ); \
- sddfWriteString( &hdfRecordPointer, aValue1 ); \
- sddfWriteString( &hdfRecordPointer, aKey2 ); \
- sddfWriteString( &hdfRecordPointer, aValue2 ); \
- sddfWriteInteger( &hdfRecordPointer, type ); \
- sddfWriteInteger( &hdfRecordPointer, dimension );
-#endif /* WRITE_HDF_FIELD2*/
-
-#define FAMILY_NAME 0260 /* Data Set Name Record */
-#define FAMILY_MISC 0270
-#define FAMILY_HDFPROCNAME 0300
-
-#define mpiOpenBeginID 900800
-#define mpiOpenEndID 900801
-
-#define mpiCloseBeginID 900802
-#define mpiCloseEndID 900803
-
-#define mpiSetSizeBeginID 900806
-#define mpiSetSizeEndID 900807
-
-#define mpiGetSizeBeginID 900810
-#define mpiGetSizeEndID 900811
-
-#define mpiSetViewBeginID 900816
-#define mpiSetViewEndID 900817
-
-#define mpiGetViewBeginID 900818
-#define mpiGetViewEndID 900819
-
-#define mpiReadAtBeginID 900820
-#define mpiReadAtEndID 900821
-
-#define mpiReadAtAllBeginID 900822
-#define mpiReadAtAllEndID 900823
-
-#define mpiWriteAtBeginID 900824
-#define mpiWriteAtEndID 900825
-
-#define mpiWriteAtAllBeginID 900826
-#define mpiWriteAtAllEndID 900827
-
-#define mpiSyncBeginID 900856
-#define mpiSyncEndID 900857
-
-typedef struct {
- long numBytes;
- long setID;
- char *setName;
-} HDFsetInfo ;
-
-#endif /* HDFTRACE_H */
diff --git a/pablo/HDFmpioProtos.h b/pablo/HDFmpioProtos.h
deleted file mode 100644
index 886983d..0000000
--- a/pablo/HDFmpioProtos.h
+++ /dev/null
@@ -1,77 +0,0 @@
-#ifdef PCF_BUILD
-#define MPI_File_open PCF_MPI_File_open
-#define MPI_File_close PCF_MPI_File_close
-#define MPI_File_set_size PCF_MPI_File_set_size
-#define MPI_File_get_size PCF_MPI_File_get_size
-#define MPI_File_set_view PCF_MPI_File_set_view
-#define MPI_File_get_view PCF_MPI_File_get_view
-#define MPI_File_read_at PCF_MPI_File_read_at
-#define MPI_File_read_at_all PCF_MPI_File_read_at_all
-#define MPI_File_write_at PCF_MPI_File_write_at
-#define MPI_File_write_at_all PCF_MPI_File_write_at_all
-#define MPI_File_sync PCF_MPI_File_sync
-
-int PCF_MPI_File_open( MPI_Comm comm, char *filename, int amode,
- MPI_Info info, MPI_File *fh );
-int PCF_MPI_File_close( MPI_File *fh );
-int PCF_MPI_File_delete( char *filename, MPI_Info info );
-int PCF_MPI_File_set_size( MPI_File fh, MPI_Offset size );
-int PCF_MPI_File_get_size( MPI_File fh, MPI_Offset *size );
-int PCF_MPI_File_set_view( MPI_File fh, MPI_Offset disp, MPI_Datatype etype,
- MPI_Datatype filetype, char *datarep,
- MPI_Info info );
-int PCF_MPI_File_get_view( MPI_File fh, MPI_Offset *disp,
- MPI_Datatype *etype, MPI_Datatype *filetype,
- char *datarep );
-int PCF_MPI_File_read_at( MPI_File fh, MPI_Offset offset, void *buf,
- int count, MPI_Datatype datatype,
- MPI_Status *status );
-int PCF_MPI_File_read_at_all( MPI_File fh, MPI_Offset offset, void *buf,
- int count, MPI_Datatype datatype,
- MPI_Status *status );
-int PCF_MPI_File_write_at( MPI_File fh, MPI_Offset offset, void *buf,
- int count, MPI_Datatype datatype,
- MPI_Status *status );
-int PCF_MPI_File_write_at_all( MPI_File fh, MPI_Offset offset, void *buf,
- int count, MPI_Datatype datatype,
- MPI_Status *status );
-int PCF_MPI_File_sync( MPI_File fh );
-#else
-#define MPI_File_open HDF_MPI_File_open
-#define MPI_File_close HDF_MPI_File_close
-#define MPI_File_set_size HDF_MPI_File_set_size
-#define MPI_File_get_size HDF_MPI_File_get_size
-#define MPI_File_set_view HDF_MPI_File_set_view
-#define MPI_File_get_view HDF_MPI_File_get_view
-#define MPI_File_read_at HDF_MPI_File_read_at
-#define MPI_File_read_at_all HDF_MPI_File_read_at_all
-#define MPI_File_write_at HDF_MPI_File_write_at
-#define MPI_File_write_at_all HDF_MPI_File_write_at_all
-#define MPI_File_sync HDF_MPI_File_sync
-
-int HDF_MPI_File_open( MPI_Comm comm, char *filename, int amode,
- MPI_Info info, MPI_File *fh );
-int HDF_MPI_File_close( MPI_File *fh );
-int HDF_MPI_File_delete( char *filename, MPI_Info info );
-int HDF_MPI_File_set_size( MPI_File fh, MPI_Offset size );
-int HDF_MPI_File_get_size( MPI_File fh, MPI_Offset *size );
-int HDF_MPI_File_set_view( MPI_File fh, MPI_Offset disp, MPI_Datatype etype,
- MPI_Datatype filetype, char *datarep,
- MPI_Info info );
-int HDF_MPI_File_get_view( MPI_File fh, MPI_Offset *disp,
- MPI_Datatype *etype, MPI_Datatype *filetype,
- char *datarep );
-int HDF_MPI_File_read_at( MPI_File fh, MPI_Offset offset, void *buf,
- int count, MPI_Datatype datatype,
- MPI_Status *status );
-int HDF_MPI_File_read_at_all( MPI_File fh, MPI_Offset offset, void *buf,
- int count, MPI_Datatype datatype,
- MPI_Status *status );
-int HDF_MPI_File_write_at( MPI_File fh, MPI_Offset offset, void *buf,
- int count, MPI_Datatype datatype,
- MPI_Status *status );
-int HDF_MPI_File_write_at_all( MPI_File fh, MPI_Offset offset, void *buf,
- int count, MPI_Datatype datatype,
- MPI_Status *status );
-int HDF_MPI_File_sync( MPI_File fh );
-#endif /* PCF_BUILD */
diff --git a/pablo/HDFrecord_RT.h b/pablo/HDFrecord_RT.h
deleted file mode 100644
index 3fb3f31..0000000
--- a/pablo/HDFrecord_RT.h
+++ /dev/null
@@ -1,215 +0,0 @@
-/*
- * This file is part of the Pablo Performance Analysis Environment
- *
- * (R)
- * The Pablo Performance Analysis Environment software is NOT in
- * the public domain. However, it is freely available without fee for
- * education, research, and non-profit purposes. By obtaining copies
- * of this and other files that comprise the Pablo Performance Analysis
- * Environment, you, the Licensee, agree to abide by the following
- * conditions and understandings with respect to the copyrighted software:
- *
- * 1. The software is copyrighted in the name of the Board of Trustees
- * of the University of Illinois (UI), and ownership of the software
- * remains with the UI.
- *
- * 2. Permission to use, copy, and modify this software and its documentation
- * for education, research, and non-profit purposes is hereby granted
- * to Licensee, provided that the copyright notice, the original author's
- * names and unit identification, and this permission notice appear on
- * all such copies, and that no charge be made for such copies. Any
- * entity desiring permission to incorporate this software into commercial
- * products should contact:
- *
- * Professor Daniel A. Reed reed@cs.uiuc.edu
- * University of Illinois
- * Department of Computer Science
- * 2413 Digital Computer Laboratory
- * 1304 West Springfield Avenue
- * Urbana, Illinois 61801
- * USA
- *
- * 3. Licensee may not use the name, logo, or any other symbol of the UI
- * nor the names of any of its employees nor any adaptation thereof in
- * advertizing or publicity pertaining to the software without specific
- * prior written approval of the UI.
- *
- * 4. THE UI MAKES NO REPRESENTATIONS ABOUT THE SUITABILITY OF THE
- * SOFTWARE FOR ANY PURPOSE. IT IS PROVIDED "AS IS" WITHOUT EXPRESS
- * OR IMPLIED WARRANTY.
- *
- * 5. The UI shall not be liable for any damages suffered by Licensee from
- * the use of this software.
- *
- * 6. The software was developed under agreements between the UI and the
- * Federal Government which entitle the Government to certain rights.
- *
- **************************************************************************
- *
- * Developed by: The Pablo Research Group
- * University of Illinois at Urbana-Champaign
- * Department of Computer Science
- * 1304 W. Springfield Avenue
- * Urbana, IL 61801
- *
- * http://www-pablo.cs.uiuc.edu
- *
- * Send comments to: pablo-feedback@guitar.cs.uiuc.edu
- *
- * Copyright (c) 1987-1996
- * The University of Illinois Board of Trustees.
- * All Rights Reserved.
- *
- * PABLO is a registered trademark of
- * The Board of Trustees of the University of Illinois
- * registered in the U.S. Patent and Trademark Office.
- *
- * Author: Dan Wells (dwells@cs.uiuc.edu)
- *
- * Project Manager and Principal Investigator:
- * Daniel A. Reed (reed@cs.uiuc.edu)
- *
- * Funded in part by National Science Foundation grants NSF CCR87-06653
- * and NSF CDA87-22836 (Tapestry), DARPA contracts DABT63-91-K-0004,
- * DABT63-93-C-0040, DABT63-94-C-0049 (SIO), and F30602-96-C-0161, NASA
- * contracts NAG-1-613 (ICLASS), USRA 5555-22, and NGT-51023, and a
- * collaborative research agreement with the Intel Supercomputer
- * Systems Division
- */
-/*
- * HDFrecord.h: Class to represent HDF records.
- *
- * $Header$
- */
-
-#ifndef HDFRECORD_RT_H
-#define HDFRECORD_RT_H
-#ifndef NULL
-#define NULL 0
-#endif
-
-#include <string.h>
-#include <stdlib.h>
-#include <limits.h>
-#include "ProcIDs.h"
-
-#ifndef min
-#define min( x , y ) ( x <= y ? x : y )
-#endif
-#ifndef max
-#define max( x , y ) ( x >= y ? x : y )
-#endif
-/*======================================================================*
-// Enumeration of time fields in an HDFrec_t below *
-//======================================================================*/
-enum TimeFields { HDF_,
- MPI,
- Malloc,
- AllIO,
- Open,
- Close,
- Read,
- Write,
- Aread,
- Awrite,
- Seek,
- Wait,
- Misc,
- MPIOread,
- MPIOreadAll,
- MPIOwrite,
- MPIOwriteAll,
- MPIOiRead,
- MPIOiWrite,
- MPIOother,
- nTallyFields,
- MPIOreadTrans,
- MPIOreadAllTrans,
- MPIOwriteTrans,
- MPIOwriteAllTrans
- };
-/*======================================================================*
-// Enumeration of byte fields in an HDFrec_t below *
-//======================================================================*/
-enum ByteFields{ MallocBytes,
- ReadBytes,
- WriteBytes,
- AreadBytes,
- AwriteBytes,
- MPIOreadBytesReq,
- MPIOreadBytesTrans,
- MPIOwriteBytesReq,
- MPIOwriteBytesTrans,
- MPIOreadAllBytesReq,
- MPIOreadAllBytesTrans,
- MPIOwriteAllBytesReq,
- MPIOwriteAllBytesTrans,
- MPIOiReadBytesReq,
- MPIOiWriteBytesReq,
- nByteFields,
- nHistFields = AwriteBytes+1 };
-/*======================================================================*
-// Definition of first and last IO event. *
-//======================================================================*/
-#define FirstIO Open
-#define LastIO Misc
-#define nBkts 4
-#define ONEK 1024
-int BktLim[] = { 1, 4*ONEK, 64*ONEK, 256*ONEK, INT_MAX } ;
-/*======================================================================*
-// Definition of structure used to account activity in an HDF call *
-//======================================================================*/
-typedef struct {
- int nCalls; /* number of proc calls */
- CLOCK lastCall; /* time of last call */
- CLOCK incDur; /* inclusive duration */
- CLOCK excDur; /* exclusive duration */
- CLOCK times[nTallyFields]; /* Tally op/calls times */
- int counts[nTallyFields]; /* Tally op/calls counts */
- int bytes[nByteFields]; /* Tally bytes transferred */
- int Hists[nHistFields][nBkts]; /* Historgrams */
- long hdfID; /* data set ID */
- long xRef; /* data set cross reference */
-} HDFrec_t;
-/*======================================================================*
-// Node used to maintain linked lists of HDF procedure activity. *
-//======================================================================*/
-typedef struct HDFnode {
- CLOCK lastIOtime; /* last IO time stamp */
- HDFrec_t record; /* data */
- struct HDFnode *ptr; /* link pointer */
- int eventID; /* event ID */
-} HDFnode_t;
-/*======================================================================*
-// Structure used to produce SDDF packets for Named identifiers. *
-//======================================================================*/
-typedef struct {
- int packetLength; /* bytes in packet */
- int packetType; /* == PKT_DATA */
- int packetTag; /* == FAMILY_<name> */
- int fileType; /* Type of data set */
- int fileID; /* File ID */
- int nameLen; /* length of file */
-} HDFNamePacket_t;
-/*======================================================================*
-// Node used to form linked lists to track named identifiers. *
-//======================================================================*/
-typedef struct fileRec {
- struct fileRec *ptr;
- long hdfID;
- long PabloID;
- char *fileName;
-} fileRec_t;
-/*=======================================================================
-// Utility programs to determine field index for a given eventID *
-//=====================================================================*/
-int getHDFFieldIndex( int eventID );
-int getHDFByteFieldIndex( int eventID );
-
-/*
- * Define flags to distinguish misc i/o begin from misc i/o end
- */
-#define MISC_BEGIN 0
-#define MISC_END 1
-
-#endif /* HDFRECORD_RT_H */
diff --git a/pablo/Makefile.in b/pablo/Makefile.in
deleted file mode 100644
index d0f82dc..0000000
--- a/pablo/Makefile.in
+++ /dev/null
@@ -1,314 +0,0 @@
-## HDF5 Library Makefile(.in)
-##
-##
-## Copyright by the Board of Trustees of the University of Illinois.
-## All rights reserved.
-##
-## This file is part of HDF5. The full HDF5 copyright notice, including
-## terms governing use, modification, and redistribution, is contained in
-## the files COPYING and Copyright.html. COPYING can be found at the root
-## of the source code distribution tree; Copyright.html can be found at the
-## root level of an installed copy of the electronic HDF5 document set and
-## is linked from the top-level documents page. It can also be found at
-## http://hdf.ncsa.uiuc.edu/HDF5/doc/Copyright.html. If you do not have
-## access to either file, you may request a copy from hdfhelp@ncsa.uiuc.edu.
-##
-top_srcdir=@top_srcdir@
-top_builddir=..
-srcdir=@srcdir@
-
-@COMMENCE@
-
-TRACE=$(PERL) $(top_srcdir)/bin/trace
-.SUFFIXES: .c .o .lo .x
-
-###############################################################################
-## MODIFICATONS FOR CREATING THE PABLO INSTRUMENTED LIBRARY libhdf5-inst.a
-## For Pablo instrumenation of parallel code, remove the # from in front of
-## PABLO_MPIO_FLAGS.
-###############################################################################
-PARALLEL_PABLO=@PARALLEL_PABLO@
-
-PABLO_MPIO_FLAGS=${PARALLEL_PABLO:yes=-DH5_HAVE_PARALLEL -DH5_HAVE_MPIOTRACE}
-PABLO_INC=-I$(top_srcdir)/src -I$(top_srcdir)/pablo -I$(top_builddir)/src -I.
-PABLO_DEFS=-DH5_HAVE_PABLO -DH5_DEBUG_API -DNDEBUG -D$(PABLO_BLD)_BUILD
-
-PABLO_FLAGS=$(PABLO_DEFS) $(PABLO_MPIO_FLAGS) $(PABLO_INC)
-
-CPPFLAGS=$(PABLO_FLAGS) @CPPFLAGS@
-
-## This is our main target:
-LIB=libhdf5-inst.a
-
-SRCDIRS=./. ../src/.
-
-# Took out the GNU'isms for the SRCFILES and LIB_SRC variables.
-#
-# This may cause problems in two ways: any changes to the SRCDIRS
-# variable should be make to the SRCFILES macro also and the LIB_SRC
-# variable now has directory paths included in it (which may cause
-# problems somewhere). - QAK
-#
-LIB_SRC=H5.c H5A.c H5AC.c H5B.c H5D.c H5Dio.c H5E.c H5F.c H5FD.c \
- H5FDcore.c H5FDfamily.c H5FDgass.c H5FDlog.c \
- H5FDmpio.c H5FDmpiposix.c H5FDmulti.c H5FDsec2.c H5FDsrb.c \
- H5FDstdio.c H5FDstream.c H5FL.c H5FO.c \
- H5FS.c H5Fcompact.c H5Fcontig.c H5Fistore.c H5Fseq.c \
- H5G.c H5Gent.c H5Gnode.c H5Gstab.c H5HG.c H5HL.c H5HP.c H5I.c \
- H5MF.c H5MM.c H5O.c H5Oattr.c H5Obogus.c H5Ocont.c H5Odtype.c \
- H5Oefl.c H5Ofill.c H5Olayout.c H5Omtime.c H5Oname.c H5Onull.c \
- H5Opline.c H5Osdspace.c H5Oshared.c H5Ostab.c H5P.c H5Pdcpl.c \
- H5Pdxpl.c H5Pfapl.c H5Pfcpl.c H5Ptest.c H5R.c H5RS.c H5S.c H5ST.c \
- H5Sall.c H5Shyper.c H5Smpio.c H5Snone.c H5Spoint.c H5Sselect.c \
- H5Stest.c H5T.c H5TB.c H5TS.c H5Tarray.c H5Tbit.c H5Tcommit.c \
- H5Tcompound.c H5Tconv.c H5Tcset.c H5Tenum.c H5Tfields.c H5Tfixed.c \
- H5Tfloat.c H5Tinit.c H5Tnative.c H5Toffset.c H5Topaque.c H5Torder.c \
- H5Tpad.c H5Tprecis.c H5Tstrpad.c H5Tvlen.c H5V.c H5Z.c H5Zdeflate.c \
- H5Zfletcher32.c H5Zshuffle.c H5Zszip.c H5detect.c
-
-PABLO_OBJ=PabloHDF.o PabloHDF_RT.o PabloHDF_SDDF.o PabloHDF_MPIO.o
-
-LIB_XOBJ=$(LIB_SRC:.c=.x)
-LIB_COBJ=$(LIB_XOBJ:.x=.o)
-LIB_OBJ=$(PABLO_OBJ) $(LIB_COBJ)
-
-.c.x:
- if test "$*" != "H5Tinit"; then \
- $(CC) $(CFLAGS) $(CPPFLAGS) -c $(top_srcdir)/src/$*.c -o $*.o; \
- else \
- $(CC) $(CFLAGS) $(CPPFLAGS) -c $(top_builddir)/src/$*.c -o $*.o; \
- fi;
- cp $*.o $@
-
-# 'vpath' directive is only supported in gmake, take out - QAK
-#vpath %.c $(shell echo $(SRCDIRS) | sed 's/ /:/g')
-
-## Pablo header files (to be installed)...
-PABLO_HDR=HDFentryNames.h HDFidList.h ProcIDs.h HDFTrace.h ProcTrace.h \
- ProcTrace.inc
-
-##------------------------------------------------------------ -*- makefile -*-
-## The following section of this makefile comes from the
-## `./config/conclude' file which was generated with config.status
-## from `./config/conclude.in'.
-##-----------------------------------------------------------------------------
-
-## This is the target for the library described in the main body of the
-## makefile.
-##
-lib: $(LIB)
-$(LIB): $(PABLO_OBJ) $(LIB_XOBJ)
- $(AR) -rc $@ $(LIB_OBJ)
- $(RANLIB) $@
-##
-## Dummy this out so that there is no redundant make of the library
-##
-progs:
-
-## Build a tags file in this directory.
-TAGS: $(LIB_SRC)
- $(RM) $@
- -etags $(LIB_SRC)
-
-##
-## Dummy this out so that there is no redundant make of the library
-##
-tests:
-
-## Install the library, the public header files, and programs.
-install: $(LIB)
- @test -d $(libdir) || mkdir $(libdir)
- @for f in X $(LIB); do \
- if test $$f != X; then \
- (set -x; $(INSTALL_DATA) $$f $(libdir)/. || exit 1); \
- fi; \
- done
- @test -d $(includedir) || mkdir $(includedir)
- @for f in X $(PABLO_HDR); do \
- if test $$f != X; then \
- (set -x; $(INSTALL_DATA) $$f $(includedir)/. || exit 1); \
- fi \
- done
-
-## Removes those things that `make install' (would have) installed.
-uninstall:
- @if test "X$(LIB)" != X; then \
- set -x; cd $(libdir) && $(RM) $(LIB); \
- fi
-
-## Removes temporary files without removing the final target files. That is,
-## remove things like object files but not libraries or executables.
-##
-mostlyclean:
- $(RM) $(LIB_OBJ) $(LIB_XOBJ) $(TEST_OBJ) $(PROG_OBJ) $(MOSTLYCLEAN)
-
-## Like `mostlyclean' except it also removes the final targets: things like
-## libraries and executables. This target doesn't remove any file that
-## is part of the HDF5 distribution.
-##
-clean: mostlyclean
- $(RM) $(LIB) $(TESTS) $(PROGS) $(CLEAN) $(PABLO_CLEAN) H*.c
-
-## Like `clean' except it also removes files that were created by running
-## configure. If you've unpacked the source and built HDF5 without creating
-## any other files, then `make distclean' will leave only the files that were
-## in the distribution.
-##
-distclean: clean
- $(RM) .depend TAGS *~ core *.core *.bak *.old *.new $(DISTCLEAN)
- @if test -f $(top_srcdir)/src/Makefile.in; then \
- (set -x; $(RM) Makefile); \
- fi
-
-## Like `distclean' except it deletes all files that can be regenerated from
-## the makefile, including those generated from autoheader and autoconf.
-##
-maintainer-clean: distclean
- $(RM) *~ core core.* *.core *.bak *.contrib gmon.out
-
-.c.lo:
- @$(LT_COMPILE) $(CFLAGS) $(CPPFLAGS) -c $(top_srcdir)/src/$*.c $<
-
-.PHONY: all progs test _test check dep depend
-
-PABLO_INCLUDES=HDFentryNames.h HDFidList.h ProcIDs.h HDFTrace.h ProcTrace.h \
- ProcTrace.inc
-
-PABLO_CLEAN=HDFentryNames.h HDFidList.h ProcMasks.h HDFentries.txt \
- ProcTrace.inc
-
-HDFentries.txt: $(top_srcdir)/src/*.c
- grep "FUNC_ENTER[_INITNOAPICLEARFS ]*(" $(top_srcdir)/src/*.[ch] | \
- sed "s/.*FUNC_ENTER[_INITNOAPICLEARFS ]*( *//;s/[,)].*//" | sort -u > $@
-
-HDFentryNames.h: HDFentries.txt
- sed "s/.*/\"&\",/" $? > $@
-
-HDFidList.h: HDFentries.txt
- sed "s/.*/ID_&,/" $? > $@
- echo ID_ALLHDF, >> $@
- grep "#define[ ]*PABLO_MASK" $(top_srcdir)/src/*.c | \
- sed "s/.*H5/ID_H5/;s/mask.*/c,/" | sort -u >> $@
-
-ProcMasks.h: $(top_srcdir)/src/*.c
- grep "#define[ ]*PABLO_MASK" $(top_srcdir)/src/*.c | \
- sed "s/.*[ ]H5/H5/;s/_mask.*//;s/.*/#define &_mask ID_&_c/" >$@
-
-ProcIDs.h: HDFidList.h ProcMasks.h
-
-ProcTrace.inc: HDFidList.h
- sed "=" $? | sed -f $(top_srcdir)/pablo/PabloSedscr > $@
-
-PabloHDF.o: PabloHDF.c $(PABLO_INCLUDES)
- $(CC) -g $(CFLAGS) $(CPPFLAGS) $(PABLO_FLAGS) -c $<
-
-PabloHDF_RT.o: PabloHDF_RT.c $(PABLO_INCLUDES)
- $(CC) $(CFLAGS) $(CPPFLAGS) $(PABLO_FLAGS) -c $<
-
-PabloHDF_SDDF.o: PabloHDF_SDDF.c $(PABLO_INCLUDES)
- $(CC) $(CFLAGS) $(CPPFLAGS) $(PABLO_FLAGS) -c $<
-
-PabloHDF_MPIO.o: PabloHDF_MPIO.c $(PABLO_INCLUDES)
- $(CC) $(CFLAGS) $(CPPFLAGS) $(PABLO_FLAGS) -c $<
-
-PabloHDFff.o: PabloHDFff.f $(PABLO_INCLUDES)
- $(F77) $(FFLAGS) -O -c PabloHDFff.f
-
-H5.c: $(top_srcdir)/src/H5.c
-H5A.c: $(top_srcdir)/src/H5A.c
-H5AC.c: $(top_srcdir)/src/H5AC.c
-H5B.c: $(top_srcdir)/src/H5B.c
-H5D.c: $(top_srcdir)/src/H5D.c
-H5Dio.c: $(top_srcdir)/src/H5Dio.c
-H5E.c: $(top_srcdir)/src/H5E.c
-H5F.c: $(top_srcdir)/src/H5F.c
-H5FD.c: $(top_srcdir)/src/H5FD.c
-H5FDcore.c: $(top_srcdir)/src/H5FDcore.c
-H5FDfamily.c: $(top_srcdir)/src/H5FDfamily.c
-H5FDgass.c: $(top_srcdir)/src/H5FDgass.c
-H5FDlog.c: $(top_srcdir)/src/H5FDlog.c
-H5FDmpio.c: $(top_srcdir)/src/H5FDmpio.c
-H5FDmpiposix.c: $(top_srcdir)/src/H5FDmpiposix.c
-H5FDmulti.c: $(top_srcdir)/src/H5FDmulti.c
-H5FDsec2.c: $(top_srcdir)/src/H5FDsec2.c
-H5FDsrb.c: $(top_srcdir)/src/H5FDsrb.c
-H5FDstdio.c: $(top_srcdir)/src/H5FDstdio.c
-H5FDstream.c: $(top_srcdir)/src/H5FDstream.c
-H5FL.c: $(top_srcdir)/src/H5FL.c
-H5FO.c: $(top_srcdir)/src/H5FO.c
-H5FS.c: $(top_srcdir)/src/H5FS.c
-H5Fcompact.c: $(top_srcdir)/src/H5Fcompact.c
-H5Fcontig.c: $(top_srcdir)/src/H5Fcontig.c
-H5Fistore.c: $(top_srcdir)/src/H5Fistore.c
-H5Fseq.c: $(top_srcdir)/src/H5Fseq.c
-H5G.c: $(top_srcdir)/src/H5G.c
-H5Gent.c: $(top_srcdir)/src/H5Gent.c
-H5Gnode.c: $(top_srcdir)/src/H5Gnode.c
-H5Gstab.c: $(top_srcdir)/src/H5Gstab.c
-H5HG.c: $(top_srcdir)/src/H5HG.c
-H5HL.c: $(top_srcdir)/src/H5HL.c
-H5HP.c: $(top_srcdir)/src/H5HP.c
-H5I.c: $(top_srcdir)/src/H5I.c
-H5MF.c: $(top_srcdir)/src/H5MF.c
-H5MM.c: $(top_srcdir)/src/H5MM.c
-H5O.c: $(top_srcdir)/src/H5O.c
-H5Oattr.c: $(top_srcdir)/src/H5Oattr.c
-H5Obogus.c: $(top_srcdir)/src/H5Obogus.c
-H5Ocont.c: $(top_srcdir)/src/H5Ocont.c
-H5Odtype.c: $(top_srcdir)/src/H5Odtype.c
-H5Oefl.c: $(top_srcdir)/src/H5Oefl.c
-H5Ofill.c: $(top_srcdir)/src/H5Ofill.c
-H5Olayout.c: $(top_srcdir)/src/H5Olayout.c
-H5Omtime.c: $(top_srcdir)/src/H5Omtime.c
-H5Oname.c: $(top_srcdir)/src/H5Oname.c
-H5Onull.c: $(top_srcdir)/src/H5Onull.c
-H5Opline.c: $(top_srcdir)/src/H5Opline.c
-H5Osdspace.c: $(top_srcdir)/src/H5Osdspace.c
-H5Oshared.c: $(top_srcdir)/src/H5Oshared.c
-H5Ostab.c: $(top_srcdir)/src/H5Ostab.c
-H5P.c: $(top_srcdir)/src/H5P.c
-H5Pdcpl.c: $(top_srcdir)/src/H5Pdcpl.c
-H5Pdxpl.c: $(top_srcdir)/src/H5Pdxpl.c
-H5Pfapl.c: $(top_srcdir)/src/H5Pfapl.c
-H5Pfcpl.c: $(top_srcdir)/src/H5Pfcpl.c
-H5Ptest.c: $(top_srcdir)/src/H5Ptest.c
-H5R.c: $(top_srcdir)/src/H5R.c
-H5RS.c: $(top_srcdir)/src/H5RS.c
-H5S.c: $(top_srcdir)/src/H5S.c
-H5ST.c: $(top_srcdir)/src/H5ST.c
-H5Sall.c: $(top_srcdir)/src/H5Sall.c
-H5Shyper.c: $(top_srcdir)/src/H5Shyper.c
-H5Smpio.c: $(top_srcdir)/src/H5Smpio.c
-H5Snone.c: $(top_srcdir)/src/H5Snone.c
-H5Spoint.c: $(top_srcdir)/src/H5Spoint.c
-H5Sselect.c: $(top_srcdir)/src/H5Sselect.c
-H5Stest.c: $(top_srcdir)/src/H5Stest.c
-H5T.c: $(top_srcdir)/src/H5T.c
-H5TB.c: $(top_srcdir)/src/H5TB.c
-H5TS.c: $(top_srcdir)/src/H5TS.c
-H5Tarray.c: $(top_srcdir)/src/H5Tarray.c
-H5Tbit.c: $(top_srcdir)/src/H5Tbit.c
-H5Tcommit.c: $(top_srcdir)/src/H5Tcommit.c
-H5Tcompound.c: $(top_srcdir)/src/H5Tcompound.c
-H5Tconv.c: $(top_srcdir)/src/H5Tconv.c
-H5Tcset.c: $(top_srcdir)/src/H5Tcset.c
-H5Tenum.c: $(top_srcdir)/src/H5Tenum.c
-H5Tfields.c: $(top_srcdir)/src/H5Tfields.c
-H5Tfixed.c: $(top_srcdir)/src/H5Tfixed.c
-H5Tfloat.c: $(top_srcdir)/src/H5Tfloat.c
-H5Tinit.c: $(top_srcdir)/src/H5Tinit.c
-H5Tnative.c: $(top_srcdir)/src/H5Tnative.c
-H5Toffset.c: $(top_srcdir)/src/H5Toffset.c
-H5Topaque.c: $(top_srcdir)/src/H5Topaque.c
-H5Torder.c: $(top_srcdir)/src/H5Torder.c
-H5Tpad.c: $(top_srcdir)/src/H5Tpad.c
-H5Tprecis.c: $(top_srcdir)/src/H5Tprecis.c
-H5Tstrpad.c: $(top_srcdir)/src/H5Tstrpad.c
-H5Tvlen.c: $(top_srcdir)/src/H5Tvlen.c
-H5V.c: $(top_srcdir)/src/H5V.c
-H5Z.c: $(top_srcdir)/src/H5Z.c
-H5Zdeflate.c: $(top_srcdir)/src/H5Zdeflate.c
-H5Zfletcher32.c: $(top_srcdir)/src/H5Zfletcher32.c
-H5Zshuffle.c: $(top_srcdir)/src/H5Zshuffle.c
-H5Zszip.c: $(top_srcdir)/src/H5Zszip.c
-H5detect.c: $(top_srcdir)/src/H5detect.c
diff --git a/pablo/PabloHDF.c b/pablo/PabloHDF.c
deleted file mode 100644
index f756381..0000000
--- a/pablo/PabloHDF.c
+++ /dev/null
@@ -1,1416 +0,0 @@
-/* This file is part of the Pablo Performance Analysis Environment
-//
-// (R)
-// The Pablo Performance Analysis Environment software is NOT in
-// the public domain. However, it is freely available without fee for
-// education, research, and non-profit purposes. By obtaining copies
-// of this and other files that comprise the Pablo Performance Analysis
-// Environment, you, the Licensee, agree to abide by the following
-// conditions and understandings with respect to the copyrighted software:
-//
-// 1. The software is copyrighted in the name of the Board of Trustees
-// of the University of Illinois (UI), and ownership of the software
-// remains with the UI.
-//
-// 2. Permission to use, copy, and modify this software and its documentation
-// for education, research, and non-profit purposes is hereby granted
-// to Licensee, provided that the copyright notice, the original author's
-// names and unit identification, and this permission notice appear on
-// all such copies, and that no charge be made for such copies. Any
-// entity desiring permission to incorporate this software into commercial
-// products should contact:
-//
-// Professor Daniel A. Reed reed@cs.uiuc.edu
-// University of Illinois
-// Department of Computer Science
-// 2413 Digital Computer Laboratory
-// 1304 West Springfield Avenue
-// Urbana, Illinois 61801
-// USA
-//
-// 3. Licensee may not use the name, logo, or any other symbol of the UI
-// nor the names of any of its employees nor any adaptation thereof in
-// advertizing or publicity pertaining to the software without specific
-// prior written approval of the UI.
-//
-// 4. THE UI MAKES NO REPRESENTATIONS ABOUT THE SUITABILITY OF THE
-// SOFTWARE FOR ANY PURPOSE. IT IS PROVIDED "AS IS" WITHOUT EXPRESS
-// OR IMPLIED WARRANTY.
-//
-// 5. The UI shall not be liable for any damages suffered by Licensee from
-// the use of this software.
-//
-// 6. The software was developed under agreements between the UI and the
-// Federal Government which entitle the Government to certain rights.
-//
-// *************************************************************************
-//
-// Developed by: The Pablo Research Group
-// University of Illinois at Urbana-Champaign
-// Department of Computer Science
-// 1304 W. Springfield Avenue
-// Urbana, IL 61801
-//
-// http://www-pablo.cs.uiuc.edu
-//
-// Send comments to: pablo-feedback@guitar.cs.uiuc.edu
-//
-// Copyright (c) 1987-1998
-// The University of Illinois Board of Trustees.
-// All Rights Reserved.
-//
-// PABLO is a registered trademark of
-// The Board of Trustees of the University of Illinois
-// registered in the U.S. Patent and Trademark Office.
-//
-// Project Manager and Principal Investigator:
-// Daniel A. Reed (reed@cs.uiuc.edu)
-//
-// Funded in part by the Defense Advanced Research Projects Agency under
-// DARPA contracts DABT63-94-C0049 (SIO Initiative), F30602-96-C-0161,
-// and DABT63-96-C-0027 by the National Science Foundation under the PACI
-// program and grants NSF CDA 94-01124 and ASC 97-20202, and by the
-// Department of Energy under contracts DOE B-341494, W-7405-ENG-48, and
-// 1-B-333164.
-//========================================================================*/
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <fcntl.h>
-#include <stdarg.h>
-#include <limits.h>
-#ifndef fileno
-int fileno ( FILE * );
-#endif
-/* on ipsc/860 don't include this or you'll get multiply defined SEEK_* */
-#ifndef __NX
-#include <unistd.h>
-#endif
-
-
-#define HDFtrace3OPEN__
-int HDFtrace3OPEN( const char *, int, mode_t );
-
-#ifdef TRACELIB_BUILD
-#undef PCF_BUILD
-#endif
-
-#ifndef PCF_BUILD
-#include "SDDFparam.h"
-#include "TraceParam.h"
-
-#include "SystemDepend.h"
-#include "Trace.h"
-
-#include "IO_TraceParams.h"
-#include "IOTrace.h"
-#endif
-
-#include "HDFIOTrace.h"
-
-#ifndef TRUE
-#define TRUE 1
-#endif
-
-#ifndef FALSE
-#define FALSE 0
-#endif
-
-/* mode_t is not defined on the ipsc/860 so we define it here */
-#ifdef __NX
-typedef unsigned int mode_t;
-#endif
-
-#ifdef H5_HAVE_PARALLEL
-#define HAVE_MPIO
-#endif
-
-int OUTPUT_SWITCH = 1;
-int *procTrace;
-extern void preInitIOTrace( void );
-
-#include "ProcIDs.h"
-#include "HDFTrace.h"
-
-#define ID_HDFprocName 9996
-#define ID_malloc 9997
-#define ID_free 9998
-#define ID_timeStamp 9999
-#define DUMMY_HDF 10000
-
-char HDFprocNames[][80] = {
-"noName",
-"noName",
-"noName",
-"noName",
-"noName",
-#include "HDFentryNames.h"
-"HDF_LAST_ENTRY"
-};
-
-void startHDFtraceEvent (int );
-void endHDFtraceEvent (int , int , char *, int );
-void getHDFprocName( int, char[81] );
-
-void setHDFcallLevel( int );
-void resetHDFcallLevel( void );
-int HDFcallLevel;
-int MaxHDFcallLevel = INT_MAX;
-
-#ifdef PCF_BUILD
-#include "PcUIOinterface.h"
-void hdfCaptureInit( const char* name, int procNum, int captureType );
-void hdfCaptureEnd( void );
-void traceHDFentryEvent( int eventID ) ;
-void traceHDFexitEvent( int eventID );
-void basePerformanceInit( const char* name, int procNum );
-void genericBaseInit( int captureType, int procNum );
-void unixIObaseInit( int captureType, int procNum );
-int hdfBaseInit( int captureType,
- int procNum,
- int numHDFentries,
- char HDFprocNames[][80] );
-void timeStamp( void );
-void hdfBaseEnd( void );
-void unixIObaseEnd( void );
-void genericBaseEnd( void );
-void basePerformanceEnd( void );
-/*void* traceMALLOC( size_t bytes );
-FILE* traceFOPEN( const char* fileName, const char* type );
-int traceOPEN( const char *path, int flags, ... ) ;
-int trace3OPEN( const char *path, int flags, mode_t mode ) ;
-int traceCREAT( const char *path, mode_t mode ) ;
-int traceFFLUSH( FILE *stream ) ;
-int traceFCLOSE( FILE *stream ) ;
-int traceCLOSE( int fd ) ;
-ssize_t traceREAD( int fd, void *buf, int nbyte ) ;
-size_t traceFREAD( void *ptr, int size, int nItems, FILE *stream ) ;
-int traceFGETC( FILE *stream ) ;
-char* traceFGETS( char *s, int n, FILE *stream ) ;
-int traceGETW( FILE *stream ) ;
-off_t traceLSEEK( int fd, off_t offset, int whence ) ;
-int traceFSEEK( FILE *stream, off_t offset, int whence ) ;
-int traceFSETPOS( FILE *stream, const fpos_t *position ) ;
-void traceREWIND( FILE *stream ) ;
-ssize_t traceWRITE( int fd, const void *buf, int nbyte ) ;
-size_t traceFWRITE(const void *ptr, int size, int nItems, FILE *stream ) ;
-int traceFPUTC( int c, FILE *stream ) ;
-int traceFPUTS( const char *s, FILE *stream ) ;
-int tracePUTS( const char *s ) ;
-int tracePUTW( int w, FILE *stream ) ;*/
-#else
-void HDFinitTrace_RT ( const char *, int procNum );
-void HDFinitTrace_SDDF ( const char *, int procNum );
-void hinittracex_ ( char [], int *, int*, int[], int *,unsigned * );
-void hdfendtrace_ ( void ) ;
-void HDFendTrace_RT (void );
-void HDFendTrace_SDDF( void );
-void HDFfinalTimeStamp( void );
-void HDFtraceEvent_RT ( int , HDFsetInfo *, unsigned );
-void HDFtraceIOEvent( int , void *, unsigned );
-extern int IOtracingEnabled;
-extern int suppressMPIOtrace;
-char *hdfRecordPointer;
-#endif
-
-/*======================================================================*
-// NAME *
-// HDFinitTrace -- initialize HDF tracing *
-// USAGE *
-// VOID HDFinitTrace( traceFileName, out_sw ) *
-// char *traceFileName; IN: name of the generated trace output *
-// file *
-// int ... IN: indicates which routines to trace *
-// The list is terminated by the *
-// OUTPUT_SWITCH value indicating *
-// whether to do RunTime or Summary *
-// tracing. *
-// RETURNS *
-// None. *
-//======================================================================*/
-/*======================================================================*
-// fortran to C interface. *
-// This is called from hdfinittracef_ *
-//======================================================================*/
-void
-hinittracex_( char *file,
- int *len,
- int *procNum,
- int flags[],
- int *nflags,
- unsigned *out_sw )
-{
- char *traceFileName;
- int i;
- traceFileName = (char *)malloc(*len+1);
- HDFcallLevel = 0;
- for ( i = 0; i < *len; ++i )
- {
- traceFileName[i] = file[i];
- }
- traceFileName[*len] = 0;
- /*===================================================================*
- // Allocate space for trace indicators. *
- //===================================================================*/
- procTrace = ( int * ) malloc( NUM_HDF_IDS*sizeof(int) );
- if ( procTrace == NULL )
- {
- fprintf(stderr,">> Error: Unable to allocate procTrace ");
- fprintf(stderr,"array in program HDFinitTrace. <<<\n");
- fprintf(stderr,">>> Exiting program! <<<\n");
- exit (-1);
- }
- /*===================================================================*
- // Initialize to 0. *
- //===================================================================*/
- for ( i = 0; i < NUM_HDF_IDS; ++i )
- {
- procTrace[i] = 0;
- }
- /*===================================================================*
- // Read in the flags indicating which procedures to trace. *
- // The last parameter passed is an indicator of the type of *
- // tracing to do. This indicator has a value larger than any *
- // of the flags. *
- //===================================================================*/
- for ( i = 0; i < *nflags; ++i )
- {
- procTrace[flags[i]] = 1;
- }
- OUTPUT_SWITCH = *out_sw;
- /*===================================================================*
- // if no flags were passed, the default is to trace all of the *
- // procedures. *
- //===================================================================*/
- if ( *nflags == 0 || procTrace[ID_ALLHDF] )
- {
- for ( i = 0; i < NUM_HDF_IDS; ++i )
- {
- procTrace[i] = 1;
- }
- }
-#ifdef PCF_BUILD
- hdfCaptureInit( traceFileName, *procNum, OUTPUT_SWITCH );
-#else
- suppressMPIOtrace = TRUE;
- if ( OUTPUT_SWITCH == RUNTIME_TRACE
- || OUTPUT_SWITCH == MPI_RUNTIME_TRACE )
- {
- HDFinitTrace_SDDF( traceFileName, *procNum );
- IOtracingEnabled = 1;
- }
- else if ( OUTPUT_SWITCH == SUMMARY_TRACE
- || OUTPUT_SWITCH == MPI_SUMMARY_TRACE )
- {
- HDFinitTrace_RT( traceFileName, *procNum );
- IOtracingEnabled = 1;
- }
- else if ( OUTPUT_SWITCH == NO_TRACE )
- {
- IOtracingEnabled = 0;
- }
- else
- {
- fprintf(stderr,">> Error in HDFinitTrace: the third argument ");
- fprintf(stderr,"must have a value between %4d<<\n",RUNTIME_TRACE);
- fprintf(stderr,">> and %4d, inclusive.",NO_TRACE);
- fprintf(stderr," The value received was %4u.", OUTPUT_SWITCH);
- fprintf(stderr," Exiting Program. <<\n");
- exit (-1);
- }
-#endif /* PCF_BUILD */
-}
-void
-HDFinitTrace( const char *traceFileName, int procNum, int id_flag, ... )
-{
- int i;
- int nIDs;
- va_list ap;
- HDFcallLevel = 0;
- /*===================================================================*
- // Allocate space for trace indicators. *
- //===================================================================*/
- procTrace = ( int * ) malloc( NUM_HDF_IDS*sizeof(int) );
- if ( procTrace == NULL )
- {
- fprintf(stderr,">> Error: Unable to allocate procTrace ");
- fprintf(stderr,"array in program HDFinitTrace. <<<\n");
- fprintf(stderr,">>> Exiting program! <<<\n");
- exit (-1);
- }
- /*===================================================================*
- // Initialize to 0. *
- //===================================================================*/
- for ( i = 0; i < NUM_HDF_IDS; ++i )
- {
- procTrace[i] = 0;
- }
- /*===================================================================*
- // Read in the flags indicating which procedures to trace. *
- // The last parameter passed is an indicator of the type of *
- // tracing to do. This indicator has a value larger than any *
- // of the flags. *
- //===================================================================*/
- nIDs = 0;
- va_start( ap, id_flag );
- while ( id_flag > LAST_TRACE_TYPE )
- {
- procTrace[id_flag] = 1;
- ++nIDs;
- id_flag = va_arg ( ap, int );
- }
- OUTPUT_SWITCH = id_flag;
- /*===================================================================*
- // if no flags were passed, the default is to trace all of the *
- // procedures. *
- //===================================================================*/
- if ( nIDs == 0 || procTrace[ID_ALLHDF] )
- {
- for ( i = 0; i < NUM_HDF_IDS; ++i )
- {
- procTrace[i] = 1;
- }
- }
-#ifdef PCF_BUILD
- hdfCaptureInit( traceFileName, procNum, OUTPUT_SWITCH );
-#else
- suppressMPIOtrace = TRUE;
- if ( OUTPUT_SWITCH == RUNTIME_TRACE
- || OUTPUT_SWITCH == MPI_RUNTIME_TRACE )
- {
- HDFinitTrace_SDDF( traceFileName, procNum );
- IOtracingEnabled = 1;
- }
- else if ( OUTPUT_SWITCH == SUMMARY_TRACE
- || OUTPUT_SWITCH == MPI_SUMMARY_TRACE )
- {
- HDFinitTrace_RT( traceFileName, procNum );
- IOtracingEnabled = 1;
- }
- else if ( OUTPUT_SWITCH == NO_TRACE )
- {
- IOtracingEnabled = 0;
- }
- else
- {
- fprintf(stderr,">> Error in HDFinitTrace: the third argument ");
- fprintf(stderr,"must have a value between %4d<<\n",RUNTIME_TRACE);
- fprintf(stderr,">> and %4d, inclusive.",NO_TRACE);
- fprintf(stderr," The value received was %4u.", OUTPUT_SWITCH);
- fprintf(stderr," Exiting Program. <<\n");
- exit (-1);
- }
-#endif /* PCF_BUILD */
-}
-/*======================================================================*
-// NAME *
-// HDFendTrace -- end HDF tracing *
-// USAGE *
-// VOID HDFendTrace(VOID) *
-// RETURNS *
-// None. *
-//======================================================================*/
-void hdfendtrace_( void )
-{
- HDFendTrace ();
-}
-void setHDFcallLevel( int maxLevel )
-{
- MaxHDFcallLevel = maxLevel;
-}
-void resetHDFcallLevel()
-{
- MaxHDFcallLevel = INT_MAX;
-}
-void HDFendTrace(void)
-{
-#ifdef PCF_BUILD
- hdfCaptureEnd();
-#else
- if ( OUTPUT_SWITCH == RUNTIME_TRACE
- || OUTPUT_SWITCH == MPI_RUNTIME_TRACE )
- {
- HDFendTrace_SDDF( );
- }
- else if ( OUTPUT_SWITCH == SUMMARY_TRACE
- || OUTPUT_SWITCH == MPI_SUMMARY_TRACE )
- {
- HDFendTrace_RT();
- }
-#endif /* PCF_BUILD */
- OUTPUT_SWITCH = NO_TRACE;
- MaxHDFcallLevel = INT_MAX;
-}
-void startHDFtraceEvent(int eventID)
-{
- ++HDFcallLevel;
- if ( HDFcallLevel <= MaxHDFcallLevel )
- {
-#ifdef PCF_BUILD
- if (OUTPUT_SWITCH != NO_TRACE )
- {
- traceHDFentryEvent( eventID ) ;
- }
-#else
- if ( OUTPUT_SWITCH == RUNTIME_TRACE
- || OUTPUT_SWITCH == MPI_RUNTIME_TRACE )
- {
- traceEvent( eventID, NULL, 0 ) ;
- }
- else if (OUTPUT_SWITCH != NO_TRACE )
- {
- HDFtraceEvent_RT( eventID, NULL, 0 ) ;
- }
-#endif /* PCF_BUILD */
- }
-}
-void endHDFtraceEvent(int eventID, int setID, char *setName, int IDtype )
-{
- if ( HDFcallLevel <= MaxHDFcallLevel )
- {
-#ifdef PCF_BUILD
- {
- traceHDFexitEvent( eventID );
- }
-#else
- HDFsetInfo info;
- info.setID = setID;
- info.setName = setName;
- if ( OUTPUT_SWITCH == RUNTIME_TRACE
- || OUTPUT_SWITCH == MPI_RUNTIME_TRACE )
- {
- traceEvent( eventID, (char *)&info, 0 ) ;
- }
- else if ( OUTPUT_SWITCH == SUMMARY_TRACE
- || OUTPUT_SWITCH == MPI_SUMMARY_TRACE )
- {
- HDFtraceEvent_RT( eventID, &info, 0 ) ;
- }
- else if ( OUTPUT_SWITCH != NO_TRACE )
- {
- fprintf(stderr,"endHDFtraceEvent: ");
- fprintf(stderr,"invalid OUTPUT_SWITCH %d, IDtype = %d\n",
- OUTPUT_SWITCH, IDtype ) ;
- }
-#endif /* PCF_BUILD */
- }
- --HDFcallLevel;
-}
-#ifdef PCF_BUILD
-void
-hdfCaptureInit( const char* name, int procNum, int captureType )
-{
- basePerformanceInit( name, procNum );
- genericBaseInit( captureType, procNum );
- unixIObaseInit( captureType, procNum );
-#ifdef HAVE_MPIO
- mpiIObaseInit( captureType, procNum );
-#endif
- hdfBaseInit( captureType,
- procNum,
- ID_HDF_Last_Entry,
- HDFprocNames );
- HDFcallLevel = 0;
-}
-void
-hdfCaptureEnd( void )
-{
- int i;
- timeStamp();
- for ( i = 0; i < NUM_HDF_IDS; ++i )
- {
- procTrace[i] = 0;
- }
- hdfBaseEnd();
-#ifdef HAVE_MPIO
- mpiIObaseEnd();
-#endif
- unixIObaseEnd();
- genericBaseEnd();
- basePerformanceEnd();
- MaxHDFcallLevel = INT_MAX;
-}
-#endif /* PCF_BUILD */
-/*****************************************************************************/
-/* The HDFtraceXXXX routines are substitutes for the standard I/O routines. */
-/* When libhdf5-inst.a is compiled, macros in HDFTrace.h substitute the name */
-/* HDFtraceWrite for write, HDFtraceRead for Read, etc. These routines are */
-/* then called when standard I/O is done. */
-/*****************************************************************************/
-/*****************************************************************************/
-/*+ Open routines +*/
-/*+ ------------- +*/
-/*+ +*/
-/*+ Routine: FILE *HDFtraceFOPEN( const char *filename, const char *type ) +*/
-/*+ substitute for fopen() +*/
-/*+ generates fopenBeginID, fopenEndID +*/
-/*+ record Open (fopenBegin) +*/
-/*+ Mode = -1 +*/
-/*+ +*/
-/*****************************************************************************/
-FILE*
-HDFtraceFOPEN( const char *filename, const char *type )
-{
- FILE *fp;
-#ifdef PCF_BUILD
- fp = (FILE *)traceFOPEN( filename, type );
-#else
- int fd, id;
- int flags = 0;
- struct open_args openArgs;
- size_t typeLen;
-
- if ( IOtracingEnabled )
- {
- strcpy( openArgs.filename, filename );
-
- /* check for 'b' - usually if 2 chars, second is '+' */
- typeLen = strlen( type );
- if ( ( typeLen == 2 ) && ( type [1] == 'b' ) )
- {
- typeLen = 1;
- }
-
- if ( typeLen == 1 )
- {
- switch( type[0] )
- {
- case 'r':
- flags = flags | O_RDONLY;
- break;
- case 'w':
- flags = O_TRUNC | O_CREAT | O_WRONLY;
- break;
- case 'a':
- flags = flags | O_APPEND | O_CREAT | O_WRONLY;
- break;
- }
- }
- else
- {
- switch( type[0] )
- {
- case 'r':
- flags = O_RDWR;
- break;
- case 'w':
- flags = O_TRUNC | O_CREAT | O_RDWR;
- break;
- case 'a':
- flags = O_APPEND | O_CREAT | O_RDWR;
- break;
- }
- }
- openArgs.flags = flags;
- openArgs.mode= -1;
-
- HDFtraceIOEvent( fopenBeginID, (void *)&openArgs, sizeof(openArgs) );
- }
-
- fp = fopen( filename, type );
- if ( fp != NULL )
- {
- fd = fileno( fp );
- id = set_c_mappedID( fd );
- }
- else
- {
- id = -1;
- }
-
- if ( IOtracingEnabled )
- {
- HDFtraceIOEvent( fopenEndID, (void *) &id, int_SIZE );
- }
-#endif /* PCF_BUILD */
- return( fp );
-}
-
-/*****************************************************************************/
-/*+ Routine: int HDFtraceCREAT( const char *path, mode_t mode ) +*/
-/*+ substitute for creat() +*/
-/*+ generates openBeginID, openEndID +*/
-/*+ record Open (openBeginID) +*/
-/*+ +*/
-/*****************************************************************************/
-int
-HDFtraceCREAT( const char *path, mode_t mode )
-{
- int fd;
-#ifdef PCF_BUILD
- fd = traceCREAT( path, mode );
-#else
- struct open_args openArgs;
- int id;
-
- if ( IOtracingEnabled ) {
- strcpy( openArgs.filename, path );
- openArgs.flags = O_WRONLY | O_CREAT | O_TRUNC;
- openArgs.mode = (int) mode;
-
- HDFtraceIOEvent( openBeginID, (void *)&openArgs, sizeof(openArgs) );
- }
-
- fd = creat( path, mode );
- id = set_c_mappedID( fd );
-
- if ( IOtracingEnabled ) {
- HDFtraceIOEvent( openEndID, (void *) &id, int_SIZE );
- }
-#endif /* PCF_BUILD */
- return( fd );
-}
-
-/*****************************************************************************/
-/*+ Flush routines +*/
-/*+ -------------- +*/
-/*+ +*/
-/*+ Routine: int HDFtraceFFLUSH( FILE *stream ) +*/
-/*+ substitute for fflush() +*/
-/*+ generates fflushBeginID, fflushEndID +*/
-/*+ record Flush (fflushBeginID) +*/
-/*+ +*/
-/*****************************************************************************/
-int
-HDFtraceFFLUSH( FILE *stream )
-{
- int ret;
-#ifdef PCF_BUILD
- ret = traceFFLUSH( stream );
-#else
- int id;
- int fd;
-
- if ( IOtracingEnabled )
- {
- /*
- * If stream is NULL, all files open for write are flushed.
- * We show this with a -2 in the trace record as too much overhead
- * to try and tell what files those are and generate individual
- * trace records.
- */
- if ( stream == NULL )
- {
- id = -2;
- }
- else
- {
- fd = fileno( stream );
- id = c_mappedID( fd );
- HDFtraceIOEvent( fflushBeginID, (void *) 0, int_SIZE );
- }
- }
-
- ret = fflush( stream );
-
- if ( IOtracingEnabled )
- {
- HDFtraceIOEvent( fflushEndID, (void *) &id, 0 );
- }
-
- /*
- * Note that if fflush called on stream open for reading, the file pointer
- * is moved to EOF if it isn't there already. We don't account for that
- * in our file positioning information.
- */
-#endif /* PCF_BUILD */
- return( ret );
-}
-
-/*****************************************************************************/
-/*+ Close routines +*/
-/*+ -------------- +*/
-/*+ +*/
-/*+ Routine: int HDFtraceFCLOSE( FILE *stream ) +*/
-/*+ substitute for fclose() +*/
-/*+ generates fcloseBeginID, fcloseEndID +*/
-/*+ record Close (fcloseBeginID) +*/
-/*+ +*/
-/*****************************************************************************/
-int
-HDFtraceFCLOSE( FILE *stream )
-{
- int ret;
-#ifdef PCF_BUILD
- ret = traceFCLOSE( stream );
-#else
- int id;
- int fd = fileno( stream );
-
- if ( IOtracingEnabled )
- {
- id = c_mappedID( fd );
- HDFtraceIOEvent( fcloseBeginID, (void *) &id, int_SIZE );
- }
-
- ret = fclose( stream );
-
- if ( IOtracingEnabled )
- {
- HDFtraceIOEvent( fcloseEndID, (void *) 0, 0 );
- }
-#endif /* PCF_BUILD */
-
- return( ret );
-}
-
-/*****************************************************************************/
-/*+ Routine: int HDFtrace3OPEN( char *path, int flags, mode_t mode ) +*/
-/*+ substitute for open() when called with 3 arguments +*/
-/*+ generates openBeginID, openEndID +*/
-/*+ record Open (openBeginID) +*/
-/*+ +*/
-/*****************************************************************************/
-int
-HDFtrace3OPEN( const char *path, int flags, mode_t mode )
-{
- int fd;
-#ifdef PCF_BUILD
- fd = trace3OPEN( path, flags, mode );
-#else
- struct open_args openArgs;
- int id;
-
- if ( IOtracingEnabled )
- {
- strcpy( openArgs.filename, path );
- openArgs.flags = flags;
- openArgs.mode = (int) mode;
-
- HDFtraceIOEvent( openBeginID, (char *)&openArgs, sizeof(openArgs) );
- }
-
- fd = open( path, flags, mode );
- id = set_c_mappedID( fd );
-
- if ( IOtracingEnabled )
- {
- HDFtraceIOEvent( openEndID, (char *) &id, int_SIZE );
- }
-#endif /* PCF_BUILD */
-
- return( fd );
-}
-
-/*****************************************************************************/
-/*+ Routine: int HDFtraceCLOSE( int fd ) +*/
-/*+ substitute for close() +*/
-/*+ generates closeBeginID, closeEndID +*/
-/*+ record Close (closeBeginID) +*/
-/*+ +*/
-/*****************************************************************************/
-int
-HDFtraceCLOSE( int fd )
-{
- int ret;
-#ifdef PCF_BUILD
- ret = traceCLOSE( fd );
-#else
- int id;
-
- if ( IOtracingEnabled )
- {
- id = c_mappedID( fd );
- HDFtraceIOEvent( closeBeginID, (void *) &id, int_SIZE );
- }
-
- ret = close( fd );
-
- if ( IOtracingEnabled )
- {
- HDFtraceIOEvent( closeEndID, (void *) 0, 0 );
- }
-#endif /* PCF_BUILD */
-
- return( ret );
-}
-
-/*****************************************************************************/
-/*+ Read routines +*/
-/*+ ------------- +*/
-/*+ +*/
-/*+ Routine: int HDFtraceREAD( int fd, char *buf, int nbyte ) +*/
-/*+ substitute for read() +*/
-/*+ generates readBeginID, readEndID +*/
-/*+ record Read (readBeginID) +*/
-/*+ Number Variables = 1 +*/
-/*+ Cause = -1 +*/
-/*+ +*/
-/*****************************************************************************/
-ssize_t
-HDFtraceREAD( int fd, void *buf, size_t nbyte )
-{
- ssize_t ret;
-#ifdef PCF_BUILD
- ret = traceREAD( fd, buf, nbyte );
-#else
- struct read_write_args readArgs;
- int bytes;
-
- if ( IOtracingEnabled )
- {
- readArgs.fileID = c_mappedID( fd );
- readArgs.numVariables = 1;
- readArgs.cause = -1;
-
- HDFtraceIOEvent( readBeginID, (void *) &readArgs, sizeof(readArgs) );
- }
-
- ret = read( fd, buf, nbyte );
-
- if ( IOtracingEnabled )
- {
- if ( ret > 0 )
- {
- bytes = (int)ret;
- }
- else
- {
- bytes = 0;
- }
- HDFtraceIOEvent( readEndID, (void *) &bytes, int_SIZE );
- }
-#endif /* PCF_BUILD */
-
- return( ret );
-}
-
-/*****************************************************************************/
-/*+ Routine: int HDFtraceFREAD( char *ptr, int size, int nitems, +*/
-/*+ FILE *stream) +*/
-/*+ substitute for fread() +*/
-/*+ generates freadBeginID, freadEndID +*/
-/*+ record Read (freadBeginID) +*/
-/*+ Number Variables = nitems +*/
-/*+ Cause = -1 +*/
-/*+ +*/
-/*****************************************************************************/
-size_t
-HDFtraceFREAD( void *ptr, size_t size, size_t nitems, FILE *stream )
-{
- size_t ret;
-#ifdef PCF_BUILD
- ret = traceFREAD( ptr, size, nitems, stream );
-#else
- struct read_write_args readArgs;
- int nbytes;
- int fd = fileno( stream );
-
- if ( IOtracingEnabled )
- {
- readArgs.fileID = c_mappedID( fd );
- readArgs.numVariables = (int)nitems;
- readArgs.cause = -1;
- HDFtraceIOEvent( freadBeginID, (void *) &readArgs, sizeof(readArgs) );
- }
-
- ret = fread( ptr, size, nitems, stream );
-
- if ( IOtracingEnabled )
- {
- if ( ret > 0 )
- {
- nbytes = (int)(ret * size) ;
- }
- else
- {
- nbytes = 0;
- }
- HDFtraceIOEvent( freadEndID, (void *) &nbytes, int_SIZE );
- }
-#endif /* PCF_BUILD */
-
- return( ret );
-}
-/*****************************************************************************/
-/*+ Seek routines +*/
-/*+ ------------- +*/
-/*+ +*/
-/*+ Routine: off_t HDFtraceLSEEK( int fd, off_t offset, int whence ) +*/
-/*+ substitute for lseek() +*/
-/*+ generates lseekBeginID, lseekEndID +*/
-/*+ record Seek (lseekBeginID) +*/
-/*+ +*/
-/*****************************************************************************/
-off_t
-HDFtraceLSEEK( int fd, off_t offset, int whence )
-{
- off_t ret;
-#ifdef PCF_BUILD
- ret = traceLSEEK( fd, offset, whence );
-#else
- struct seek_args seekArgs;
- long arg;
-
- if ( IOtracingEnabled )
- {
- seekArgs.fileID = c_mappedID( fd );
- seekArgs.offset = (int) offset;
- seekArgs.whence = whence;
-
- HDFtraceIOEvent( lseekBeginID, (void *) &seekArgs, sizeof(seekArgs) );
- }
-
- ret = lseek( fd, offset, whence );
-
- if ( IOtracingEnabled )
- {
- arg = (long) ret;
- HDFtraceIOEvent( lseekEndID, (void *)&arg, long_SIZE );
- }
-#endif /* PCF_BUILD */
-
- return( ret );
-}
-
-/*****************************************************************************/
-/*+ routine: int HDF traceFSEEK( FILE *stream, long offset, int whence ) +*/
-/*+ substitute for fseek() +*/
-/*+ generates fseekBeginID, fseekEndID +*/
-/*+ record Seek (fseekBeginID) +*/
-/*+ +*/
-/*****************************************************************************/
-int
-HDFtraceFSEEK( FILE *stream, long offset, int whence )
-{
- int ret;
-#ifdef PCF_BUILD
- ret = traceFSEEK( stream, offset, whence );
-#else
- struct seek_args seekArgs;
- long arg;
- int fd = fileno( stream );
-
- if ( IOtracingEnabled )
- {
- seekArgs.fileID = c_mappedID( fd );;
- seekArgs.offset = (int) offset;
- seekArgs.whence = whence;
-
- HDFtraceIOEvent( fseekBeginID, (void *) &seekArgs, sizeof(seekArgs) );
- }
-
- ret = fseek( stream, offset, whence );
-
- if ( IOtracingEnabled )
- {
- arg = ftell( stream );
- HDFtraceIOEvent( fseekEndID, (void *)&arg, long_SIZE );
- }
-#endif /* PCF_BUILD */
-
- return( ret );
-}
-
-#ifdef fpos_t
-/*****************************************************************************/
-/*+ Routine: int HDFtraceFSETPOS( FILE *stream, const fpos_t *position ) +*/
-/*+ substitute for fsetpos() +*/
-/*+ generates fsetposBeginID, fsetposEndID +*/
-/*+ record Seek (fsetposBeginID) +*/
-/*+ +*/
-/*****************************************************************************/
-int
-HDFtraceFSETPOS( FILE stream, const fpos_t *position )
-{
- int ret;
-#ifdef PCF_BUILD
- ret = traceFSETPOS( stream, position );
-#else
- struct seek_args seekArgs;
- long arg;
- int fd = fileno( stream );
-
- if ( IOtracingEnabled )
- {
- seekArgs.fileID = c_mappedID( fd );;
- seekArgs.offset = (int) *position;
- seekArgs.whence = SEEK_SET;
-
- HDFtraceIOEvent( fsetposBeginID, (void *) &seekArgs, sizeof(seekArgs) );
- }
-
- ret = fsetpos( stream, position );
-
- if ( IOtracingEnabled )
- {
- arg = (long) *position;
- HDFtraceIOEvent( fsetposEndID, (void *)&arg, long_SIZE );
- }
-#endif /* PCF_BUILD */
-
- return( ret );
-}
-#endif /* fpos_t */
-
-/*****************************************************************************/
-/*+ Routine: void HDFtraceREWIND ( FILE *stream ) +*/
-/*+ substitute for rewind() +*/
-/*+ generates rewindBeginID, rewindEndID +*/
-/*+ record Seek (rewindBeginID) +*/
-/*+ Offset = 0 +*/
-/*+ Whence = SEEK_SET +*/
-/*+ +*/
-/*****************************************************************************/
-void
-HDFtraceREWIND( FILE *stream )
-{
-#ifdef PCF_BUILD
- traceREWIND( stream );
-#else
- long arg;
- struct seek_args seekArgs;
- int fd = fileno( stream );
-
- if ( IOtracingEnabled )
- {
- seekArgs.fileID = c_mappedID( fd );
- seekArgs.offset = 0;
- seekArgs.whence = SEEK_SET;
-
- HDFtraceIOEvent( rewindBeginID, (void *) &seekArgs, sizeof(seekArgs) );
- }
-
- rewind( stream );
-
- if ( IOtracingEnabled )
- {
- arg = 0;
- HDFtraceIOEvent( rewindEndID, (void *)&arg, long_SIZE );
- }
-#endif /* PCF_BUILD */
-
- return;
-}
-
-/*****************************************************************************/
-/*+ Write routines +*/
-/*+ -------------- +*/
-/*+ +*/
-/*+ Routine: int HDFtraceWRITE( int fd, char *buf, int nbyte ) +*/
-/*+ substitute for write() +*/
-/*+ generates writeBeginID, writeEndID +*/
-/*+ record Write (writeBeginID) +*/
-/*+ Number Variables = 1 +*/
-/*+ Cause = -1 +*/
-/*+ +*/
-/*****************************************************************************/
-ssize_t
-HDFtraceWRITE( int fd, const void *buf, size_t nbyte )
-{
- ssize_t ret;
-#ifdef PCF_BUILD
- ret = traceWRITE( fd, buf, nbyte );
-#else
- struct read_write_args writeArgs;
- int bytes;
-
- if ( IOtracingEnabled )
- {
- writeArgs.fileID = c_mappedID( fd );
- writeArgs.numVariables = 1;
- writeArgs.cause = -1;
-
- HDFtraceIOEvent( writeBeginID, (void *) &writeArgs, sizeof(writeArgs) );
- }
-
- ret = write( fd, buf, nbyte );
-
- if ( IOtracingEnabled )
- {
- if ( ret > 0 )
- {
- bytes = (int)ret;
- }
- else
- {
- bytes = 0;
- }
- HDFtraceIOEvent( writeEndID, (void *) &bytes, int_SIZE );
- }
-#endif /* PCF_BUILD */
- return( ret );
-}
-
-/*****************************************************************************/
-/*+ Routine: size_t HDFtraceFWRITE( const char *ptr, int size, int nitems,+*/
-/*+ FILE *stream ) +*/
-/*+ substitute for fwrite() +*/
-/*+ generates fwriteBeginID, fwriteEndID +*/
-/*+ record Write (fwriteBeginID) +*/
-/*+ Number Variables = nitems +*/
-/*+ Cause = -1 +*/
-/*+ +*/
-/*****************************************************************************/
-size_t
-HDFtraceFWRITE(const void *ptr,size_t size,size_t nitems,FILE *stream )
-
-{
- size_t ret;
-#ifdef PCF_BUILD
- ret = traceFWRITE( ptr, size, nitems, stream );
-#else
- struct read_write_args writeArgs;
- int nbytes;
- int fd = fileno( stream );
-
- if ( IOtracingEnabled )
- {
- writeArgs.fileID = c_mappedID( fd );
- writeArgs.numVariables = (int)nitems;
- writeArgs.cause = -1;
-
- HDFtraceIOEvent(fwriteBeginID, (void *)&writeArgs, sizeof(writeArgs));
- }
-
- ret = fwrite( ptr, size, nitems, stream );
-
- if ( IOtracingEnabled )
- {
- if ( ret > 0 )
- {
- nbytes = (int)(ret * size) ;
- }
- else
- {
- nbytes = 0;
- }
- HDFtraceIOEvent( fwriteEndID, (void *) &nbytes, int_SIZE );
- }
-#endif /* PCF_BUILD */
-
- return( ret );
-}
-/*****************************************************************************/
-/*+ Routine: int HDFtracePUTS( char *s ) +*/
-/*+ substitute for puts() +*/
-/*+ generates fwriteBeginID, fwriteEndID +*/
-/*+ record Write (fwriteBeginID) +*/
-/*+ Number Variables = 1 +*/
-/*+ Cause = -1 +*/
-/*+ +*/
-/*****************************************************************************/
-int
-HDFtracePUTS( const char *s )
-{
- int ret;
-#ifdef PCF_BUILD
- ret = tracePUTS( s );
-#else
- int fd = fileno( stdout );
- struct read_write_args writeArgs;
- if ( IOtracingEnabled )
- {
- writeArgs.fileID = c_mappedID( fd );
- writeArgs.numVariables = 1;
- writeArgs.cause = -1;
-
- HDFtraceIOEvent( fwriteBeginID, (void *) &writeArgs, sizeof(writeArgs) );
- }
-
- ret = puts( s );
-
- if ( IOtracingEnabled )
- {
- HDFtraceIOEvent( fwriteEndID, (void *) &ret, int_SIZE );
- }
-#endif
-
- return( ret );
-}
-
-void getHDFprocName ( int i, char buff[81] )
-{
- strcpy( buff, HDFprocNames[i] );
-}
-
-/*****************************************************************************/
-/*+ Routine: int HDFtraceFPUTC( int c, FILE *stream ) +*/
-/*+ substitute for fputc() +*/
-/*+ generates fwriteBeginID, fwriteEndID +*/
-/*+ record Write (fwriteBeginID) +*/
-/*+ Number Variables = 1 +*/
-/*+ Cause = -1 +*/
-/*+ +*/
-/*****************************************************************************/
-int
-HDFtraceFPUTC( int c, FILE *stream )
-{
- int ret;
-#ifdef PCF_BUILD
- ret = traceFPUTC( c, stream );
-#else
- struct read_write_args writeArgs;
- int nbytes = char_SIZE;
- int fd = fileno( stream );
-
- if ( IOtracingEnabled )
- {
- writeArgs.fileID = c_mappedID( fd );
- writeArgs.numVariables = 1;
- writeArgs.cause = -1;
-
- HDFtraceIOEvent( fwriteBeginID, (void *) &writeArgs, sizeof(writeArgs) );
- }
-
- ret = fputc( c, stream );
-
- if ( IOtracingEnabled )
- {
- if ( ret == EOF )
- {
- nbytes = 0;
- HDFtraceIOEvent( fwriteEndID, (void *) &nbytes, int_SIZE );
- }
- }
-#endif /* PCF_BUILD */
- return( ret );
-}
-/*****************************************************************************/
-/*+ Routine: int HDFtraceFPUTS( char *s, FILE *stream ) +*/
-/*+ substitute for fputs() +*/
-/*+ generates fwriteBeginID, fwriteEndID +*/
-/*+ record Write (fwriteBeginID) +*/
-/*+ Number Variables = 1 +*/
-/*+ Cause = -1 +*/
-/*+ +*/
-/*****************************************************************************/
-int HDFtraceFPUTS( const char *s, FILE *stream )
-{
- int ret;
-
-#ifdef PCF_BUILD
- ret = traceFPUTS( s, stream );
-#else
- int fd = fileno( stream );
- struct read_write_args writeArgs;
- if ( IOtracingEnabled )
- {
- writeArgs.fileID = c_mappedID( fd );
- writeArgs.numVariables = 1;
- writeArgs.cause = -1;
-
- HDFtraceIOEvent(fwriteBeginID, (void *)&writeArgs, sizeof(writeArgs));
- }
-
- ret = fputs( s, stream );
-
- if ( IOtracingEnabled )
- {
- HDFtraceIOEvent( fwriteEndID, (void *) &ret, int_SIZE );
- }
-#endif /* PCF_BUILD */
-
- return( ret );
-}
-
-void*
-HDFtraceMALLOC(size_t bytes )
-{
- void *ptr;
-#ifdef PCF_BUILD
- ptr = (void *)traceMALLOC( bytes );
-#else
- int byte_req;
- byte_req = (int)bytes;
- if ( IOtracingEnabled )
- {
- HDFtraceIOEvent ( ID_malloc, NULL, 0 );
- }
-
- ptr = malloc( bytes );
-
- if ( IOtracingEnabled )
- {
- HDFtraceIOEvent ( -ID_malloc, &byte_req, sizeof(int) );
- }
-#endif /* PCF_BUILD */
-
- return ptr ;
-
-}
-
-#ifndef PCF_BUILD
-void
-HDFtraceIOEvent( int eventType, void *dataPtr, unsigned dataLen )
-{
- if ( OUTPUT_SWITCH == RUNTIME_TRACE
- || OUTPUT_SWITCH == MPI_RUNTIME_TRACE )
- {
- traceEvent( eventType, dataPtr, dataLen );
- }
- else
- {
- HDFtraceEvent_RT( eventType, (HDFsetInfo *)dataPtr, dataLen );
- }
-}
-/*======================================================================*
-// record the final time stamp *
-//======================================================================*/
-void
-HDFfinalTimeStamp( void )
-{
- CLOCK currentTime;
- double seconds;
- struct {
- int packetLength,
- packetType,
- packetTag,
- timeDim;
- double Seconds;
- int eventID,
- node,
- dataLen;
- } Packet;
-
- currentTime = getClock();
- seconds = clockToSeconds( currentTime );
-
- Packet.packetLength = sizeof(Packet);
- Packet.packetType = PKT_DATA;
- Packet.packetTag = FAMILY_EXTERNAL | RECORD_TRACE;
- Packet.timeDim = 0; /* use fp time stamp only */
- Packet.Seconds = seconds; /* fp time stamp */
- Packet.eventID = ID_timeStamp;
- Packet.node = TRgetNode();
- Packet.dataLen = 0;
- putBytes( (void *)&Packet , sizeof(Packet) );
-}
-/*======================================================================*
-// This Program is called to specify which routines are to be traced. *
-// On first entry, the program allocates storage for and initializes a *
-// global array procTrace. The array has one element for each possible *
-// HDF procedure and HDF library file. If a procedure or all of the *
-// procedure in an HDF file are to be traced, then the elemen in the *
-// array corresponding to the procedure or file is turned on. This is *
-// used by the macros TRACE_ON and TRACE_OFF to enable tracing. If *
-// this procedure is not called prior to initialization, then all of *
-// the elements of procTrace corresponding to HDF files will be *
-// turned on, in which case all HDF procedures will be traced. *
-//======================================================================*/
-void
-PabloHDFTrace( int ID )
-{
- int i;
- if ( procTrace == NULL ) {
- procTrace = ( int * ) malloc( NUM_HDF_IDS*sizeof(int) );
- if ( procTrace == NULL ) {
- fprintf(stderr,">> Error: Unable to allocate procTrace ");
- fprintf(stderr,"array in program PabloHDFTrace. <<<\n");
- fprintf(stderr," Exiting program. <<<\n");
- exit (-1);
- }
- for ( i = 0; i < NUM_HDF_IDS; ++i ) {
- procTrace[i] = 0;
- }
- }
- if ( ID >= 0 && ID < NUM_HDF_IDS ) {
- procTrace[ID] = 1;
- } else {
- fprintf(stderr,">> Error: Value passed to PabloHDFTrace, ");
- fprintf(stderr,"%d, is out of range. <<<\n",ID);
- fprintf(stderr," Exiting program. <<<\n");
- exit (-1);
- }
-}
-#endif /* PCF_BUILD */
diff --git a/pablo/PabloHDF_MPIO.c b/pablo/PabloHDF_MPIO.c
deleted file mode 100644
index 025e823..0000000
--- a/pablo/PabloHDF_MPIO.c
+++ /dev/null
@@ -1,1366 +0,0 @@
-/*
- * This file is an extension to NCSA HDF to enable the use of the
- * Pablo trace library.
- *
- * Developed by: The TAPESTRY Parallel Computing Laboratory
- * University of Illinois at Urbana-Champaign
- * Department of Computer Science
- * 1304 W. Springfield Avenue
- * Urbana, IL 61801
- *
- * Copyright (c) 1995
- * The University of Illinois Board of Trustees.
- * All Rights Reserved.
- *
- * PABLO is a registered trademark of
- * The Board of Trustees of the University of Illinois
- * registered in the U.S. Patent and Trademark Office.
- *
- * Author: George Xin Zhou (xzhou@cs.uiuc.edu)
- * Contributing Author: Jonathan M. Reid (jreid@cs.uiuc.edu)
- *
- * Project Manager and Principal Investigator:
- * Daniel A. Reed (reed@cs.uiuc.edu)
- *
- * Funded by: National Aeronautics and Space Administration under NASA
- * Contracts NAG-1-613 and USRA 5555-22 and by the Advanced Research
- * Projects Agency under ARPA contracts DAVT63-91-C-0029 and
- * DABT63-93-C-0040.
- *
- */
-/*======================================================================*
-// File: PabloHDF_MPIO.c *
-// Purpose: support use of Pablo trace library to analyze MPIO calls *
-// within HDF calls *
-// Most of the code is conditionally compiled dependent on the compiler *
-// flag HAVE_H5_PARALLEL which is set in the Makefile in thie hdf/pablo *
-// directory. *
-// Contents
-// HDF_get_NodeNum *
-//
-// HDF_get_mode *
-// returns the node number *
-//
-// HDF_get_source *
-//
-// HDF_get_comm
-//
-// HDF_get_Datatype
-//
-// HDF_get_DataRep
-//
-// int HDF_get_Bytes
-//
-// int PabloMPI_File_open
-//
-// int PabloMPI_File_close
-//
-// int PabloMPI_File_set_size
-//
-// int PabloMPI_File_get_size
-//
-// int PabloMPI_File_set_view
-//
-// int PabloMPI_File_get_view
-//
-// int PabloMPI_File_read_at
-//
-// int PabloMPI_File_read_at_all
-//
-// int PabloMPI_File_write_at
-//
-// int PabloMPI_File_write_at_all
-//
-// int PabloMPI_File_sync
-//
-// int HDF_MPI_File_open
-//
-// int HDF_MPI_File_close
-//
-// int HDF_MPI_File_set_size
-//
-// int HDF_MPI_File_get_size
-//
-// int HDF_MPI_File_set_view
-//
-// int HDF_MPI_File_get_view
-//
-// int HDF_MPI_File_read_at
-//
-// int HDF_MPI_File_read_at_all
-//
-// int HDF_MPI_File_write_at
-//
-// int HDF_MPI_File_write_at_all
-//
-// int HDF_MPI_File_sync
-//
-//======================================================================*/
-#ifdef H5_HAVE_PARALLEL
-void HDFtraceEvent_RT( int , char *, unsigned ) ;
-#include "mpi.h"
-/************************************************************************/
-/* Return the node number. */
-/************************************************************************/
-void HDF_get_NodeNum( int* nodeNum )
-{
- MPI_Comm_rank( MPI_COMM_WORLD, nodeNum );
-}
-#ifdef _BUILD
-#include "HDFTrace.h"
-#include "ProcTrace.h"
-#include "ProcIDs.h"
-#include "MPIO_Trace.h"
-#include "MPIO_EventArgs.h"
-#include "MPIO_Data.h"
-
-extern int OUTPUT_SWITCH;
-/* Global variable declarations and definitions. */
-static int HDFlocalNode = 0;
-int HDFmyNode;
-int myHDFid = 3;
-/* Function prototypes */
-int HDF_get_mode( int );
-int HDF_get_source( int );
-int HDF_get_comm( MPI_Comm );
-int HDF_get_Datatype( MPI_Datatype );
-int HDF_get_DataRep( char* );
-int HDF_get_Bytes( MPI_Datatype, int );
-void HDFtraceIOEvent( int , void *, unsigned );
-
-/* Get the mode at the file openning */
-int
-HDF_get_mode( int amode )
-{
- if( amode == MPI_MODE_RDONLY || amode == MPI_MODE_RDWR ||
- amode == MPI_MODE_WRONLY || amode == MPI_MODE_CREATE ||
- amode == MPI_MODE_EXCL || amode == MPI_MODE_DELETE_ON_CLOSE ||
- amode == MPI_MODE_UNIQUE_OPEN ||
- /* amode == MPI_MODE_SEQUENTIAL || */
- amode == MPI_MODE_APPEND )
- return amode;
- else
- return PABLO_MPI_MODE_NULL;
-}
-
-/* Get the node number */
-int
-HDF_get_source( int source )
-{
- if ( source == MPI_ANY_SOURCE ) {
- return PABLO_MPI_ANYSOURCE;
- }
-
- if ( source == MPI_PROC_NULL ) {
- return PABLO_MPI_PROCNULL;
- }
-
- else {
- return source;
- }
-}
-
-/* get the communicator ID */
-/* this is dummy for compatability with MPIO Traceing */
-int
-HDF_get_comm( MPI_Comm in_comm )
-{
- return 0;
-}
-/* Get the MPI_Datatype (mapped to a integer) */
-int HDF_get_Datatype( MPI_Datatype datatype )
-{
- /* elementary datatypes (C) */
- if ( datatype == MPI_CHAR )
- return PABLO_MPI_CHAR;
- else if ( datatype == MPI_SHORT )
- return PABLO_MPI_SHORT;
- else if ( datatype == MPI_INT )
- return PABLO_MPI_INT;
- else if ( datatype == MPI_LONG )
- return PABLO_MPI_LONG;
- else if ( datatype == MPI_UNSIGNED_CHAR )
- return PABLO_MPI_UNSIGNED_CHAR;
- else if ( datatype == MPI_UNSIGNED_SHORT )
- return PABLO_MPI_UNSIGNED_SHORT;
- else if ( datatype == MPI_UNSIGNED )
- return PABLO_MPI_UNSIGNED;
- else if ( datatype == MPI_UNSIGNED_LONG )
- return PABLO_MPI_UNSIGNED_LONG;
- else if ( datatype == MPI_FLOAT )
- return PABLO_MPI_FLOAT;
- else if ( datatype == MPI_DOUBLE )
- return PABLO_MPI_DOUBLE;
- else if ( datatype == MPI_LONG_DOUBLE )
- return PABLO_MPI_LONG_DOUBLE;
-
- /* elementary datatypes (FORTRAN) */
-#ifdef MPI_INTEGER
- else if ( datatype == MPI_INTEGER )
- return PABLO_MPI_INTEGER;
-#endif
-#ifdef MPI_REAL
- else if ( datatype == MPI_REAL )
- return PABLO_MPI_REAL;
-#endif
-#ifdef MPI_DOUBLE_PRECISION
- else if ( datatype == MPI_DOUBLE_PRECISION )
- return PABLO_MPI_DOUBLE_PRECISION;
-#endif
-#ifdef MPI_COMPLEX
- else if ( datatype == MPI_COMPLEX )
- return PABLO_MPI_COMPLEX;
-#endif
-#ifdef MPI_DOUBLE_COMPLEX
- else if ( datatype == MPI_DOUBLE_COMPLEX )
- return PABLO_MPI_DOUBLE_COMPLEX;
-#endif
-#ifdef MPI_LOGICAL
- else if ( datatype == MPI_LOGICAL )
- return PABLO_MPI_LOGICAL;
-#endif
-#ifdef MPI_CHARACTER
- else if ( datatype == MPI_CHARACTER )
- return PABLO_MPI_CHARACTER;
-#endif
-
- /* other datatypes (C, Fortran).*/
- else if ( datatype == MPI_BYTE )
- return PABLO_MPI_BYTE;
- else if ( datatype == MPI_PACKED )
- return PABLO_MPI_PACKED;
- else if ( datatype == MPI_LB )
- return PABLO_MPI_LB;
- else if ( datatype == MPI_UB )
- return PABLO_MPI_UB;
-
-
- /* reduction datatypes (C). */
- else if ( datatype == MPI_FLOAT_INT )
- return PABLO_MPI_FLOAT_INT;
- else if ( datatype == MPI_DOUBLE_INT )
- return PABLO_MPI_DOUBLE_INT;
- else if ( datatype == MPI_LONG_INT )
- return PABLO_MPI_LONG_INT;
- else if ( datatype == MPI_2INT )
- return PABLO_MPI_2INT;
- else if ( datatype == MPI_SHORT_INT )
- return PABLO_MPI_SHORT_INT;
- else if ( datatype == MPI_LONG_DOUBLE_INT )
- return PABLO_MPI_LONG_DOUBLE_INT;
-
- /* Reduction datatypes (FORTRAN) */
-#ifdef MPI_2REAL
- else if ( datatype == MPI_2REAL )
- return PABLO_MPI_2REAL;
-#endif
-#ifdef MPI_2DOUBLE_PRECISION
- else if ( datatype == MPI_2DOUBLE_PRECISION )
- return PABLO_MPI_2DOUBLE_PRECISION;
-#endif
-#ifdef MPI_2INTEGER
- else if ( datatype == MPI_2INTEGER )
- return PABLO_MPI_2INTEGER;
-#endif
-
-#ifdef MPI_2COMPLEX
- else if ( datatype == MPI_2COMPLEX )
- return PABLO_MPI_2COMPLEX;
-#endif
-#ifdef MPI_2DOUBLE_COMPLEX
- else if ( datatype == MPI_2DOUBLE_COMPLEX )
- return PABLO_MPI_2DOUBLE_COMPLEX;
-#endif
-
-/* optional datatypes (C).*/
-#ifdef MPI_LONG_LONG_INT
- else if ( datatype == MPI_LONG_LONG_INT )
- return PABLO_MPI_LONG_LONG_INT;
-#endif
- else if ( datatype == MPI_DATATYPE_NULL )
- return PABLO_MPI_DATATYPE_NULL;
- else
- return PABLO_MPI_USER_DEF;
-}
-
-/* data representations */
-int HDF_get_DataRep( char* datarep )
-{
- if ( !strcmp( datarep, "native" ) )
- return PABLO_MPI_NATIVE;
- else if ( !strcmp( datarep, "internal" ) )
- return PABLO_MPI_INTERNAL;
- else if ( !strcmp( datarep, "external32" ) )
- return PABLO_MPI_EXTERNAL32;
- else
- return (-1);
-}
-
-/*****************************************************************************/
-/* The routines below are there to bypass the MPI I/O Tracing. When MPI I/O */
-/* tracing is done with a nonstandard MPI I/O implementation, problems can */
-/* occur in linking and in data recording. */
-/* For each of the MPI I/O routines MPI_File_xxx used in HDF, there are two */
-/* entries: HDF_MPI_File_xxx and PabloMPI_File_xxx. Macros replace the */
-/* MPI_File_xxx call with HDF_MPI_File_xxx. */
-/* If SUMMARY Tracing is used */
-/* HDF_MPI_File_xxx routine will record entry data in a table, call the */
-/* IF RUNTIME Tracing is used */
-/* HDF_MPI_File_xxx routine calls PabloMPI_File_xxx. This routine writes */
-/* data to the trace file, calls the standard MPI_File_xxx routine, then */
-/* records exit data to a trace file. */
-/* The PabloMPI_File_xxx functionality could have been incorporated into the */
-/* HDF_MPI_File_xxx routine, but was not done so for expediency. */
-/*****************************************************************************/
-int PabloMPI_File_open( MPI_Comm comm,
- char *filename,
- int amode,
- MPI_Info info,
- MPI_File *fh ) ;
-
-int PabloMPI_File_close( MPI_File *fh ) ;
-
-int PabloMPI_File_set_size( MPI_File fh, MPI_Offset size ) ;
-
-int PabloMPI_File_get_size( MPI_File fh, MPI_Offset *size ) ;
-
-int PabloMPI_File_set_view( MPI_File fh,
- MPI_Offset disp,
- MPI_Datatype etype,
- MPI_Datatype filetype,
- char *datarep,
- MPI_Info info ) ;
-
-int PabloMPI_File_get_view( MPI_File fh,
- MPI_Offset *disp,
- MPI_Datatype *etype,
- MPI_Datatype *filetype,
- char *datarep ) ;
-
-int PabloMPI_File_read_at( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status ) ;
-
-int PabloMPI_File_read_at_all( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status ) ;
-
-int PabloMPI_File_write_at( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status ) ;
-
-int PabloMPI_File_write_at_all( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status ) ;
-
-int PabloMPI_File_sync( MPI_File fh ) ;
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int
-HDF_MPI_File_open( MPI_Comm comm,
- char *filename,
- int amode,
- MPI_Info info,
- MPI_File *fh )
-{
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE )
- {
- returnVal = PabloMPI_File_open( comm, filename, amode, info, fh );
- }
- else
- {
- dataLen = sizeof( HDFsetInfo );
- dataPtr.setID = 0;
- dataPtr.setName = (char *)malloc( strlen(filename) + 1);
- strcpy( dataPtr.setName , filename );
- HDFtraceEvent_RT( HDFmpiOpenID, &dataPtr, dataLen );
- returnVal = MPI_File_open( comm, filename, amode, info, fh );
- dataPtr.setID = (long)fh;
- HDFtraceEvent_RT( -HDFmpiOpenID, &dataPtr, dataLen );
- }
- return returnVal;
-}
-
-
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int
-HDF_MPI_File_close( MPI_File *fh )
-{
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE )
- {
- returnVal = PabloMPI_File_close( fh );
- }
- else
- {
- dataLen = sizeof( HDFsetInfo );
- dataPtr.setID = (long)fh;
- dataPtr.setName = NULL;
- HDFtraceEvent_RT( HDFmpiCloseID, &dataPtr, dataLen );
- returnVal = MPI_File_close( fh );
- HDFtraceEvent_RT( -HDFmpiCloseID, &dataPtr, dataLen );
- free( dataPtr.setName );
- }
- return returnVal;
-}
-
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int
-HDF_MPI_File_set_size( MPI_File fh, MPI_Offset size )
-{
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE )
- {
- returnVal = PabloMPI_File_set_size( fh, size );
- }
- else
- {
- dataLen = 1;
- dataPtr.setID = (long)fh;
- HDFtraceEvent_RT( HDFmpiSetSizeID,&dataPtr,dataLen );
- returnVal = MPI_File_set_size( fh, size );
- HDFtraceEvent_RT( -HDFmpiSetSizeID, &dataPtr, dataLen );
- }
- return returnVal;
-}
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int
-HDF_MPI_File_get_size( MPI_File fh, MPI_Offset *size )
-{
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE ) {
- returnVal = PabloMPI_File_get_size( fh, size);
- } else {
- dataLen = 1;
- dataPtr.setID = (long)fh;
- HDFtraceEvent_RT( HDFmpiGetSizeID,
- &dataPtr,dataLen );
- returnVal = MPI_File_get_size( fh, size);
- HDFtraceEvent_RT( -HDFmpiGetSizeID,
- &dataPtr,dataLen );
- }
- return returnVal;
-}
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int
-HDF_MPI_File_set_view( MPI_File fh,
- MPI_Offset disp,
- MPI_Datatype etype,
- MPI_Datatype filetype,
- char *datarep,
- MPI_Info info )
-{
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE )
- {
- returnVal = PabloMPI_File_set_view( fh, disp, etype, filetype,
- datarep, info );
- }
- else
- {
- dataLen = 1;
- dataPtr.setID = (long)fh;
- HDFtraceEvent_RT( HDFmpiSetViewID,
- &dataPtr,dataLen );
- returnVal = MPI_File_set_view( fh, disp, etype, filetype,
- datarep, info );
- HDFtraceEvent_RT( -HDFmpiSetViewID,
- &dataPtr,dataLen );
- }
- return returnVal;
-}
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int
-HDF_MPI_File_get_view( MPI_File fh,
- MPI_Offset *disp,
- MPI_Datatype *etype,
- MPI_Datatype *filetype,
- char *datarep )
-{
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE )
- {
- returnVal = PabloMPI_File_get_view(fh, disp, etype, filetype, datarep);
- }
- else
- {
- dataLen = 1;
- dataPtr.setID = (long)fh;
- HDFtraceEvent_RT( HDFmpiSetViewID, &dataPtr,dataLen );
- returnVal = MPI_File_get_view(fh, disp, etype, filetype, datarep);
- HDFtraceEvent_RT( -HDFmpiSetViewID, &dataPtr,dataLen );
- returnVal = MPI_File_get_view(fh, disp, etype, filetype, datarep);
-
- }
- return returnVal;
-}
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int HDF_MPI_File_read_at( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status )
-{
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
- int rCount;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE )
- {
- returnVal = PabloMPI_File_read_at( fh,
- offset,
- buf,
- count,
- datatype,
- status );
- }
- else
- {
- dataLen = sizeof(dataPtr);
- dataPtr.setID = (long)fh;
- dataPtr.numBytes = HDF_get_Bytes( datatype, count );
- HDFtraceEvent_RT( HDFmpiReadAtID,
- &dataPtr,dataLen );
- returnVal = MPI_File_read_at( fh,
- offset,
- buf,
- count,
- datatype,
- status );
- MPI_Get_count(status,datatype,&rCount);
- if ( rCount < 0 || rCount > count )
- {
- dataPtr.numBytes = -1;
- }
- else
- {
- dataPtr.numBytes = HDF_get_Bytes( datatype, rCount );
- }
- HDFtraceEvent_RT( -HDFmpiReadAtID,
- &dataPtr,dataLen );
- }
- return returnVal;
-}
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int
-HDF_MPI_File_read_at_all( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status )
-{
-
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
- int rCount;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE )
- {
- returnVal = PabloMPI_File_read_at_all( fh,
- offset,
- buf,
- count,
- datatype,
- status );
- }
- else
- {
- dataLen = sizeof(dataPtr);
- dataPtr.setID = (long)fh;
- dataPtr.numBytes = HDF_get_Bytes( datatype, count );
- HDFtraceEvent_RT( HDFmpiReadAtAllID,
- &dataPtr,dataLen );
- returnVal = MPI_File_read_at_all( fh,
- offset,
- buf,
- count,
- datatype,
- status );
- MPI_Get_count(status,datatype,&rCount);
- if ( rCount < 0 || rCount > count )
- {
- dataPtr.numBytes = -1;
- }
- else
- {
- dataPtr.numBytes = HDF_get_Bytes( datatype, rCount );
- }
- HDFtraceEvent_RT( -HDFmpiReadAtAllID,
- &dataPtr,dataLen );
- }
- return returnVal;
-}
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int
-HDF_MPI_File_write_at( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status )
-{
-
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
- int rCount;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE )
- {
- returnVal = PabloMPI_File_write_at( fh,
- offset,
- buf,
- count,
- datatype,
- status );
- }
- else
- {
- dataLen = sizeof(dataPtr);
- dataPtr.setID = (long)fh;
- dataPtr.numBytes = HDF_get_Bytes( datatype, count );
- HDFtraceEvent_RT( HDFmpiWriteAtID, &dataPtr,dataLen );
- returnVal = MPI_File_write_at( fh,
- offset,
- buf,
- count,
- datatype,
- status );
- MPI_Get_count(status,datatype,&rCount);
- if ( rCount < 0 || rCount > count )
- {
- dataPtr.numBytes = -1;
- }
- else
- {
- dataPtr.numBytes = HDF_get_Bytes( datatype, rCount );
- }
- HDFtraceEvent_RT( -HDFmpiWriteAtID, &dataPtr,dataLen );
- }
- return returnVal;
-}
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int
-HDF_MPI_File_write_at_all( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status )
-{
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
- int numBytes;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE )
- {
- returnVal = PabloMPI_File_write_at_all( fh,
- offset,
- buf,
- count,
- datatype,
- status );
- }
- else
- {
- dataLen = sizeof(dataPtr);
- dataPtr.setID = (long)fh;
- dataPtr.numBytes = HDF_get_Bytes( datatype, count );
- HDFtraceEvent_RT( HDFmpiWriteAtAllID, &dataPtr, dataLen );
- returnVal = MPI_File_write_at_all( fh,
- offset,
- buf,
- count,
- datatype,
- status );
- if ( returnVal == MPI_SUCCESS )
- {
- numBytes = HDF_get_Bytes( datatype, count );
- }
- else
- {
- numBytes = -1;
- }
- dataPtr.numBytes = numBytes;
- HDFtraceEvent_RT( -HDFmpiWriteAtAllID,
- &dataPtr,dataLen );
- }
- return returnVal;
-}
-
-/*======================================================================*
-// Pass call through to regular MPIO entry except in case of Real Time *
-// tracing. *
-// Note: The regular MPIO entry may or may not be instrumented. *
-//======================================================================*/
-int
-HDF_MPI_File_sync( MPI_File fh )
-{
- int returnVal;
- HDFsetInfo dataPtr;
- int dataLen;
-
- if ( OUTPUT_SWITCH != MPI_SUMMARY_TRACE )
- {
- returnVal = PabloMPI_File_sync ( fh );
- }
- else
- {
- dataLen = 1;
- dataPtr.setID = (long)fh;
- HDFtraceEvent_RT( HDFmpiSyncID,
- &dataPtr,dataLen );
- returnVal = MPI_File_sync ( fh );
- HDFtraceEvent_RT( -HDFmpiSyncID,
- &dataPtr,dataLen );
- }
- return returnVal;
-}
-
-int
-HDF_get_Bytes( MPI_Datatype datatype, int count )
-{
- int nm_bytes;
-
- MPI_Type_size( datatype, &nm_bytes );
- return( nm_bytes * count );
-}
-
-int
-PabloMPI_File_open( MPI_Comm comm,
- char *filename,
- int amode,
- MPI_Info info,
- MPI_File *fh )
-{
- int returnVal;
-
- struct mpiOpenBeginArgs mpiOpenBeginArguments;
- struct mpiOpenEndArgs mpiOpenEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "PabloMPI_File_open\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- MPI_Comm_rank( comm, &HDFlocalNode );
- MPI_Comm_rank( MPI_COMM_WORLD, &HDFmyNode );
-
- mpiOpenBeginArguments.localNode = HDF_get_source( HDFlocalNode );
- mpiOpenBeginArguments.globalNode = HDFmyNode;
- mpiOpenBeginArguments.communicatorID = HDF_get_comm( comm );
- mpiOpenBeginArguments.mode = amode;
- strcpy( mpiOpenBeginArguments.fileName, filename );
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiOpenBeginID,
- (char *) &mpiOpenBeginArguments,
- sizeof( mpiOpenBeginArguments ) );
-
- returnVal = MPI_File_open( comm, filename, amode, info, fh );
-
- mpiOpenEndArguments.localNode = HDF_get_source( HDFlocalNode );
- mpiOpenEndArguments.globalNode = HDFmyNode;
- /* the fileID is mapped to the fp's address */
- myHDFid++;
- mpiOpenEndArguments.fileID = myHDFid;
-
- /* Generate exit record */
- HDFtraceIOEvent( mpiOpenEndID,
- (char *) &mpiOpenEndArguments,
- sizeof( mpiOpenEndArguments ) );
-
- return returnVal;
-}
-
-int
-PabloMPI_File_close( MPI_File *fh )
-{
- int returnVal;
-
- struct mpiCloseBeginArgs mpiCloseBeginArguments;
- struct mpiCloseEndArgs mpiCloseEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "MPI_File_close\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- mpiCloseBeginArguments.localNode = HDFlocalNode;
- mpiCloseBeginArguments.globalNode = HDFmyNode;
- mpiCloseBeginArguments.fileID = myHDFid;
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiCloseBeginID,
- (char *) &mpiCloseBeginArguments,
- sizeof( mpiCloseBeginArguments ) );
-
- returnVal = MPI_File_close( fh );
-
- mpiCloseEndArguments.localNode = HDFlocalNode;
- mpiCloseEndArguments.globalNode = HDFmyNode;
- mpiCloseEndArguments.fileID = myHDFid;
-
- /* Generate exit record */
- HDFtraceIOEvent( mpiCloseEndID,
- (char *) &mpiCloseEndArguments,
- sizeof( mpiCloseEndArguments ) );
-
- return returnVal;
-}
-
-int
-PabloMPI_File_set_size( MPI_File fh, MPI_Offset size )
-{
- int returnVal;
-
- struct mpiSetSizeBeginArgs mpiSetSizeBeginArguments;
- struct mpiSetSizeEndArgs mpiSetSizeEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "MPI_File_set_size\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- mpiSetSizeBeginArguments.localNode = HDFlocalNode;
- mpiSetSizeBeginArguments.globalNode = HDFmyNode;
- /* mpiSetSizeBeginArguments.fileID = (long) (&fh); */
- mpiSetSizeBeginArguments.fileID = myHDFid;
-
- mpiSetSizeBeginArguments.fileSize = (long) size;
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiSetSizeBeginID,
- (char *) &mpiSetSizeBeginArguments,
- sizeof( mpiSetSizeBeginArguments ) );
-
- returnVal = MPI_File_set_size( fh, size );
-
- mpiSetSizeEndArguments.localNode = HDFlocalNode;
- mpiSetSizeEndArguments.globalNode = HDFmyNode;
- mpiSetSizeEndArguments.fileID = myHDFid;
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiSetSizeEndID,
- (char *) &mpiSetSizeEndArguments,
- sizeof( mpiSetSizeEndArguments ) );
-
- return returnVal;
-}
-
-int
-PabloMPI_File_get_size( MPI_File fh, MPI_Offset *size )
-{
- int returnVal;
-
- struct mpiGetSizeBeginArgs mpiGetSizeBeginArguments;
- struct mpiGetSizeEndArgs mpiGetSizeEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "MPI_File_get_size\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- mpiGetSizeBeginArguments.localNode = HDFlocalNode;
- mpiGetSizeBeginArguments.globalNode = HDFmyNode;
- /* mpiGetSizeBeginArguments.fileID = (long) (&fh); */
- mpiGetSizeBeginArguments.fileID = myHDFid;
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiGetSizeBeginID,
- (char *) &mpiGetSizeBeginArguments,
- sizeof( mpiGetSizeBeginArguments ) );
-
- returnVal = MPI_File_get_size( fh, size);
-
- mpiGetSizeEndArguments.localNode = HDFlocalNode;
- mpiGetSizeEndArguments.globalNode = HDFmyNode;
- /* mpiGetSizeEndArguments.fileID = (long) ( &fh ); */
- mpiGetSizeEndArguments.fileID = myHDFid;
-
- mpiGetSizeEndArguments.fileSize = (long) (*size);
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiGetSizeEndID,
- (char *) &mpiGetSizeEndArguments,
- sizeof( mpiGetSizeEndArguments ) );
-
- return returnVal;
-}
-
-int
-PabloMPI_File_set_view( MPI_File fh,
- MPI_Offset disp,
- MPI_Datatype etype,
- MPI_Datatype filetype,
- char *datarep,
- MPI_Info info )
-{
- int returnVal;
-
- struct mpiSetViewBeginArgs mpiSetViewBeginArguments;
- struct mpiSetViewEndArgs mpiSetViewEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "MPI_File_set_view\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- mpiSetViewBeginArguments.localNode = HDFlocalNode;
- mpiSetViewBeginArguments.globalNode = HDFmyNode;
- /* mpiSetViewBeginArguments.fileID = (long) ( &fh ); */
- mpiSetViewBeginArguments.fileID = myHDFid;
-
- mpiSetViewBeginArguments.disp = (long) ( disp );
- mpiSetViewBeginArguments.etype = HDF_get_Datatype( etype );
- mpiSetViewBeginArguments.fileType = HDF_get_Datatype( filetype );
- mpiSetViewBeginArguments.dataRep = HDF_get_DataRep( datarep );
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiSetViewBeginID,
- (char *) &mpiSetViewBeginArguments,
- sizeof( mpiSetViewBeginArguments ) );
-
- returnVal = MPI_File_set_view( fh,
- disp,
- etype,
- filetype,
- datarep,
- info );
-
- mpiSetViewEndArguments.localNode = HDFlocalNode;
- mpiSetViewEndArguments.globalNode = HDFmyNode;
- /* mpiSetViewEndArguments.fileID = (long) ( &fh ); */
- mpiSetViewEndArguments.fileID = myHDFid;
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiSetViewEndID,
- (char *) &mpiSetViewEndArguments,
- sizeof( mpiSetViewEndArguments ) );
-
- return returnVal;
-}
-
-int
-PabloMPI_File_get_view( MPI_File fh,
- MPI_Offset *disp,
- MPI_Datatype *etype,
- MPI_Datatype *filetype,
- char *datarep )
-{
- int returnVal;
-
- struct mpiGetViewBeginArgs mpiGetViewBeginArguments;
- struct mpiGetViewEndArgs mpiGetViewEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "MPI_File_get_view\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- mpiGetViewBeginArguments.localNode = HDFlocalNode;
- mpiGetViewBeginArguments.globalNode = HDFmyNode;
- mpiGetViewBeginArguments.fileID = myHDFid;
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiGetViewBeginID,
- (char *) &mpiGetViewBeginArguments,
- sizeof( mpiGetViewBeginArguments ) );
-
- returnVal = MPI_File_get_view( fh, disp, etype, filetype, datarep );
-
- mpiGetViewEndArguments.localNode = HDFlocalNode;
- mpiGetViewEndArguments.globalNode = HDFmyNode;
- /* mpiGetViewEndArguments.fileID = (long) ( &fh ); */
- mpiGetViewEndArguments.fileID = myHDFid;
-
- mpiGetViewEndArguments.disp = (long) ( *disp );
- mpiGetViewEndArguments.etype = HDF_get_Datatype( *etype );
- mpiGetViewEndArguments.fileType = HDF_get_Datatype( *filetype );
- mpiGetViewEndArguments.dataRep = HDF_get_DataRep( datarep );
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiGetViewEndID,
- (char *) &mpiGetViewEndArguments,
- sizeof( mpiGetViewEndArguments ) );
-
- return returnVal;
-}
-
-int
-PabloMPI_File_read_at( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status )
-{
- int returnVal, bcount;
-
- struct mpiReadAtBeginArgs mpiReadAtBeginArguments;
- struct mpiReadAtEndArgs mpiReadAtEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "MPI_File_read_at\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- mpiReadAtBeginArguments.localNode = HDFlocalNode;
- mpiReadAtBeginArguments.globalNode = HDFmyNode;
- /* mpiReadAtBeginArguments.fileID = (long) ( &fh ); */
- mpiReadAtBeginArguments.fileID = myHDFid;
-
- mpiReadAtBeginArguments.offset = (long) ( offset );
- mpiReadAtBeginArguments.count = count;
- mpiReadAtBeginArguments.dataType = HDF_get_Datatype( datatype );
- mpiReadAtBeginArguments.numBytes = HDF_get_Bytes( datatype, count );
-
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiReadAtBeginID,
- (char *) &mpiReadAtBeginArguments,
- sizeof( mpiReadAtBeginArguments ) );
-
- returnVal = MPI_File_read_at( fh, offset, buf, count, datatype, status );
-
- mpiReadAtEndArguments.localNode = HDFlocalNode;
- mpiReadAtEndArguments.globalNode = HDFmyNode;
- /* mpiReadAtEndArguments.fileID = (long) ( &fh ); */
- mpiReadAtEndArguments.fileID = myHDFid;
-
- MPI_Get_count( status, datatype, &bcount );
- if ( bcount < 0 || bcount > count )
- {
- mpiReadAtEndArguments.rCount = -1;
- mpiReadAtEndArguments.numBytes = -1;
- }
- else
- {
- mpiReadAtEndArguments.rCount = bcount;
- mpiReadAtEndArguments.numBytes = HDF_get_Bytes( datatype, bcount );
- }
- /* Generate entry record */
- HDFtraceIOEvent( mpiReadAtEndID,
- (char *) &mpiReadAtEndArguments,
- sizeof( mpiReadAtEndArguments ) );
-
- return returnVal;
-}
-
-int
-PabloMPI_File_read_at_all( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status )
-{
- int returnVal, bcount;
-
- struct mpiReadAtAllBeginArgs mpiReadAtAllBeginArguments;
- struct mpiReadAtAllEndArgs mpiReadAtAllEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "MPI_File_read_at_all\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- mpiReadAtAllBeginArguments.localNode = HDFlocalNode;
- mpiReadAtAllBeginArguments.globalNode = HDFmyNode;
- /* mpiReadAtAllBeginArguments.fileID = (long) ( &fh ); */
- mpiReadAtAllBeginArguments.fileID = myHDFid;
-
- mpiReadAtAllBeginArguments.offset = (long) ( offset );
- mpiReadAtAllBeginArguments.count = count;
- mpiReadAtAllBeginArguments.dataType = HDF_get_Datatype( datatype );
- mpiReadAtAllBeginArguments.numBytes = HDF_get_Bytes( datatype, count );
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiReadAtAllBeginID,
- (char *) &mpiReadAtAllBeginArguments,
- sizeof( mpiReadAtAllBeginArguments ) );
-
- returnVal = MPI_File_read_at_all( fh,
- offset,
- buf,
- count,
- datatype,
- status );
-
- mpiReadAtAllEndArguments.localNode = HDFlocalNode;
- mpiReadAtAllEndArguments.globalNode = HDFmyNode;
- /* mpiReadAtAllEndArguments.fileID = (long) ( &fh ); */
- mpiReadAtAllEndArguments.fileID = myHDFid;
-
- MPI_Get_count( status, datatype, &bcount );
- if ( bcount < 0 || bcount > count )
- {
- mpiReadAtAllEndArguments.rCount = -1;
- mpiReadAtAllEndArguments.numBytes = -1;
- }
- else
- {
- mpiReadAtAllEndArguments.rCount = bcount;
- mpiReadAtAllEndArguments.numBytes = HDF_get_Bytes( datatype, bcount );
- }
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiReadAtAllEndID,
- (char *) &mpiReadAtAllEndArguments,
- sizeof( mpiReadAtAllEndArguments ) );
-
- return returnVal;
-}
-
-int
-PabloMPI_File_write_at( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status )
-{
- int returnVal, bcount;
-
- struct mpiWriteAtBeginArgs mpiWriteAtBeginArguments;
- struct mpiWriteAtEndArgs mpiWriteAtEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "MPI_File_write_at\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- mpiWriteAtBeginArguments.localNode = HDFlocalNode;
- mpiWriteAtBeginArguments.globalNode = HDFmyNode;
- /* mpiWriteAtBeginArguments.fileID = (long) ( &fh ); */
- mpiWriteAtBeginArguments.fileID = myHDFid;
-
- mpiWriteAtBeginArguments.offset = (long) ( offset );
- mpiWriteAtBeginArguments.count = count;
- mpiWriteAtBeginArguments.dataType = HDF_get_Datatype( datatype );
- mpiWriteAtBeginArguments.numBytes = HDF_get_Bytes( datatype, count );
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiWriteAtBeginID,
- (char *) &mpiWriteAtBeginArguments,
- sizeof( mpiWriteAtBeginArguments ) );
-
- returnVal = MPI_File_write_at( fh,
- offset,
- buf,
- count,
- datatype,
- status );
-
- mpiWriteAtEndArguments.localNode = HDFlocalNode;
- mpiWriteAtEndArguments.globalNode = HDFmyNode;
- /* mpiWriteAtEndArguments.fileID = (long) ( &fh ); */
- mpiWriteAtEndArguments.fileID = myHDFid;
-
- MPI_Get_count( status, datatype, &bcount );
- mpiWriteAtEndArguments.wCount = bcount;
- mpiWriteAtEndArguments.numBytes = HDF_get_Bytes( datatype, bcount );
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiWriteAtEndID,
- (char *) &mpiWriteAtEndArguments,
- sizeof( mpiWriteAtEndArguments ) );
-
- return returnVal;
-}
-
-int
-PabloMPI_File_write_at_all( MPI_File fh,
- MPI_Offset offset,
- void *buf,
- int count,
- MPI_Datatype datatype,
- MPI_Status *status )
-{
- int returnVal, bcount;
- int numBytes;
-
- struct mpiWriteAtAllBeginArgs mpiWriteAtAllBeginArguments;
- struct mpiWriteAtAllEndArgs mpiWriteAtAllEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "MPI_File_write_at\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- mpiWriteAtAllBeginArguments.localNode = HDFlocalNode;
- mpiWriteAtAllBeginArguments.globalNode = HDFmyNode;
- /* mpiWriteAtAllBeginArguments.fileID = (long) ( &fh ); */
- mpiWriteAtAllBeginArguments.fileID = myHDFid;
-
- mpiWriteAtAllBeginArguments.offset = (long) ( offset );
- mpiWriteAtAllBeginArguments.count = count;
- mpiWriteAtAllBeginArguments.dataType = HDF_get_Datatype( datatype );
- mpiWriteAtAllBeginArguments.numBytes = HDF_get_Bytes( datatype, count );
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiWriteAtAllBeginID,
- (char *) &mpiWriteAtAllBeginArguments,
- sizeof( mpiWriteAtAllBeginArguments ) );
-
- returnVal = MPI_File_write_at_all( fh,
- offset,
- buf,
- count,
- datatype,
- status );
-
- mpiWriteAtAllEndArguments.localNode = HDFlocalNode;
- mpiWriteAtAllEndArguments.globalNode = HDFmyNode;
- mpiWriteAtAllEndArguments.fileID = myHDFid;
-
- if ( returnVal == MPI_SUCCESS )
- {
- bcount = count;
- numBytes = HDF_get_Bytes( datatype, count );
- }
- else
- {
- bcount = -1;
- numBytes = -1;
- }
- mpiWriteAtAllEndArguments.wCount = bcount;
- mpiWriteAtAllEndArguments.numBytes = numBytes;
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiWriteAtAllEndID,
- (char *) &mpiWriteAtAllEndArguments,
- sizeof( mpiWriteAtAllEndArguments ) );
-
- return returnVal;
-}
-
-int
-PabloMPI_File_sync( MPI_File fh )
-{
- int returnVal;
-
- struct mpiSyncBeginArgs mpiSyncBeginArguments;
- struct mpiSyncEndArgs mpiSyncEndArguments;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "MPI_File_sync\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- mpiSyncBeginArguments.localNode = HDFlocalNode;
- mpiSyncBeginArguments.globalNode = HDFmyNode;
- /* mpiSyncBeginArguments.fileID = (long) ( &fh ); */
- mpiSyncBeginArguments.fileID = myHDFid;
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiSyncBeginID,
- (char *) &mpiSyncBeginArguments,
- sizeof( mpiSyncBeginArguments ) );
-
- returnVal = MPI_File_sync ( fh );
-
- mpiSyncEndArguments.localNode = HDFlocalNode;
- mpiSyncEndArguments.globalNode = HDFmyNode;
- /* mpiSyncEndArguments.fileID = (long) ( &fh ); */
- mpiSyncEndArguments.fileID = myHDFid;
-
- /* Generate entry record */
- HDFtraceIOEvent( mpiSyncEndID,
- (char *) &mpiSyncEndArguments,
- sizeof( mpiSyncEndArguments ) );
-
- return returnVal;
-}
-#endif /* _BUILD */
-#else /* H5_HAVE_PARALLEL */
-void HDF_get_NodeNum( int* nodeNum )
-{
- *nodeNum = 0;
-}
-#endif /* H5_HAVE_PARALLEL */
diff --git a/pablo/PabloHDF_RT.c b/pablo/PabloHDF_RT.c
deleted file mode 100644
index c71f6e8..0000000
--- a/pablo/PabloHDF_RT.c
+++ /dev/null
@@ -1,1686 +0,0 @@
-/* This file is part of the Pablo Performance Analysis Environment
-//
-// (R)
-// The Pablo Performance Analysis Environment software is NOT in
-// the public domain. However, it is freely available without fee for
-// education, research, and non-profit purposes. By obtaining copies
-// of this and other files that comprise the Pablo Performance Analysis
-// Environment, you, the Licensee, agree to abide by the following
-// conditions and understandings with respect to the copyrighted software:
-//
-// 1. The software is copyrighted in the name of the Board of Trustees
-// of the University of Illinois (UI), and ownership of the software
-// remains with the UI.
-//
-// 2. Permission to use, copy, and modify this software and its documentation
-// for education, research, and non-profit purposes is hereby granted
-// to Licensee, provided that the copyright notice, the original author's
-// names and unit identification, and this permission notice appear on
-// all such copies, and that no charge be made for such copies. Any
-// entity desiring permission to incorporate this software into commercial
-// products should contact:
-//
-// Professor Daniel A. Reed reed@cs.uiuc.edu
-// University of Illinois
-// Department of Computer Science
-// 2413 Digital Computer Laboratory
-// 1304 West Springfield Avenue
-// Urbana, Illinois 61801
-// USA
-//
-// 3. Licensee may not use the name, logo, or any other symbol of the UI
-// nor the names of any of its employees nor any adaptation thereof in
-// advertizing or publicity pertaining to the software without specific
-// prior written approval of the UI.
-//
-// 4. THE UI MAKES NO REPRESENTATIONS ABOUT THE SUITABILITY OF THE
-// SOFTWARE FOR ANY PURPOSE. IT IS PROVIDED "AS IS" WITHOUT EXPRESS
-// OR IMPLIED WARRANTY.
-//
-// 5. The UI shall not be liable for any damages suffered by Licensee from
-// the use of this software.
-//
-// 6. The software was developed under agreements between the UI and the
-// Federal Government which entitle the Government to certain rights.
-//
-// *************************************************************************
-//
-// Developed by: The Pablo Research Group
-// University of Illinois at Urbana-Champaign
-// Department of Computer Science
-// 1304 W. Springfield Avenue
-// Urbana, IL 61801
-//
-// http://www-pablo.cs.uiuc.edu
-//
-// Send comments to: pablo-feedback@guitar.cs.uiuc.edu
-//
-// Copyright (c) 1987-1998
-// The University of Illinois Board of Trustees.
-// All Rights Reserved.
-//
-// PABLO is a registered trademark of
-// The Board of Trustees of the University of Illinois
-// registered in the U.S. Patent and Trademark Office.
-//
-// Project Manager and Principal Investigator:
-// Daniel A. Reed (reed@cs.uiuc.edu)
-//
-// Funded in part by the Defense Advanced Research Projects Agency
-// under DARPA contracts DABT63-94-C0049 (SIO Initiative),
-// F30602-96-C-0161, and DABT63-96-C-0027 by the National Science
-// Foundation under the PACI program and grants NSF CDA 94-01124 and
-// ASC 97-20202, and by the Department of Energy under contracts
-// DOE B-341494, W-7405-ENG-48, and 1-B-333164.
-*/
-/*======================================================================*
-// File: PabloHDF_RT *
-// Purpose: support use of Pablo trace library to analyze HDF *
-// performance *
-// Contents: *
-// HDFinitTrace_RT : initialize real-time tracing *
-// HDFendTrace_RT : complete trace *
-// initHDFProcTrace_RT : sets up data structures at init time. *
-// initproctracert_() : fortran interface *
-// HDFtraceEvent_RT : called to record event information *
-// HDFrecordSum : adds fields of one record to those of *
-// another *
-// HDFnodeInit : initializes linked list node *
-// HDFrecordFileName : records named HDF identifiers *
-// BeginIOEventRecord : initialize before I/O call *
-// EndIOEventRecord : finalize after I/O call *
-// BeginMPIOEventRecord : initialize before MPI-I/O call *
-// EndMPIOEventRecord : finalize after MPI-I/O call *
-// BeginHDFEventRecord : initialize before HDF call *
-// EndHDFEventRecord : finalizie after HDF call *
-// HDFrecordFileName : record named identifier information *
-// HDFassignPabloIDs : assigns a number to named identifiers *
-// writeHDFNamePacketsRT : write SDDF packets for identifier names *
-// HDFupdateProcLists : adds records in queue to entries in *
-// tables *
-// HDFupdateProcs : called by HDFupdateProcLists to do *
-// addition *
-// HDFSummarySDDF : write SDDF event summary packets *
-// HDFnodeInit : initialize event node *
-// HDFrecordSum : add one event record to another *
-// getHDFFieldIndex : get Field Index for counts and times *
-// getHDFByteFieldIndex : get field index for bytes *
-// writeHDFRecDescrptrsRT : write HDF Record Descriptor packets *
-// printFileMappingsRT : print map of named identifiers *
-// _hdfNameDescriptor() : writes SDDF descriptor packet for names *
-//======================================================================*/
-#ifndef PCF_BUILD
-#ifdef _HDF5_
-#include "H5config.h"
-#endif
-#include "SystemDepend.h"
-#include "Trace.h"
-#include "TraceParam.h"
-#include "ProcIDs.h"
-#include "IO_TraceParams.h"
-#include "IOTrace.h"
-#include "HDFTrace.h"
-#include "SDDFparam.h"
-#include <string.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <fcntl.h>
-/*======================================================================*
-// on ipsc/860 don't include this or you'll get multiply defined SEEK_ *
-//======================================================================*/
-#ifndef __NX
-#include <unistd.h>
-#endif
-
-#ifndef SUCCESS
-#define SUCCESS 0
-#define FAILURE 1
-#endif
-
-#ifndef TRUE
-#define TRUE 1
-#define FALSE 0
-#endif
-#define NEG_THREAD_ID -999
-
-#include "HDFrecord_RT.h"
-
-#ifdef H5_HAVE_MPIOTRACE
-#include "mpi.h"
-#include "MPIO_EventArgs.h"
-#endif
-
-#ifndef TRgetThreadID
-#define TRgetThreadID TRgetNode
-#endif
-
-#ifndef TRnumNodes
-#define TRnumNodes 1
-#endif
-
-#define AllThreads -1
-
-/*======================================================================*
-// User output file pointer. *
-//======================================================================*/
-FILE *outP;
-/*======================================================================*
-// Data Structures: *
-// *
-// HDFQueues: an array of linked list. Each list corresponds to an *
-// HDF event and contains an entry for each different *
-// thread and data set referenced by a call to that event *
-// *
-// CallStack: a stack of HDFnode_t objects. At any given time, the *
-// stack represents the calling stack of the HDF routines *
-// *
-// HDFfileList: a linked list of named identifiers and identifier *
-// numbers. This is processed later to assign a single *
-// numbers to identifiers with the same name. *
-//======================================================================*/
-HDFnode_t **HDFQueues;
-HDFnode_t *CallStack;
-HDFnode_t *TagQueue;
-fileRec_t *HDFfileList;
-/*======================================================================*
-// Internal Function prototypes *
-//======================================================================*/
-void HDFinitTrace_RT( char *, int, int );
-void HDFendTrace_RT();
-int initproctracert_( void );
-int initHDFProcTrace_RT( void );
-void HDFtraceEvent_RT( int , char *, unsigned ) ;
-void BeginIOEventRecord ( int, CLOCK , void * );
-void EndIOEventRecord ( int , CLOCK , void * );
-void BeginMPIOEventRecord ( int, CLOCK , void *, int );
-void EndMPIOEventRecord ( int , CLOCK , void *, int);
-void BeginHDFEventRecord( int , CLOCK );
-void EndHDFEventRecord ( CLOCK ,void *);
-void HDFrecordFileName( HDFsetInfo * );
-void HDFassignPabloIDs( int *, char *** );
-void writeHDFNamePacketsRT( char **, int );
-void HDFupdateProcLists( void );
-void HDFupdateProcs( HDFnode_t * );
-void HDFSummarySDDF( HDFnode_t *, int );
-void HDFnodeInit ( HDFnode_t * ) ;
-void HDFrecordSum ( HDFrec_t *, HDFrec_t * );
-int getHDFFieldIndex( int );
-int getHDFByteFieldIndex( int );
-void writeHDFRecDescrptrsRT( void );
-void printFileMappingsRT( char *, char **, int );
-void _hdfNameDescriptor( void );
-void _hdfDescriptorRT( char *, char *, int );
-void HDFfinalTimeStamp( void );
-void getHDFprocName( int index, char buff[41] );
-void IOtraceInit( char*, int, int );
-/*======================================================================*
-// Global variables *
-//======================================================================*/
-HDFnode_t InitNode; /* Node used in initialization */
-HDFrec_t Tally; /* Node used to get total */
-char *FileName; /* Name of Trace file */
-HDFsetInfo openInfo; /* Info about file opened */
-char openName[256]; /* Name of opened file */
-extern char *hdfRecordPointer;
-extern char HDFprocNames[][40];
-/*======================================================================*
-// NAME *
-// HDFinitTrace_RT-- initialize HDF real-time tracing *
-// USAGE *
-// VOID HDFinitTrace_RT( fileName ) *
-// *
-// char *fileName; IN: name of output file *
-// RETURNS *
-// None. *
-//======================================================================*/
-void HDFinitTrace_RT( char *fileName, int procNum, int OUTSW )
-{
- int error;
- TRgetClock( &epoch );
- error = initHDFProcTrace_RT() ;
- if ( error != SUCCESS )
- {
- fprintf (stderr,"Unable to Initialize properly. Exiting program\n");
- exit(-1);
- }
- FileName = ( char * ) malloc ( strlen( fileName ) + 10 );
- /*===================================================================*
- // Here the library was built to linked with the MPI and MPIO *
- // libraries. However, the use may chose not to run with MPI. *
- // A check is made to see if MPI has been initialized. If so, *
- // a trace file is assigned to the current node with the number *
- // of the node as a suffix; if not, only one file is opened *
- // and it is not given a suffix. *
- //===================================================================*/
- IOtraceInit( fileName, procNum, OUTSW );
-}
-/*======================================================================*
-// NAME *
-// HDFendTrace-- end HDF tracing *
-// USAGE *
-// VOID HDFendTrace_RT(void) *
-// RETURNS *
-// None. *
-//======================================================================*/
-void HDFendTrace_RT( )
-{
- int j, numSetIDs;
- HDFnode_t *P;
- char **Names;
-
- HDFfinalTimeStamp();
- /*===================================================================*
- // Assing pablo ids to named identifiers and tag records *
- //===================================================================*/
- HDFassignPabloIDs( &numSetIDs, &Names );
- /*===================================================================*
- // Create a file name for the File map file. *
- // Disable for now. *
- //===================================================================*/
-/* mapFile = (char *)malloc( strlen(FileName) + 4 );
- strcpy(mapFile,FileName);
- strcat(mapFile,".map"); */
- /*===================================================================*
- // print the file mappings. *
- //===================================================================*/
-/* printFileMappingsRT( mapFile, Names, numSetIDs ); */
- /*===================================================================*
- // Print SDDF summary records *
- //===================================================================*/
- writeHDFRecDescrptrsRT();
- writeHDFNamePacketsRT( Names, numSetIDs );
- for ( j = 0; j < NumHDFProcs; ++j ) {
- HDFSummarySDDF( HDFQueues[j], j );
- }
- endTracing();
-}
-/*======================================================================*
-// initHFDProcTrace_RT *
-// This function initializes data structures specific to *
-// the HDF real-time procedure entry/exit tracing extensions of *
-// the Pablo instrumentation library. *
-//======================================================================*/
-int initproctracert_( void )
-
-{
- return initHDFProcTrace_RT();
-}
-
-int initHDFProcTrace_RT( void )
-{
- int i;
- int j;
- int size;
- int numProcs = NumHDFProcs;
-
- if ( traceProcessorNumber == -1 )
- {
- traceProcessorNumber = TRgetDefaultProcessor();
- }
- /*===================================================================*
- // Initialize InitNode used for node initialization. *
- //===================================================================*/
- InitNode.ptr = NULL;
- InitNode.eventID = 0;
- InitNode.lastIOtime = zeroClock;
- InitNode.record.nCalls = 0;
- InitNode.record.lastCall = zeroClock;
- InitNode.record.incDur = zeroClock;
- InitNode.record.excDur = zeroClock;
- InitNode.record.hdfID = 0;
- InitNode.record.xRef = 0;
- for ( j = 0; j < nTallyFields; ++j )
- {
- InitNode.record.times[j] = zeroClock;
- }
- for ( j = 0; j < nTallyFields; ++j )
- {
- InitNode.record.counts[j] = 0;
- }
- for ( j = 0; j < nByteFields; ++j )
- {
- InitNode.record.bytes[j] = 0;
- }
- for ( i = 0; i < nByteFields; ++i )
- {
- for ( j = 0; j < nBkts; ++j )
- {
- InitNode.record.Hists[i][j] = 0;
- }
- }
- /*===================================================================*
- // initialize linked list used to keep track of named hdf *
- // identifiers. *
- //===================================================================*/
- HDFfileList = NULL;
- /*===================================================================*
- // Allocate a one dimensional array of pointers to queues of *
- // HDFnodes. There is one queue for each thread and one for *
- // each HDF procedure. Each queue will be a list of summary *
- // records distinquished by file type and *
- //===================================================================*/
- size = (int)(numProcs*sizeof( HDFnode_t * ));
- HDFQueues = (HDFnode_t **)malloc( size );
- if ( HDFQueues == NULL )
- {
- fprintf(stderr,"Failed to allocate HDFQueues in initHDFProcTrace\n");
- return FAILURE;
- }
- for ( j = 0; j < numProcs; ++j )
- {
- HDFQueues[j] = NULL;
- }
- /*===================================================================*
- // Initialize call stack to a dummy node and TagQueue to NULL *
- //===================================================================*/
- CallStack = (HDFnode_t *)malloc( sizeof(HDFnode_t) );
- *CallStack = InitNode;
- TagQueue = NULL ;
- return SUCCESS;
-}
-/*======================================================================*
-// This is called from the HDF and I/O routines when real-time summary *
-// tracing is used. It sets up a call stack for the specific thread in *
-// use if no stack is yet set up. It then calls calls a routine to *
-// handle the event based on whether it is an I/O or HDF call. *
-//======================================================================*/
-void HDFtraceEvent_RT( int eventType, char *dataPtr, unsigned dataLen )
-{
- CLOCK seconds;
-
- seconds = getClock();
-
- if ( isBeginIOEvent ( eventType ) || eventType == ID_malloc )
- {
- BeginIOEventRecord ( eventType, seconds, dataPtr ) ;
- }
- else if ( isEndIOEvent( eventType ) || eventType == -ID_malloc)
- {
- EndIOEventRecord ( eventType, seconds, dataPtr );
- }
- else if ( isBeginHDFEvent( eventType ) )
- {
- BeginHDFEventRecord ( eventType , seconds ) ;
- }
- else if ( isEndHDFEvent( eventType ) )
- {
- EndHDFEventRecord ( seconds, dataPtr );
-#ifdef H5_HAVE_MPIOTRACE
- }
- else if ( isBeginMPIOEvent( eventType ) )
- {
- BeginMPIOEventRecord ( eventType, seconds, dataPtr, dataLen ) ;
- }
- else if ( isEndMPIOEvent( eventType ) )
- {
- EndMPIOEventRecord ( eventType, seconds, dataPtr, dataLen );
-#endif /* H5_HAVE_MPIOTRACE */
- }
- else
- {
- fprintf(stderr,"eventType %d, dataLen = %u\n",eventType,dataLen);
- }
-}
-/*======================================================================*
-// BeginIOEventRecord: *
-// This routine simply records the time in the record on the top of *
-// the stack. *
-//======================================================================*/
-void BeginIOEventRecord ( int eventType, CLOCK seconds, void *dataPtr )
-{
- char *name;
- /*===================================================================*
- // save the time value temporarily in top of stack *
- // When the end record is received, the duration can be computed. *
- //===================================================================*/
- CallStack->lastIOtime = seconds;
- /*===================================================================*
- // get the ID or name of the file accessed from the structure *
- // passed as dataPtr. *
- //===================================================================*/
- switch ( eventType )
- {
- case fopenBeginID:
- case openBeginID:
- {
- name = (char *)(dataPtr) + 2*sizeof(int);
- strcpy( openName, name );
- break;
- }
- case fcloseBeginID:
- case closeBeginID:
- {
- CallStack->record.hdfID = *( long *)dataPtr;
- break;
- }
- case readBeginID:
- case freadBeginID:
- case writeBeginID:
- case fwriteBeginID:
- case lseekBeginID:
- case fseekBeginID:
- case fsetposBeginID:
- case rewindBeginID:
- {
- CallStack->record.hdfID = *(int *)dataPtr;
- break;
- }
- default:
- {
- break;
- }
- }
-}
-/*======================================================================*
-// EndIOEventRecord: *
-// This routine retrieves the entry time saved on the top of the stack *
-// and computes the duration of the I/O event. This is added to the *
-// record field corresponding to this type of I/O. The Bytes field in *
-// the record is updated if this is a read or write operation. *
-//======================================================================*/
-void EndIOEventRecord ( int eventType, CLOCK secs, void *dataPtr )
-{
- CLOCK incDur;
- int i, Field, ByteField, bytes;
-
- incDur = clockSubtract(secs,CallStack->lastIOtime) ;
- Field = getHDFFieldIndex( eventType ) ;
- CallStack->record.times[Field]
- = clockAdd ( CallStack->record.times[Field] , incDur ) ;
- ++CallStack->record.counts[Field];
- ByteField = getHDFByteFieldIndex( Field ) ;
- switch ( eventType )
- {
- case readEndID:
- case freadEndID:
- case writeEndID:
- case fwriteEndID:
- case -ID_malloc:
- {
- bytes = *((int *)dataPtr);
- CallStack->record.bytes[ByteField] += bytes;
- /*======================================================
- // update histogram *
- //=====================================================*/
- i = -1;
- while ( bytes >= BktLim[i+1] ) ++i ;
- if ( i >= 0 ) ++CallStack->record.Hists[ByteField][i];
- break;
- }
- case fopenEndID:
- case openEndID:
- {
- openInfo.setName = openName;
- openInfo.setID = (int)(*((long *)dataPtr));
- CallStack->record.hdfID = openInfo.setID;
- HDFrecordFileName ( &openInfo );
- break;
- }
- default:
- {
- break;
- }
- }
-
-}
-#ifdef H5_HAVE_MPIOTRACE
-/*======================================================================*
-// BeginMPIOEventRecord: *
-// This routine simply records the time in the record on the top of *
-// the stack. *
-//======================================================================*/
-void BeginMPIOEventRecord( int eventType,
- CLOCK seconds,
- void *data,
- int dataLen )
-{
- HDFsetInfo *dataPtr;
- dataPtr = (HDFsetInfo *)data;
- /*===================================================================*
- // save the time value temporarily in top of stack *
- // When the end record is received, the duration can be *
- // computed. *
- //===================================================================*/
- CallStack->lastIOtime = seconds;
- /*===================================================================*
- // get useful info from the structure pointed to by dataPtr. *
- // Form most cases, this is the file ID. For mpiOpen, it is the *
- // name of the file. For mpiDelete, no information is of any *
- // use. *
- //===================================================================*/
- if ( dataLen == 0 ) return;
- CallStack->record.hdfID = dataPtr->setID;
- switch ( eventType )
- {
- case HDFmpiOpenID:
- {
- strcpy( openName, dataPtr->setName );
- break;
- }
- case HDFmpiReadAtID:
- {
- CallStack->record.bytes[MPIOreadBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiReadAtAllID:
- {
- CallStack->record.bytes[MPIOreadAllBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiWriteAtID:
- {
- CallStack->record.bytes[MPIOwriteBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiWriteAtAllID:
- {
- CallStack->record.bytes[MPIOwriteAllBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiIreadAtID:
- {
- CallStack->record.bytes[MPIOiReadBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiIwriteAtID:
- {
- CallStack->record.bytes[MPIOiWriteBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiReadID:
- {
- CallStack->record.bytes[MPIOreadBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiReadAllID:
- {
- CallStack->record.bytes[MPIOreadAllBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiWriteID:
- {
- CallStack->record.bytes[MPIOwriteBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiWriteAllID:
- {
- CallStack->record.bytes[MPIOwriteAllBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiIreadID:
- {
- CallStack->record.bytes[MPIOiReadBytesReq] += dataPtr->numBytes;
- break;
- }
- case HDFmpiIwriteID:
- {
- CallStack->record.bytes[MPIOiWriteBytesReq] += dataPtr->numBytes;
- break;
- }
- default:
- {
- break;
- }
- }
-}
-/*======================================================================*
-// EndMPIOEventRecord: *
-// This routine retrieves the entry time saved on the top of the stack *
-// and computes the duration of the MPI-I/O event. This is added to *
-// the record field corresponding MPI-I/O. *
-//======================================================================*/
-void EndMPIOEventRecord ( int eventType,
- CLOCK secs,
- void *data,
- int dataLen )
-{
- CLOCK incDur;
-
- HDFsetInfo* dataPtr;
- incDur = clockSubtract(secs,CallStack->lastIOtime) ;
- CallStack->record.times[MPI]
- = clockAdd ( CallStack->record.times[MPI], incDur );
- ++CallStack->record.counts[MPI];
- if ( dataLen == 0 )
- {
- return;
- }
- dataPtr = (HDFsetInfo *)data;
- switch ( eventType )
- {
- case -HDFmpiOpenID:
- {
- /*===========================================================*
- // open and record the information. *
- //===========================================================*/
- openInfo.setName = openName;
- openInfo.setID = dataPtr->setID;
- CallStack->record.hdfID = openInfo.setID;
- HDFrecordFileName ( &openInfo );
- break;
- }
- case -HDFmpiReadAtID:
- {
- ++CallStack->record.counts[MPIOread] ;
- CallStack->record.times[MPIOread]
- = clockAdd ( CallStack->record.times[MPIOread], incDur );
- CallStack->record.bytes[MPIOreadBytesTrans] += dataPtr->numBytes;
- break;
- }
- case -HDFmpiReadAtAllID:
- {
- ++CallStack->record.counts[MPIOreadAll] ;
- CallStack->record.times[MPIOreadAll]
- = clockAdd ( CallStack->record.times[MPIOreadAll], incDur );
- CallStack->record.bytes[MPIOreadAllBytesTrans] += dataPtr->numBytes;
- break;
- }
- case -HDFmpiWriteAtID:
- {
- ++CallStack->record.counts[MPIOwrite] ;
- CallStack->record.times[MPIOwrite]
- = clockAdd ( CallStack->record.times[MPIOwrite], incDur );
- CallStack->record.bytes[MPIOwriteBytesTrans] += dataPtr->numBytes;
- break;
- }
- case -HDFmpiWriteAtAllID:
- {
- ++CallStack->record.counts[MPIOwriteAll] ;
- CallStack->record.times[MPIOwriteAll]
- = clockAdd ( CallStack->record.times[MPIOwriteAll], incDur );
- CallStack->record.bytes[MPIOwriteAllBytesTrans] += dataPtr->numBytes;
- break;
- }
- case -HDFmpiIreadAtID:
- {
- ++CallStack->record.counts[MPIOiRead] ;
- CallStack->record.times[MPIOiRead]
- = clockAdd ( CallStack->record.times[MPIOiRead], incDur );
- break;
- }
- case -HDFmpiIwriteAtID:
- {
- ++CallStack->record.counts[MPIOiWrite] ;
- CallStack->record.times[MPIOiWrite]
- = clockAdd ( CallStack->record.times[MPIOiWrite], incDur );
- break;
- }
- case -HDFmpiReadID:
- {
- ++CallStack->record.counts[MPIOread] ;
- CallStack->record.times[MPIOread]
- = clockAdd ( CallStack->record.times[MPIOread], incDur );
- CallStack->record.bytes[MPIOreadBytesTrans] += dataPtr->numBytes;
- break;
- }
- case -HDFmpiReadAllID:
- {
- ++CallStack->record.counts[MPIOreadAll] ;
- CallStack->record.times[MPIOreadAll]
- = clockAdd ( CallStack->record.times[MPIOreadAll], incDur );
- CallStack->record.bytes[MPIOreadAllBytesTrans] += dataPtr->numBytes;
- break;
- }
- case -HDFmpiWriteID:
- {
- ++CallStack->record.counts[MPIOwrite] ;
- CallStack->record.times[MPIOwrite]
- = clockAdd ( CallStack->record.times[MPIOwrite], incDur );
- CallStack->record.bytes[MPIOwriteBytesTrans] += dataPtr->numBytes;
- break;
- }
- case -HDFmpiWriteAllID:
- {
- ++CallStack->record.counts[MPIOwriteAll] ;
- CallStack->record.times[MPIOwriteAll]
- = clockAdd ( CallStack->record.times[MPIOwriteAll], incDur );
- CallStack->record.bytes[MPIOwriteAllBytesTrans] += dataPtr->numBytes;
- break;
- }
- case -HDFmpiIreadID:
- {
- ++CallStack->record.counts[MPIOiRead] ;
- CallStack->record.times[MPIOiRead]
- = clockAdd ( CallStack->record.times[MPIOiRead], incDur );
- break;
- }
- case -HDFmpiIwriteID:
- {
- ++CallStack->record.counts[MPIOiWrite] ;
- CallStack->record.times[MPIOiWrite]
- = clockAdd ( CallStack->record.times[MPIOiWrite], incDur );
- break;
- }
- default:
- {
- ++CallStack->record.counts[MPIOother] ;
- CallStack->record.times[MPIOother]
- = clockAdd ( CallStack->record.times[MPIOiWrite], incDur );
- break;
- }
- }
-}
-#endif /* H5_HAVE_MPIOTRACE */
-/*======================================================================*
-// BeginHDFEventRecord: *
-// This function puts a trace record on the stack corresponding to *
-// this thread. If no stack exists, one is created. If no record *
-// exist, a record is created. *
-//======================================================================*/
-void BeginHDFEventRecord( int eventID, CLOCK secs )
-{
- HDFnode_t *HDFrec;
- /*==============================================================*
- // Create a record. Push it onto the call stack. *
- //==============================================================*/
- HDFrec = (HDFnode_t *)malloc( sizeof(HDFnode_t) );
- HDFnodeInit( HDFrec ) ;
- HDFrec->eventID = eventID;
- HDFrec->ptr = CallStack;
- CallStack = HDFrec ;
- /*==============================================================*
- // save time stamp in record. *
- //==============================================================*/
- HDFrec->record.lastCall = secs;
-}
-/*======================================================================*
-// EndHDFEventRecord: *
-// This routine pops the HDF record from the top of the stack *
-// corresponding to this thread and computes the inclusive duration *
-// and adds it to the inclusive duration field of this record and to *
-// the HDF time field of the calling routines record. *
-//======================================================================*/
-void EndHDFEventRecord ( CLOCK secs, void *dataPtr )
-{
- HDFsetInfo *info;
- HDFnode_t *HDFrec;
- CLOCK incSecs;
- static int dummyIDs = -4;
- /*==============================================================*
- // pop record from top of the stack, compute inclusive duration *
- // and set the corresponding record field and increment nCalls. *
- //==============================================================*/
- HDFrec = CallStack;
- CallStack = CallStack->ptr;
- if ( CallStack == NULL ) {
- fprintf(stderr,">>> EndHDFEventRecord: Call Stack is empty. <<<\n");
- return;
- }
- incSecs = clockSubtract(secs,HDFrec->record.lastCall) ;
-
- HDFrec->record.incDur = incSecs;
- ++HDFrec->record.nCalls;
- /*==============================================================*
- // add old record to chain to have its xRef field tagged. *
- //==============================================================*/
- HDFrec->ptr = TagQueue;
- TagQueue = HDFrec;
- /*==============================================================*
- // Add set ID information. *
- //==============================================================*/
- if ( dataPtr != NULL ) {
- info = (HDFsetInfo *)dataPtr;
- if ( info->setName != NULL ) {
- if ( info->setID == 0 ) {
- info->setID = dummyIDs--;
- }
- HDFrecordFileName ( info );
- }
- HDFrec->record.hdfID = info->setID;
- }
- /*==============================================================*
- // Update the HDF totals for the calling program. *
- //==============================================================*/
- CallStack->record.times[ HDF_ ]
- = clockAdd( CallStack->record.times[ HDF_ ] , incSecs ) ;
- ++CallStack->record.counts[ HDF_ ] ;
- /*==============================================================*
- // If the stack has only one record it represents the main *
- // program. Tag all of the records on the TagQueue and tally *
- // them up. *
- //==============================================================*/
- if ( CallStack->ptr == NULL ) {
- HDFupdateProcLists( );
- }
-}
-/*======================================================================*
-// This routine keeps track of the identifier names and tags. Some *
-// names may be associated with more than one tag. This will be *
-// rectified when final tallies are done. *
-//======================================================================*/
-void HDFrecordFileName( HDFsetInfo *info )
-{
- fileRec_t *P;
- char *t;
- int match;
- long id;
- P = HDFfileList;
- match = FALSE;
- id = info->setID;
- while ( P != NULL && match == FALSE ) {
- if ( strcmp( P->fileName, info->setName ) != 0 && P->hdfID == id ) {
- match = TRUE;
- } else {
- P = P->ptr;
- }
- }
- if ( match == FALSE ) {
- P = ( fileRec_t *) malloc( sizeof( fileRec_t ) );
- P->ptr = HDFfileList;
- HDFfileList = P;
- t = (char *)malloc( strlen( info->setName ) + 1 );
- strcpy ( t, info->setName ) ;
- P->fileName = t;
- P->hdfID = info->setID;
- P->PabloID = 0;
- }
-}
-/*======================================================================*
-// This routine assigns a unique Pablo ID to each unique name *
-// regardless of the HDF tag. *
-// It then goes through the HDFRecordQueue and marks each record with *
-// the PabloID corresponding to the hdfID and xRef fields or 0. *
-//======================================================================*/
-void HDFassignPabloIDs( int *nSetIDs, char ***Names )
-{
- fileRec_t *F, *G;
- HDFnode_t *P;
- int j;
- long PabloID = 1;
- long hdfID, xRef;
- char *fName, **T;
-
- F = HDFfileList;
- /*==============================================================*
- // Assign the same ID to identical names. *
- //==============================================================*/
- while ( F != NULL ) {
- if ( F->PabloID == 0 ) {
- F->PabloID = PabloID++;
- fName = F->fileName;
- G = F->ptr;
- while ( G != NULL ) {
- if ( strcmp( G->fileName , fName ) == 0 ) {
- G->PabloID = F->PabloID;
- }
- G = G->ptr;
- }
- }
- F = F->ptr;
- }
- *nSetIDs = (int)(PabloID - 1);
- if ( *nSetIDs <= 0 ) return;
- /*==============================================================*
- // Repace hdfID and xRef fields with corresponding Pablo ID *
- //==============================================================*/
- for ( j = 0; j < NumHDFProcs; ++j ) {
- P = HDFQueues[j] ;
- while ( P != NULL ) {
- hdfID = P->record.hdfID;
- if ( hdfID != 0 ) {
- PabloID = 0;
- F = HDFfileList;
- while ( F != NULL && PabloID == 0 ) {
- if ( hdfID == F->hdfID ) {
- PabloID = F->PabloID;
- }
- F = F->ptr;
- }
- P->record.hdfID = PabloID;
- }
- xRef = P->record.xRef;
- if ( xRef != 0 ) {
- PabloID = 0;
- F = HDFfileList;
- while ( F != NULL && PabloID == 0 ) {
- if ( xRef == F->hdfID ) {
- PabloID = F->PabloID;
- }
- F = F->ptr;
- }
- P->record.xRef = PabloID;
- }
- P = P->ptr;
- } /* end while ( P != NULL ) */
- } /* end for */
- /*==============================================================*
- // get a list of all the unique names and order them according *
- // to their Pablo IDs. *
- //==============================================================*/
- T = ( char ** )malloc( (*nSetIDs+1) * sizeof( char * ) );
- for ( j = 0; j <= *nSetIDs; ++j ) {
- T[j] = NULL;
- }
- F = HDFfileList;
- while ( F != NULL ) {
- PabloID = F->PabloID ;
- if ( T[PabloID] == NULL ) {
- T[PabloID] = ( char * )malloc( strlen( F->fileName ) + 1 );
- strcpy( T[PabloID], F->fileName ) ;
- }
- free((void *)(F->fileName));
- G = F;
- F = F->ptr;
- free ( (void *)G );
- }
- *Names = T;
-}
-/*======================================================================*
-// This routine writes SDDF packets to SDDF file containing information *
-// about the named identifiers found in the program. *
-//======================================================================*/
-void writeHDFNamePacketsRT( char **Names, int numSetIDs )
-{
- int j;
- HDFNamePacket_t NamePkt;
- char *BUFF, *fName;
- int buffSize;
- /*==============================================================*
- // Allocate a buffer to hold the packet. Allow 80 chars for *
- // identifier name. *
- //==============================================================*/
- buffSize = sizeof(HDFNamePacket_t) + 80;
- BUFF = (char *)malloc(buffSize);
- /*==============================================================*
- // Fill in constant information *
- //==============================================================*/
- NamePkt.packetType = PKT_DATA;
- NamePkt.packetTag = FAMILY_NAME;
- /*==============================================================*
- // Fill in named identifier information and write to SDDF file *
- //==============================================================*/
- for ( j = 1; j <= numSetIDs; ++j ) {
- fName = Names[j];
- NamePkt.packetLength = (int)(sizeof(NamePkt) + strlen(fName));
- NamePkt.fileType = 0; /* not currently used */
- NamePkt.fileID = j;
- NamePkt.nameLen = (int)strlen(fName) ;
- if ( buffSize < NamePkt.packetLength ) {
- free((void *)BUFF) ;
- buffSize = NamePkt.packetLength + 80;
- BUFF = (char *)malloc( buffSize ) ;
- }
- /*===========================================================*
- // Copy packet data and tack on identifier name *
- //===========================================================*/
- memcpy( BUFF, &NamePkt, sizeof(NamePkt) );
- memcpy( BUFF + sizeof(NamePkt) , fName, strlen(fName) );
- putBytes( BUFF , NamePkt.packetLength ) ;
- }
- free((void *)BUFF);
-}
-/*======================================================================*
-// Tag xRef field of all records in this queue with the hdfID of the *
-// highest level caller. Also *
-// This routine takes the records after they have been tagged and adds *
-// their fields to the apporopriate position in the HDFQueues structure *
-//======================================================================*/
-void HDFupdateProcLists( void )
-{
- HDFnode_t *P, *Q;
- long hdfID;
-
- hdfID = TagQueue->record.hdfID;
- P = TagQueue;
- while ( P != NULL ) {
- P->record.xRef = hdfID;
- Q = P->ptr;
- HDFupdateProcs( P );
- P = Q;
- }
- TagQueue = NULL;
-}
-/*======================================================================*
-// This routine takes as input a node pointer P and looks for a Total *
-// record with this same eventID, hdfID and xRef. If such a record *
-// exists, P is added to the record, otherwise a record is created and *
-// its values are set to P's. *
-//======================================================================*/
-void HDFupdateProcs( HDFnode_t *P )
-{
- int procIndex, eventID;
- long hdfID, xRef;
- HDFnode_t *Q;
- eventID = P->eventID;
- procIndex = ProcIndexForHDFEntry( eventID );
- hdfID = P->record.hdfID;
- xRef = P->record.xRef;
- Q = HDFQueues[ procIndex ];
- /*==============================================================*
- // First determine if a tally node exists that matches the *
- // eventID, hdfID and xRef of P. *
- //==============================================================*/
- while ( Q != NULL &&
- (( Q->record.hdfID != hdfID ) || ( Q->record.xRef != xRef )) ) {
- Q = Q->ptr;
- }
- if ( Q == NULL ) {
- /*===========================================================*
- // No tally record matches the hdfID and xRef so put P in *
- // the queue. *
- //===========================================================*/
- P->ptr = HDFQueues[ procIndex ];
- HDFQueues[ procIndex ] = P;
- } else {
- /*===========================================================*
- // add P to the exiting record and free it. *
- //===========================================================*/
- HDFrecordSum ( &Q->record , &P->record );
- free((void *)P);
- }
-}
-/*======================================================================*
-// Print SDDF records for all records in this linked list. *
-//======================================================================*/
-void HDFSummarySDDF( HDFnode_t *P, int procIndex )
-{
- int i, j, arrayLen, nodeID, nCalls;
- int allIOCount;
- CLOCK allIOTime, excDur;
- double t;
- char buff[1024];
- char *Packet;
- HDFnode_t *Q;
- struct
- {
- int packetLen;
- int packetType;
- int packetTag;
- int eventID;
- double Seconds;
- double IncDur;
- double ExcDur;
- long HDFid;
- long XREFid;
- } Header;
-
- Header.packetLen = sizeof(Header)
- + sizeof(int) /* n Calls */
- + sizeof(int) /* array len */
- + nTallyFields*sizeof(double) /* times array */
- + sizeof(int) /* array len */
- + nTallyFields*sizeof(int) /* count array */
- + sizeof(int) /* array len */
- + nByteFields*sizeof(int) /* bytes array */
- + nHistFields*sizeof(int) /* array lens */
- + nHistFields*nBkts*sizeof(int) /* byte hist */
- + sizeof(int); /* nodeID */
- Header.packetTag = HDF_SUMMARY_FAMILY +
- ( procIndex + 1 )*8 + RECORD_TRACE ;
- Header.packetType = PKT_DATA;
- nodeID = TRgetNode();
- while ( P != NULL ) {
- Q = P->ptr;
- /*===========================================================*
- // Total the I/O time and counts *
- //===========================================================*/
- allIOTime = zeroClock;
- for ( j = FirstIO; j <= LastIO; ++j ) {
- allIOTime = clockAdd( allIOTime, P->record.times[j] );
- }
- P->record.times[AllIO] = allIOTime;
-
- allIOCount = 0;
- for ( j = FirstIO; j <= LastIO; ++j ) {
- allIOCount += P->record.counts[j];
- }
- P->record.counts[AllIO] = allIOCount;
- /*===========================================================*
- // compute exclusive duration. *
- //===========================================================*/
- excDur = clockSubtract(P->record.incDur,allIOTime);
- excDur = clockSubtract(excDur,P->record.times[HDF_]);
- excDur = clockSubtract(excDur,P->record.times[MPI]);
- /*===========================================================*
- // print header information. *
- //===========================================================*/
- Header.eventID = P->eventID;
- Header.Seconds = clockToSeconds(P->record.lastCall);
- Header.IncDur = clockToSeconds( P->record.incDur );
- Header.ExcDur = clockToSeconds(excDur);
- Header.HDFid = P->record.hdfID;
- Header.XREFid = P->record.xRef;
- Packet = buff;
- memcpy( Packet, &Header, sizeof(Header) );
- Packet += sizeof(Header);
- /*===========================================================*
- // copy number of calls to Packet. *
- //===========================================================*/
- nCalls = P->record.nCalls;
- memcpy( Packet, &nCalls, sizeof(int) );
- Packet += sizeof(int);
- /*===========================================================*
- // copy length of times array and times array to Packet. *
- //===========================================================*/
- arrayLen = nTallyFields;
- memcpy( Packet, &arrayLen, sizeof(int) );
- Packet += sizeof(int);
- for ( j = 0; j < nTallyFields; ++j ) {
- t = clockToSeconds(P->record.times[j]);
- memcpy( Packet, &t, sizeof(double) );
- Packet += sizeof(double);
- }
- /*===========================================================*
- // copy length of counts array and counts array to Packet. *
- //===========================================================*/
- arrayLen = nTallyFields;
- memcpy( Packet, &arrayLen, sizeof(int) );
- Packet += sizeof(int);
- memcpy( Packet, P->record.counts, nTallyFields*sizeof(int) );
- Packet += nTallyFields*sizeof(int);
- /*===========================================================*
- // copy length of bytes array and bytes array to Packet. *
- //===========================================================*/
- arrayLen = nByteFields;
- memcpy( Packet, &arrayLen, sizeof(int) );
- Packet += sizeof(int);
- memcpy( Packet, P->record.bytes, nByteFields*sizeof(int) );
- Packet += nByteFields*sizeof(int);
- /*===========================================================*
- // copy length of historgram arrays and arrays to Packet. *
- //===========================================================*/
- arrayLen = nBkts;
- for ( i = 0; i < nHistFields; ++i )
- {
- memcpy( Packet, &arrayLen, sizeof(int) );
- Packet += sizeof(int);
- memcpy( Packet, P->record.Hists[i], nBkts*sizeof(int) );
- Packet += nBkts*sizeof(int);
- }
- memcpy( Packet, &nodeID, sizeof(int) );
- Packet += sizeof(int);
- arrayLen = Packet-buff;
- memcpy(buff,&arrayLen,sizeof(int));
- putBytes( buff, Packet-buff );
- P = Q;
- }
-}
-/*======================================================================*
-// Initialize a node. *
-//======================================================================*/
-void HDFnodeInit ( HDFnode_t *S )
-{
- *S = InitNode;
-}
-/*======================================================================*
-// Compute IO totals, exclusive durations of the input record T *
-// then add the fields of T to that of S. *
-//======================================================================*/
-void HDFrecordSum ( HDFrec_t *S, HDFrec_t *T )
-{
- int i;
- int j;
-
- S->nCalls += T->nCalls;
- if ( clockCompare ( S->lastCall, T->lastCall ) < 0 )
- {
- S->lastCall = T->lastCall ;
- }
- S->incDur = clockAdd ( S->incDur, T->incDur );
- for ( j = 0; j < nTallyFields; ++j )
- {
- S->times[j] = clockAdd( S->times[j] , T->times[j] ) ;
- }
- for ( j = 0; j < nTallyFields; ++j )
- {
- S->counts[j] += T->counts[j] ;
- }
- for ( j = 0; j < nByteFields; ++j )
- {
- S->bytes[j] += T->bytes[j] ;
- }
- for ( j = 0; j < nHistFields; ++j )
- {
- for ( i = 0; i < nBkts; ++i )
- {
- S->Hists[j][i] += T->Hists[j][i] ;
- }
- }
-}
-/*======================================================================*
-// Return the field index corresponding to an IO event ID. The fields *
-// are specified in an enum statement in an include file. *
-//======================================================================*/
-int getHDFFieldIndex( int eventID )
-{
- int result = -1;
- switch ( eventID )
- {
- case ID_malloc:
- case -ID_malloc:
- {
- result = Malloc;
- break;
- }
- case openBeginID:
- case openEndID:
- case fopenBeginID:
- case fopenEndID:
- {
- result = Open;
- break;
- }
- case closeBeginID:
- case closeEndID:
- case fcloseBeginID:
- case fcloseEndID:
- {
- result = Close;
- break;
- }
- case readBeginID:
- case readEndID:
- case freadBeginID:
- case freadEndID:
- {
- result = Read;
- break;
- }
- case lseekBeginID:
- case lseekEndID:
- case fseekBeginID:
- case fseekEndID:
- {
- result = Seek;
- break;
- }
- case writeBeginID:
- case writeEndID:
- case fwriteBeginID:
- case fwriteEndID:
- {
- result = Write;
- break;
- }
- case fflushBeginID:
- case fflushEndID:
- case flushBeginID:
- case flushEndID:
- {
- result = Misc;
- break;
- }
- case rewindBeginID:
- case rewindEndID:
- case fsetposBeginID:
- case fsetposEndID:
- {
- result = Misc;
- break;
- }
-#ifdef creadBeginID
- case creadBeginID:
- case creadEndID:
- case creadvBeginID:
- case creadvEndID:
- {
- result = Read;
- break;
- }
- case cwriteBeginID:
- case cwriteEndID:
- case cwritevBeginID:
- case cwritevEndID:
- {
- result = Write;
- break;
- }
- case ireadBeginID:
- case ireadEndID:
- case ireadvBeginID:
- case ireadvEndID:
- {
- result = Aread;
- break;
- }
- case iwriteBeginID:
- case iwriteEndID:
- case iwritevBeginID:
- case iwritevEndID:
- {
- result = Awrite;
- break;
- }
- case iowaitBeginID:
- case iowaitEndID:
- {
- result = Wait;
- break;
- }
- case iodoneBeginID:
- case iodoneEndID:
- {
- result = Misc;
- break;
- }
- case gopenBeginID:
- case gopenEndID:
- {
- result = Open;
- break;
- }
- case iomodeBeginID:
- case iomodeEndID:
- case setiomodeBeginID:
- case setiomodeEndID:
- case lsizeBeginID:
- case lsizeEndID:
- case forflushBeginID:
- case forflushEndID:
- {
- result = Misc;
- break;
- }
-#endif
- }
- return result;
-}
-/*======================================================================*
-// This routine determines the field index in the bytes array of the *
-// HDF records which correspond to a given IO operation. If the *
-// operation does not transfer bytes, (e.g., open operation), -1 is *
-// returned. *
-//======================================================================*/
-int getHDFByteFieldIndex( int Operation )
-{
- int result;
- switch ( Operation )
- {
- case Malloc:
- {
- result = MallocBytes;
- break;
- }
- case Read:
- {
- result = ReadBytes;
- break;
- }
- case Write:
- {
- result = WriteBytes;
- break;
- }
- case Aread:
- {
- result = AreadBytes;
- break;
- }
- case Awrite:
- {
- result = AwriteBytes;
- break;
- }
- case MPIOread:
- {
- result = MPIOreadBytesReq;
- break;
- }
- case MPIOwrite:
- {
- result = MPIOwriteBytesReq;
- break;
- }
- case MPIOreadAll:
- {
- result = MPIOreadAllBytesReq;
- break;
- }
- case MPIOwriteAll:
- {
- result = MPIOwriteAllBytesReq;
- break;
- }
- case MPIOiRead:
- {
- result = MPIOiReadBytesReq;
- break;
- }
- case MPIOiWrite:
- {
- result = MPIOiWriteBytesReq;
- break;
- }
- case MPIOreadTrans:
- {
- result = MPIOreadBytesTrans;
- break;
- }
- case MPIOwriteTrans:
- {
- result = MPIOwriteBytesTrans;
- break;
- }
- case MPIOreadAllTrans:
- {
- result = MPIOreadAllBytesTrans;
- break;
- }
- case MPIOwriteAllTrans:
- {
- result = MPIOwriteAllBytesTrans;
- break;
- }
- default:
- {
- result = -1;
- break;
- }
- }
- return result;
-}
-/*======================================================================*
-// This routine writes the SDDF packet descriptors for the HDF summary *
-// records to the output file. *
-//======================================================================*/
-void _hdfDescriptorRT( char *recordName, char *recordDescription,
- int recordFamily )
-{
- static char recordBuffer[ 4096 ];
- int recordLength;
-
- hdfRecordPointer = recordBuffer;
- /*==================================================================*
- // Allow space at the beginning of the record for the packet *
- //length which will be computed after the packet is complete. *
- //==================================================================*/
- sddfWriteInteger( &hdfRecordPointer, 0 );
- /*==================================================================*
- // The record type, tag, and name *
- //==================================================================*/
- sddfWriteInteger( &hdfRecordPointer, PKT_DESCRIPTOR );
- sddfWriteInteger( &hdfRecordPointer, ( recordFamily | RECORD_TRACE ) );
- sddfWriteString( &hdfRecordPointer, recordName );
- /*==================================================================*
- // The record attribute count and string pair *
- //==================================================================*/
- sddfWriteInteger( &hdfRecordPointer, 1 );
- sddfWriteString( &hdfRecordPointer, "description" );
- sddfWriteString( &hdfRecordPointer, recordDescription );
- /*==================================================================*
- // The record field count *
- //==================================================================*/
- sddfWriteInteger( &hdfRecordPointer, 16 );
- WRITE_HDF_FIELD( "Event Identifier",
- "Event ID",
- "Corresponding Event",
- INTEGER, 0 );
- WRITE_HDF_FIELD( "Seconds",
- "Seconds",
- "Floating Point Timestamp",
- DOUBLE, 0 );
- WRITE_HDF_FIELD( "Inclusive Duration",
- "Inclusive Duration",
- "Inclusive Duration of this Procedure",
- DOUBLE, 0 );
- WRITE_HDF_FIELD( "Exclusive Duration",
- "Exclusive Duration",
- "Excludes IO, MPI-IO and other HDF calls",
- DOUBLE, 0 );
- WRITE_HDF_FIELD2("HDF ID",
- "HDF ID", "Identifier number",
- "0", "No HDF ID specified",
- LONG, 0 );
- WRITE_HDF_FIELD( "Xref ID",
- "Cross Reference",
- "Index of related HDF ID or 0 if none",
- LONG, 0 );
- WRITE_HDF_FIELD( "N Calls",
- "N Calls",
- "Number of Calls to this Proc",
- INTEGER, 0 );
- WRITE_HDF_FIELD( "Times Array",
- "Times Array",
- "Array of Total Operation Times",
- DOUBLE, 1 );
- WRITE_HDF_FIELD( "Counts Array",
- "Counts Array",
- "Array of Total Operation Counts",
- INTEGER, 1 );
- WRITE_HDF_FIELD( "Bytes Array",
- "Bytes Array",
- "Array of Total Bytes Transferred",
- INTEGER, 1 );
- WRITE_HDF_FIELD( "Malloc Histogram",
- "Malloc Histogram",
- "Historgram of size Malloc Requests",
- INTEGER, 1 );
- WRITE_HDF_FIELD( "Read Histogram",
- "Read Histogram",
- "Historgram of size Read Requests",
- INTEGER, 1 );
- WRITE_HDF_FIELD( "Write Histogram",
- "Write Histogram",
- "Historgram of size Write Requests",
- INTEGER, 1 );
- WRITE_HDF_FIELD( "Aread Histogram",
- "Aread Histogram",
- "Historgram of size Asynch Read Requests",
- INTEGER, 1 );
- WRITE_HDF_FIELD( "Awrite Histogram",
- "Awrite Histogram",
- "Historgram of size Asynch Write Requests",
- INTEGER, 1 );
- WRITE_HDF_FIELD( "Processor Number",
- "Node",
- "Processor number",
- INTEGER, 0 );
- /*===================================================================
- // The entire record descriptor packet has been written. *
- // Compute and update the record length. *
- // Write the completed record. *
- //==================================================================*/
- recordLength = (int)(hdfRecordPointer - recordBuffer);
-
- hdfRecordPointer = recordBuffer;
- sddfWriteInteger( &hdfRecordPointer, recordLength );
-
- putBytes( recordBuffer, (unsigned) recordLength );
-}
-
-/*======================================================================*
-// Internal Routine: writeHDFRecDescrptrsRT *
-// Writes record descriptors for the HDF events. *
-//======================================================================*/
-void writeHDFRecDescrptrsRT( void )
-{
- int j, FAMILY;
- char BUF1[256], BUF2[256] ;
- char buff[41];
- _hdfNameDescriptor(); /* Descriptor for named identifiers */
- for ( j = 0; j < NumHDFProcs; ++j ) {
- if ( HDFQueues[j] != NULL ) {
- getHDFprocName( j, buff );
- strcpy( BUF2, "HDF ");
- strcat( BUF2, buff );
- strcat( BUF2, " Procedure Summary");
- strcpy( BUF1, BUF2 );
- strcat( BUF1, " Trace");
- FAMILY = HDF_SUMMARY_FAMILY + (j + 1)*8;
- _hdfDescriptorRT( BUF1, BUF2, FAMILY );
- }
- }
- return;
-}
-/*======================================================================*
-// This routine prints the Pablo IDs assigned to named HDF identifiers *
-//======================================================================*/
-void printFileMappingsRT( char *mapFile, char **Names, int nPabloIDs )
-{
- int i;
- FILE *ptr;
- ptr = fopen( mapFile, "w" );
-
- if ( ptr == NULL ) {
- fprintf(stderr,
- "Couldn't open map file %s - none created.\n",mapFile);
- return;
- }
-
- fprintf(ptr,"\n\nPablo ID to HDF Name mappings:\n");
- fprintf(ptr,"------------------------------\n");
- for ( i = 1; i <= nPabloIDs; i++ ) {
- fprintf(ptr,"%4d %s\n",i,Names[i] );
- }
- fprintf(ptr,"\n\n");
- fclose( ptr );
-}
-/************************************************************************/
-/* _hdfNameDescriptor */
-/* Generate a SDDF binary format record descriptor for the */
-/* named identifiers used during execution. */
-/************************************************************************/
-void _hdfNameDescriptor( void )
-{
- static char recordBuffer[ 4096 ];
- int recordLength;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "_hdfExitTraceDescriptor entered\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
- hdfRecordPointer = recordBuffer;
- /********************************************************************/
- /* Allow space at the beginning of the record for the packet */
- /*length which will be computed after the packet is complete. */
- /********************************************************************/
- sddfWriteInteger( &hdfRecordPointer, 0 );
- /********************************************************************/
- /* The record type, tag, and name */
- /********************************************************************/
- sddfWriteInteger( &hdfRecordPointer, PKT_DESCRIPTOR );
- sddfWriteInteger( &hdfRecordPointer, ( FAMILY_NAME ) );
- sddfWriteString( &hdfRecordPointer, "HDF Name Identifier Record" );
- /********************************************************************/
- /* The record attribute count and string pair */
- /********************************************************************/
- sddfWriteInteger( &hdfRecordPointer, 1 );
- sddfWriteString( &hdfRecordPointer, "description" );
- sddfWriteString( &hdfRecordPointer, "HDF Name Identifier Record" );
- /********************************************************************/
- /* The record field count */
- /********************************************************************/
- sddfWriteInteger( &hdfRecordPointer, 3);
- /********************************************************************/
- /* Create fields */
- /********************************************************************/
- WRITE_HDF_FIELD( "Identifier Type",
- "Data Set Type",
- "Data Set Identifier Type",
- INTEGER, 0 );
- WRITE_HDF_FIELD2( "HDF ID",
- "HDF ID", "File, Data Set or Dim Identifier number",
- "0", "No HDF ID specified",
- INTEGER, 0 );
- WRITE_HDF_FIELD( "HDF Name",
- "HDF Name", "Name of File, Data Set or Dim",
- CHARACTER, 1 );
-
- recordLength = (int)(hdfRecordPointer - recordBuffer);
-
- hdfRecordPointer = recordBuffer;
- sddfWriteInteger( &hdfRecordPointer, recordLength );
-
- putBytes( recordBuffer, (unsigned) recordLength );
-}
-#endif /* PCF_BUILD */
diff --git a/pablo/PabloHDF_SDDF.c b/pablo/PabloHDF_SDDF.c
deleted file mode 100644
index 6326702..0000000
--- a/pablo/PabloHDF_SDDF.c
+++ /dev/null
@@ -1,820 +0,0 @@
-/*
- * This file is an extension to NCSA HDF to enable the use of the
- * Pablo trace library.
- *
- * Developed by: The TAPESTRY Parallel Computing Laboratory
- * University of Illinois at Urbana-Champaign
- * Department of Computer Science
- * 1304 W. Springfield Avenue
- * Urbana, IL 61801
- *
- * Copyright (c) 1995
- * The University of Illinois Board of Trustees.
- * All Rights Reserved.
- *
- * PABLO is a registered trademark of
- * The Board of Trustees of the University of Illinois
- * registered in the U.S. Patent and Trademark Office.
- *
- * Author: George Xin Zhou (xzhou@cs.uiuc.edu)
- * Contributing Author: Jonathan M. Reid (jreid@cs.uiuc.edu)
- *
- * Project Manager and Principal Investigator:
- * Daniel A. Reed (reed@cs.uiuc.edu)
- *
- * Funded by: National Aeronautics and Space Administration under NASA
- * Contracts NAG-1-613 and USRA 5555-22 and by the Advanced Research
- * Projects Agency under ARPA contracts DAVT63-91-C-0029 and
- * DABT63-93-C-0040.
- *
- */
-/*======================================================================*
-// File: PabloHDF_SDDF.c *
-// Purpose: support use of Pablo trace library to analyze HDF *
-// performance *
-// Contents: *
-// HDFinitTrace_SDDF: initialize SDDF tracing *
-// HDFendTrace_SDDF: end SDDF tracing *
-// startHDFtraceEvent: record start of HDF procedure *
-// endHDFtraceEvent: record end of HDF proc *
-// preInitHDFProcTrace: called by HDFinitTrace_SDDF to set up SDDF *
-// interface function calls *
-// initHDFProcTrace: called by HDFinitTrace_SDDF to initialize data *
-// structures used in tracing HDF procedures. *
-// writeHDFProcRecordDescriptors: *
-// generates the record descriptors for the HDF *
-// procedure entry/exit event families. *
-// HDFprocEventRecord: generates trace records for events which are *
-// to produce procedure entry or exit event family *
-// trace records. *
-// findHDFProcEvent: retruns procedure entry/exit index *
-// _hdfTraceEntryDescriptor: *
-// Generate a SDDF binary format record descriptor *
-// for HDF procedure entries *
-// _hdfTraceExitDescriptor: *
-// Generate a SDDF binary format record descriptor *
-// for the HDF procedure exits *
-//======================================================================*/
-#ifndef PCF_BUILD
-#include <stdio.h>
-
-#include "H5config.h"
-#undef H5_HAVE_PABLO
-#include "H5private.h"
-#define H5_HAVE_PABLO
-#include "ProcIDs.h"
-
-#include "SystemDepend.h"
-#include "SDDFparam.h"
-#include "TraceParam.h"
-#include "Trace.h"
-#include "IOTrace.h"
-#include "HDFTrace.h"
-void IOtraceInit( char*, int, int );
-void HDFendTrace_SDDF(void);
-void startHDFtraceEvent(int eventID);
-void endHDFtraceEvent(int , int , char *, int );
-int preInitHDFProcTrace( void );
-int initHDFProcTrace( int , int * );
-int writeHDFProcRecordDescriptors( void );
-int findHDFProcEvent( int ) ;
-TR_RECORD *HDFprocEventRecord( int, TR_EVENT *, CLOCK, HDFsetInfo *, unsigned );
-TR_RECORD *miscEventRecord( int , TR_EVENT *, CLOCK, void *, unsigned );
-void _hdfMiscDescriptor( void );
-void _hdfProcNameDescriptor( void );
-/*int setEventRecordFunction( int, void *(*)() );*/
-int setEventRecordFunction( int, TR_RECORD *(*)() );
-void HDFtraceIOEvent( int, void *, unsigned );
-void initIOTrace( void );
-void enableIOdetail( void );
-void disableLifetimeSummaries( void );
-void disableTimeWindowSummaries( void );
-void disableFileRegionSummaries( void );
-void _hdfTraceDescriptor( char *, char *, int );
-void createHDFTraceDescriptor( int );
-void HDFfinalTimeStamp( void );
-void getHDFprocName( int index, char buff[41] );
-void endIOTrace();
-
-#define PABLO 1
-/* on the ipsc/860 we don't include unistd.h */
-#ifndef __NX
-#include <unistd.h>
-#endif
-
-#define returnRecord(x) return x;
-
-#ifdef H5_HAVE_MPIOTRACE
- int initMPIOTrace( char *, int, int );
- void endMPIOTrace( void ) ;
-#else
- void endMPIOTrace( void ) {return;}
-#endif
-extern char *hdfRecordPointer;
-/*======================================================================*
-// Prototypes of functions in this file. *
-//======================================================================*/
-void HDFinitTrace_SDDF( char *, int );
-/*======================================================================*
-// Each procedure being traced has associated with it a distinct pair *
-// of entry and exit event IDs. This code maintains a vector of such *
-// matchings which permits the ready identification of an event ID as *
-// being either an entry event or an exit event and for which procedure.*
-//======================================================================*/
-typedef struct procEventMatch {
- int entryID; /* procedure entry event ID */
- int exitID; /* procedure exit event ID */
-} PROC_EVENTS;
-
-static PROC_EVENTS *procEvents = /* array of event ID pairs */
- (PROC_EVENTS *) 0;
-/*======================================================================*
-// For each procedure being traced this code maintains a stack of *
-// procedure entry times. Each procedure entry event causes the *
-// corresponding procedure's stack to be pushed, each procedure exit *
-// event causes the corresponding procedure's stack to be popped, and *
-// from the difference in time between entry and exit the procedure *
-// duration may be calculated in a very straightforward subtraction. *
-// The above procedure entry-exit event ID matching is used to map *
-// events to their corresponding procedures. In addition, the *
-// cumulative total of these procedure durations is maintained for all *
-// traced subprocedures of each traced procedure. That is, when a *
-// traced procedure exits, it increases this duration sum for its most *
-// immediate traced ancestor procedure. By subtracting this *
-// subprocedure duration sum from the traced procedure's inclusive *
-// duration, we arrive at the exclusive duration of the procedure. *
-//======================================================================*/
-typedef struct procEntryTime {
- CLOCK entryTime; /* when proc entered */
- CLOCK subProcTime; /* subproc duration */
- struct procEntryTime *nextTime; /* stack pointer down */
- struct procEntryTime *ancestorProc; /* traced ancestor */
-} PROC_ENTRY;
-
-/*
-static PROC_ENTRY **procEntryStack =*/ /* array of pointers to */
-/* (PROC_ENTRY **) 0;*/ /* stack top elements */
-/*======================================================================*
-// Define data structure types for procedure entry and exit trace *
-// records, similarly to record data structures in Trace.h *
-//======================================================================*/
-
-/*======================================================================*
-// TraceRecord Data packets: *
-//======================================================================*/
-struct procTraceRecordData {
- int packetLength; /* bytes in packet */
- int packetType; /* == PKT_DATA */
- int packetTag; /* FAMILY_PROCEXIT | RECORD_TRACE */
- int eventID; /* ID of corresponding event */
- double seconds; /* floating-point timestamp */
- long setID; /* index of file | Data Set accessed */
- int nodeNumber; /* occurred on which node */
- int nameLen; /* Length of file or data set name */
- /* name comes next, but no space is allocated */
-};
-#define procTraceRecLen 6*sizeof(int) + sizeof(double) +sizeof(long)
-/*======================================================================*
-// misc Record Data packets: *
-//======================================================================*/
-struct miscTraceRecordData
-{
- int packetLength; /* bytes in packet */
- int packetType; /* == PKT_DATA */
- int packetTag; /* FAMILY_MISC | RECORD_TRACE */
- int eventID; /* ID of corresponding event */
- double seconds; /* floating-point timestamp */
- double duration; /* floating-point operation duration */
- unsigned long bytes; /* number of bytes requested */
- int nodeNumber; /* occurred on which node */
-};
-#define miscTraceLen 5*sizeof(int) + 2*sizeof(double) +sizeof(long)
-/*======================================================================*
-// The procEntries array specifies the event IDs of procedure entry *
-// events. *
-//======================================================================*/
-int procEntries[] =
-{
-0, 0, 0, 0, 0,
-#include "HDFidList.h"
-ID_HDF_Last_Entry
-};
-/*======================================================================*
-// The procEntryCalled array indicates whether or not a procedure entry *
-// was called. *
-//======================================================================*/
-int *procEntryCalled;
-/*=======================================================================
-// NAME *
-// HDFinitTrace_SDDF -- initalize HDF tracing with SDDF records *
-// USAGE *
-// HDFinitTrace_SDDF( traceFileName, porcNum ) *
-// PARAMETERS *
-// char *traceFileName -- name of trace file to hold output *
-// int procNum -- processor Number *
-// RETURNS *
-// None *
-//======================================================================*/
-void HDFinitTrace_SDDF( char *traceFileName, int procNum )
-{
- /*====================================================================
- // set traceFileName and set IO tracing switches. If MPIO *
- // tracing is available, MPIO tracing will also be initialized. *
- //===================================================================*/
-#ifdef H5_HAVE_MPIOTRACE
-// int myNode;
- /*====================================================================
- // in the parallel case, initialize MPI-IO tracing. This *
- // will initialize the traceFileName and set the I/O tracing *
- // switches. *
- //===================================================================*/
- /*====================================================================
- // MPIO Tracing is supported in the Pablo Library. Let the *
- // MPIO initialization be performed and handle the naming of *
- // trace files. *
- //===================================================================*/
- initMPIOTrace( traceFileName, procNum, RUNTIME_TRACE );
-// MPI_Comm_rank( MPI_COMM_WORLD, &myNode );
- setTraceProcessorNumber( procNum );
-#else
- IOtraceInit( traceFileName, procNum, RUNTIME_TRACE );
- /*====================================================================
- // complete HDF initiailization. *
- //===================================================================*/
- enableIOdetail();
- disableLifetimeSummaries();
- disableTimeWindowSummaries();
- disableFileRegionSummaries();
-#endif
- preInitHDFProcTrace();
- initHDFProcTrace( sizeof(procEntries)/sizeof(int), procEntries );
-}
-/*=======================================================================
-// NAME *
-// HDFendTrace_SDDF -- end HDF tracing *
-// USAGE *
-// HDFendTrace_SDDF() *
-// RETURNS *
-// None. *
-//======================================================================*/
-void HDFendTrace_SDDF()
-{
- HDFfinalTimeStamp();
-#ifdef H5_HAVE_MPIORACE
- /*====================================================================
- // termintate MPI-IO tracing in the parallel case. This *
- // will terminate the I/O tracing and close tracing as well. *
- //===================================================================*/
- endMPIOTrace();
-#else
- /*====================================================================
- // terminate tracing *
- //===================================================================*/
- endIOTrace();
- endTracing();
-#endif
-}
-/*=======================================================================
-// NAME *
-// initHDFProcTrace: *
-// This function initializes data structures specific to *
-// the procedure entry/exit tracing extensions of the Pablo *
-// instrumentation library. The argument numProcs specifies *
-// how many procedures are to be traced. The argument procEntryID *
-// is a vector specifying the event IDs to be use as entry events *
-// for each of the procedures. The negative value is used for *
-// the exit event ID. *
-// USAGE *
-// result = initHDFProcTrace(numProcs,procEntryID) *
-// PARAMETERS *
-// int numProcs -- number of Procedures to be initialized *
-// int *procEntryID -- array of id entry codes for these procedures *
-// RETURNS *
-// SUCCESS or FAILURE *
-//======================================================================*/
-int initHDFProcTrace( int numProcs, int *procEntryID )
-{
- int procIndex;
- int IX;
- int ID;
-
- if (( numProcs <= 0 ) || ( procEntryID == (int *) 0 ) )
- {
- return FAILURE;
- }
- /*====================================================================
- // Allocate space to store a copy of the procedure entry-exit *
- // event ID matchings and also the procedure entry stacks. *
- //===================================================================*/
- procEvents = (PROC_EVENTS *)TRgetBuffer((numProcs+4)*sizeof(PROC_EVENTS));
-
- if ( procEvents == (PROC_EVENTS *) 0 )
- {
- TRfailure( "cannot allocate procedure events matching" );
- }
-
- procEntryCalled = ( int *)malloc( numProcs*sizeof(int) );
- if ( procEvents == NULL )
- {
- TRfailure( "cannot allocate procedure Called indicators" );
- }
- /*====================================================================
- // Initialize the procedure events matching from the arguments *
- // passed. Configure the trace record-generating function for *
- // these events. Initialize the flags indicating whether or *
- // not the procedure was called. *
- //===================================================================*/
- for ( procIndex = 0; procIndex < numProcs; procIndex++ )
- {
-
- IX = procEntryID[ procIndex ];
- ID = HDFIXtoEventID( IX );
- procEvents[ procIndex ].entryID = ID;
- procEvents[ procIndex ].exitID = -ID;
-
- setEventRecordFunction( ID, HDFprocEventRecord );
- setEventRecordFunction( -ID, HDFprocEventRecord );
- procEntryCalled[ procIndex ] = 0;
-
- }
-
- /*====================================================================
- // Initialize the procedure events for malloc. *
- // Configure the trace record-generating function for this *
- // event. *
- //===================================================================*/
- procEvents[ numProcs ].entryID = ID_malloc;
- procEvents[ numProcs ].exitID = -ID_malloc;
- setEventRecordFunction( ID_malloc, miscEventRecord );
- setEventRecordFunction( -ID_malloc, miscEventRecord );
- procEvents[ numProcs+1 ].entryID = ID_free;
- procEvents[ numProcs+1 ].exitID = -ID_free;
- setEventRecordFunction( ID_free, miscEventRecord );
- setEventRecordFunction( -ID_free, miscEventRecord );
-
- return SUCCESS;
-}
-/*=======================================================================
-// NAME *
-// preInitHDFProcTrace: *
-// This function calls the trace library interface function *
-// setRecordDescriptor, which records the address of the *
-// procedure that generates the record descriptors for the *
-// procedure trace event families. It is automatically *
-// invoked by HDFinitTrace_SDDF. *
-// USAGE *
-// result = preInitHDFProcTrace(); *
-// RESULT *
-// SUCCESS or FAILURE *
-/=======================================================================*/
-int preInitHDFProcTrace( void )
-{
- static int preInitDone = FALSE;
-
- if ( preInitDone == TRUE )
- {
- return SUCCESS;
- }
- /*====================================================================
- // Give the instrumentation library a pointer to the functions *
- // in which we output the specialized record descriptors for *
- // procedure entry/exit. *
- //===================================================================*/
- setRecordDescriptor( writeHDFProcRecordDescriptors );
-
- preInitDone = TRUE;
- return SUCCESS;
-}
-/*=======================================================================
-// NAME *
-// writeHDFProcRecordDescriptors: *
-// This function generates the record descriptors for the HDF *
-// procedure entry/exit event families. It will be invoked *
-// by the instrumentation library initialization routines. *
-// Patterned after instrumentation library internal function *
-// writeRecordDescriptors. *
-// USAGE *
-// result = writeHDFProcRecordDescriptors(); *
-// RESULT *
-// SUCCESS *
-/=======================================================================*/
-int writeHDFProcRecordDescriptors( void )
-{
-#ifdef PABLODEBUG
- fprintf( debugFile, "writeHDFProcRecordDescriptors\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- _hdfMiscDescriptor();
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "writeHDFProcRecordDescriptors done\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
- return SUCCESS;
-}
-/*=======================================================================
-// NAME *
-// HDFprocEventRecord: *
-// This function generates trace records for events which are *
-// to produce procedure entry or exit event family trace records. *
-// Patterned after the instrumentation library internal functions *
-// externalEventRecord and sddfRecord. *
-// USAGE *
-// REC = HDFprocEventRecord( recordType, eventPointer, timeStamp, *
-// dataPointer, dataLength) *
-// PARAMETERS *
-// int recordType -- type of event record *
-// TR_EVENT eventPointer -- pointer to event data structure *
-// CLOCK timeStamp -- time event is recorded *
-// HDFsetInfo dataPointer -- information about HDF data set accessed *
-// unsigned dataLength -- dummy for compatability *
-// RETURNS *
-// pointer to trace record for this event *
-//======================================================================*/
-TR_RECORD *
-HDFprocEventRecord( int recordType,
- TR_EVENT *eventPointer,
- CLOCK timeStamp,
- HDFsetInfo *dataPointer,
- unsigned dataLength )
-{
- static TR_RECORD traceRecord;
- static void *recordBuffer = NULL;
- static int bufferLength = 0;
- struct procTraceRecordData *TraceRecordHeader;
- int procIndex;
- int recordFamily;
- char *namePtr;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "HDFprocEventRecord\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
-
- /*==============================================================*
- // Find the index in the tables for the procedure corresponding *
- // to this eventID. *
- //==============================================================*/
- procIndex = findHDFProcEvent( eventPointer->eventID );
- if ( procIndex < 0 )
- {
- return nullRecordFunction( recordType, eventPointer,
- timeStamp, (char *)dataPointer, dataLength );
- }
- /*===================================================================*
- // Produce a packet for the name of the procedure if one has *
- // not already been produced. *
- //===================================================================*/
- if ( procEntryCalled[procIndex] == 0 ) {
- createHDFTraceDescriptor( procIndex );
- procEntryCalled[procIndex] = 1;
- }
- /*===================================================================*
- // Determine whether this is a procedure entry or a procedure *
- // exit family event by lookup in the procedure event ID *
- // matching. *
- //===================================================================*/
- recordFamily = HDF_FAMILY + ( procIndex + 1)*8;
- /*===================================================================*
- // The time stamp stored in the event descriptor will be used *
- // unless one is specified in the timeStamp parameter. *
- //===================================================================*/
- if ( clockCompare( timeStamp, noSuchClock ) == 0 ) {
- timeStamp = eventPointer->eventLast;
- }
- /*===================================================================*
- // Determine how many bytes of storage will be needed for the *
- // contents of the trace record. *
- //===================================================================*/
- traceRecord.recordLength = sizeof *TraceRecordHeader;
- if ( dataPointer != NULL && dataPointer->setName != NULL )
- {
- traceRecord.recordLength += strlen( dataPointer->setName );
- }
- /*===================================================================*
- // If there is a previously-allocated buffer and its size will *
- // hold this record, re-use the buffer. Otherwise, deallocate *
- // the buffer (if allocated) and allocate a bigger one. *
- //===================================================================*/
- if ( bufferLength < traceRecord.recordLength )
- {
-
- if ( recordBuffer != NULL )
- {
- TRfreeBuffer( recordBuffer );
- }
-
- recordBuffer = (char *)TRgetBuffer( traceRecord.recordLength );
-
- if ( recordBuffer == NULL )
- {
- TRfailure( "cannot allocate storage for trace record" );
- }
- bufferLength = traceRecord.recordLength;
- }
-
- traceRecord.recordContents = recordBuffer;
- /*===================================================================*
- // Load the trace record fields into the allocated buffer *
- //===================================================================*/
- TraceRecordHeader = (struct procTraceRecordData *)recordBuffer;
- TraceRecordHeader->packetLength = traceRecord.recordLength;
- TraceRecordHeader->packetType = PKT_DATA;
- TraceRecordHeader->packetTag = recordFamily | recordType;
- TraceRecordHeader->seconds = clockToSeconds( timeStamp );
- TraceRecordHeader->eventID = eventPointer->eventID;
- TraceRecordHeader->nodeNumber = TRgetNode();
-
- if ( dataPointer != 0 )
- {
- TraceRecordHeader->setID = dataPointer->setID;
- if (dataPointer->setName != NULL )
- {
- TraceRecordHeader->nameLen = (int)strlen( dataPointer->setName );
- /*==============================================================*
- // copy name directly into the end of the buffer. *
- //==============================================================*/
- namePtr = (char *)TraceRecordHeader + procTraceRecLen;
- memcpy(namePtr, dataPointer->setName, TraceRecordHeader->nameLen);
- }
- else
- {
- TraceRecordHeader->nameLen = 0;
- }
- }
- else
- {
- TraceRecordHeader->setID = 0;
- TraceRecordHeader->nameLen = 0;
- }
-#ifdef PABLODEBUG
- fprintf( debugFile, "HDFprocEventRecord done\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
- returnRecord(&traceRecord);
-}
-/*======================================================================*
-// Internal Routine: miscEventRecord *
-// Called for misc start and end events. *
-//======================================================================*/
-TR_RECORD *miscEventRecord( int recordType,
- TR_EVENT *eventPointer,
- CLOCK timeStamp,
- void *dataPointer,
- unsigned dataLength )
-{
- static TR_RECORD traceRecord;
- static struct miscTraceRecordData miscRecord;
- static int initialized = FALSE;
- int eventID;
-
- if ( clockCompare( timeStamp, noSuchClock ) == 0 )
- {
- timeStamp = eventPointer->eventLast;
- }
-
- eventID = eventPointer->eventID;
- if ( ! initialized )
- {
- miscRecord.packetLength = sizeof( miscRecord );
- miscRecord.packetType = PKT_DATA;
- miscRecord.packetTag = FAMILY_MISC | RECORD_TRACE;
- miscRecord.nodeNumber = traceProcessorNumber;
-
- traceRecord.recordLength = miscRecord.packetLength;
- traceRecord.recordContents = (char *) &miscRecord;
- initialized = TRUE;
- }
-
- switch ( eventID )
- {
- case ID_malloc:
- case ID_free:
- miscRecord.seconds = clockToSeconds( timeStamp ) ;
- miscRecord.eventID = eventID ;
- break;
- case -ID_malloc:
- case -ID_free:
- miscRecord.bytes = *(int *)dataPointer;
- miscRecord.duration = clockToSeconds( timeStamp)
- - miscRecord.seconds;
- return &traceRecord; /* generate trace record */
- default:
- fprintf( stderr, "miscEventRecord: unknown eventID %d\n", eventID );
- break;
- }
- /*===================================================================*
- // If we get here then no trace record generated. Normally we *
- // should get here if this is an entry call. *
- //===================================================================*/
- return( nullRecordFunction( recordType, eventPointer, timeStamp,
- dataPointer, dataLength ) );
-}
-/*======================================================================*
-// NAME *
-// findHDFProcEvent: *
-// Search the procedure entry/exit event ID matching data *
-// structure for an event ID (either entry or exit) which is *
-// the same as the argument eventID. If found, return the *
-// index from that table, which will be between 0 and *
-// numberProcedures - 1, inclusive. If not found, return -1; *
-// USAGE *
-// index = findHDFProcEvent *
-// RETURNS *
-// index of the procedure corresponding to this ID *
-//======================================================================*/
-int findHDFProcEvent( int eventID )
-{
- int procIndex;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "findHDFProcEvent\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
- if ( isBeginHDFEvent(eventID) )
- {
- procIndex = eventID - BEGIN_HDF;
- }
- else if ( isEndHDFEvent( eventID ) )
- {
- procIndex = -eventID - BEGIN_HDF;
- }
- else
- {
- procIndex = -1 ;
- }
- return procIndex;
-}
-void createHDFTraceDescriptor( int Inx )
-{
- char BUF1[256];
- char BUF2[256] ;
- char buff[41];
- int FAMILY;
- getHDFprocName( Inx, buff );
- strcpy( BUF2, "HDF ");
- strcat( BUF2, buff );
- strcat( BUF2, " Procedure");
- strcpy( BUF1, BUF2 );
- strcat( BUF1, " Trace");
-
- FAMILY = HDF_FAMILY + (Inx + 1)*8;
- _hdfTraceDescriptor( BUF1, BUF2, FAMILY );
-}
-/*======================================================================*
-// NAME *
-// _hdfTraceDescriptor *
-// Generate a SDDF binary format record descriptor for the *
-// full trace class of events in the HDF procedure entry *
-// USAGE *
-// _hdfTraceDescriptro( recordName, recordDescription, recordFamily ) *
-// RETURNS *
-// void *
-//======================================================================*/
-void _hdfTraceDescriptor( char *recordName,
- char *recordDescription,
- int recordFamily )
-{
- static char recordBuffer[ 4096 ];
- int recordLength;
-
- hdfRecordPointer = recordBuffer;
- /*====================================================================
- // Allow space at the beginning of the record for the packet *
- //length which will be computed after the packet is complete. *
- //===================================================================*/
- sddfWriteInteger( &hdfRecordPointer, 0 );
- /*====================================================================
- // The record type, tag, and name *
- //===================================================================*/
- sddfWriteInteger( &hdfRecordPointer, PKT_DESCRIPTOR );
- sddfWriteInteger( &hdfRecordPointer, ( recordFamily | RECORD_TRACE ) );
- sddfWriteString( &hdfRecordPointer, recordName );
- /*====================================================================
- // The record attribute count and string pair *
- //===================================================================*/
- sddfWriteInteger( &hdfRecordPointer, 1 );
- sddfWriteString( &hdfRecordPointer, "description" );
- sddfWriteString( &hdfRecordPointer, recordDescription );
- /*===================================================================*
- // The record field count *
- //===================================================================*/
- sddfWriteInteger( &hdfRecordPointer, 5);
- /*===================================================================*
- // Create fields *
- //===================================================================*/
- WRITE_HDF_FIELD( "Event Identifier",
- "Event ID",
- "Event Identifier Number",
- INTEGER,
- 0 );
- WRITE_HDF_FIELD( "Seconds",
- "Seconds",
- "Floating Point Timestamp",
- DOUBLE,
- 0 );
- WRITE_HDF_FIELD2( "HDF ID",
- "HDF ID",
- "File, Data Set or Dim Identifier number",
- "0",
- "No HDF ID specified",
- LONG,
- 0 );
- WRITE_HDF_FIELD( "Processor Number",
- "Node",
- "Processor number",
- INTEGER,
- 0 );
- WRITE_HDF_FIELD( "HDF Name",
- "HDF Name",
- "Name of File, Data Set or Dim",
- CHARACTER,
- 1 );
-
- recordLength = (int)(hdfRecordPointer - recordBuffer);
-
- hdfRecordPointer = recordBuffer;
- sddfWriteInteger( &hdfRecordPointer, recordLength );
-
- putBytes( recordBuffer, (unsigned) recordLength );
-}
-/*======================================================================*
-// NAME *
-// _hdfMiscDescriptor *
-// Generate a SDDF binary format record descriptor for the *
-// misc procedure *
-// USAGE *
-// _hdfMiscDescriptor() *
-// RETURNS *
-// void *
-//======================================================================*/
-void _hdfMiscDescriptor( void )
-{
- static char recordBuffer[ 4096 ];
- int recordLength;
-
-#ifdef PABLODEBUG
- fprintf( debugFile, "_hdfMiscDescriptor entered\n" );
- fflush( debugFile );
-#endif /* PABLODEBUG */
- hdfRecordPointer = recordBuffer;
- /*===================================================================*
- // Allow space at the beginning of the record for the packet *
- //length which will be computed after the packet is complete. *
- //===================================================================*/
- sddfWriteInteger( &hdfRecordPointer, 0 );
- /*===================================================================*
- // The record type, tag, and name *
- //===================================================================*/
- sddfWriteInteger( &hdfRecordPointer, PKT_DESCRIPTOR );
- sddfWriteInteger( &hdfRecordPointer, ( FAMILY_MISC | RECORD_TRACE ) );
- sddfWriteString( &hdfRecordPointer, "Misc Trace" );
- /*===================================================================*
- // The record attribute count and string pair *
- //===================================================================*/
- sddfWriteInteger( &hdfRecordPointer, 1 );
- sddfWriteString( &hdfRecordPointer, "description" );
- sddfWriteString( &hdfRecordPointer, "Misc Trace Record" );
- /*===================================================================*
- // The record field count *
- //===================================================================*/
- sddfWriteInteger( &hdfRecordPointer, 5);
- /*===================================================================*
- // Create fields *
- //===================================================================*/
- WRITE_HDF_FIELD( "Event Identifier",
- "Event ID",
- "Event Identifier Number",
- INTEGER,
- 0 );
- WRITE_HDF_FIELD( "Seconds",
- "Seconds",
- "Floating Point Timestamp",
- DOUBLE,
- 0 );
- WRITE_HDF_FIELD( "Duration",
- "Duration",
- "Operation Duration",
- DOUBLE,
- 0 );
- WRITE_HDF_FIELD( "Bytes",
- "Bytes",
- "Bytes Requested",
- LONG,
- 0 );
- WRITE_HDF_FIELD( "Processor Number",
- "Node",
- "Processor number",
- INTEGER,
- 0 );
-
- recordLength = (int)(hdfRecordPointer - recordBuffer);
-
- hdfRecordPointer = recordBuffer;
- sddfWriteInteger( &hdfRecordPointer, recordLength );
-
- putBytes( recordBuffer, (unsigned) recordLength );
-}
-
-#endif /* PCF_BUILD */
diff --git a/pablo/PabloHDFff.f b/pablo/PabloHDFff.f
deleted file mode 100644
index 3b39740..0000000
--- a/pablo/PabloHDFff.f
+++ /dev/null
@@ -1,62 +0,0 @@
-C *
-C * This file is an extension to NCSA HDF to enable the use of the
-C * Pablo trace library.
-C *
-C * Developed by: The TAPESTRY Parallel Computing Laboratory
-C * University of Illinois at Urbana-Champaign
-C * Department of Computer Science
-C * 1304 W. Springfield Avenue
-C * Urbana, IL 61801
-C *
-C * Copyright (c) 1995
-C * The University of Illinois Board of Trustees.
-C * All Rights Reserved.
-C *
-C * PABLO is a registered trademark of
-C * The Board of Trustees of the University of Illinois
-C * registered in the U.S. Patent and Trademark Office.
-C *
-C * Author: Jonathan M. Reid (jreid@cs.uiuc.edu)
-C *
-C * Project Manager and Principal Investigator:
-C * Daniel A. Reed (reed@cs.uiuc.edu)
-C *
-C * Funded by: National Aeronautics and Space Administration under NASA
-C * Contracts NAG-1-613 and USRA 5555-22 and by the Advanced Research
-C * Projects Agency under ARPA contracts DAVT63-91-C-0029 and
-C * DABT63-93-C-0040.
-C *
-
-C-----------------------------------------------------------------------------
-C File: PabloHDFff.f
-C Purpose: Fortran stubs for Pablo routines
-C Invokes: PabloHDFf.c
-C Contents:
-C hinitiotrace : Call ihinitiotrace to initialize Pablo tracing
-C Remarks: none
-C-----------------------------------------------------------------------------
-
-C-----------------------------------------------------------------------------
-C Name: hdfinittrace
-C Purpose: call hdfinittracex to initialize tracing
-C Inputs: tracefn: Trace file name
-C proctmask:
-C Returns: 0 on success, FAIL on failure
-C Users:
-C Invokes: hinittracex
-C-----------------------------------------------------------------------------
-
- subroutine hdfinittracef(tracefn,traceids,nids,out_sw)
-
- character*(*) tracefn
- integer traceids(*), out_sw, nids
- character filename(1024)
- integer i, length
-
- length = len(tracefn)
- do i = 1, length
- filename(i) = tracefn(i:i)
- end do
- call hinittracex(filename,length,traceids,nids,out_sw)
- return
- end
diff --git a/pablo/PabloSedscr b/pablo/PabloSedscr
deleted file mode 100644
index 6df38c2..0000000
--- a/pablo/PabloSedscr
+++ /dev/null
@@ -1,31 +0,0 @@
-s/,//g
-/^[0-9]/,/[A-z]/{
-/^[0-9]/h
-/^[0-9]/d
-s/$/ = ID_Begin + /
-G
-s/\n//
-s/[A-z]/ parameter ( &/
-s/$/ )/
-h
-s/parameter (/integer/
-s/=.*//
-G
-}
-/ALLHDF/,$!d
-s/_//g
-/integer.*ALLHDF/{
-i\
- integer RuntimeTrace\
- integer SummaryTrace\
- integer MPIRuntimeTrace\
- integer MPISummaryTrace\
- integer NoTrace\
- integer IDBegin \
- parameter (NoTrace = 0)\
- parameter (RuntimeTrace = 1)\
- parameter (SummaryTrace = 2)\
- parameter (MPIRuntimeTrace = 3)\
- parameter (MPISummaryTrace = 4)\
- parameter ( IDBegin = 4 )
-}
diff --git a/pablo/ProcIDs.h b/pablo/ProcIDs.h
deleted file mode 100644
index 3370037..0000000
--- a/pablo/ProcIDs.h
+++ /dev/null
@@ -1,165 +0,0 @@
-/* This file is part of the Pablo Performance Analysis Environment
-//
-// (R)
-// The Pablo Performance Analysis Environment software is NOT in
-// the public domain. However, it is freely available without fee for
-// education, research, and non-profit purposes. By obtaining copies
-// of this and other files that comprise the Pablo Performance Analysis
-// Environment, you, the Licensee, agree to abide by the following
-// conditions and understandings with respect to the copyrighted software:
-//
-// 1. The software is copyrighted in the name of the Board of Trustees
-// of the University of Illinois (UI), and ownership of the software
-// remains with the UI.
-//
-// 2. Permission to use, copy, and modify this software and its documentation
-// for education, research, and non-profit purposes is hereby granted
-// to Licensee, provided that the copyright notice, the original author's
-// names and unit identification, and this permission notice appear on
-// all such copies, and that no charge be made for such copies. Any
-// entity desiring permission to incorporate this software into commercial
-// products should contact:
-//
-// Professor Daniel A. Reed reed@cs.uiuc.edu
-// University of Illinois
-// Department of Computer Science
-// 2413 Digital Computer Laboratory
-// 1304 West Springfield Avenue
-// Urbana, Illinois 61801
-// USA
-//
-// 3. Licensee may not use the name, logo, or any other symbol of the UI
-// nor the names of any of its employees nor any adaptation thereof in
-// advertizing or publicity pertaining to the software without specific
-// prior written approval of the UI.
-//
-// 4. THE UI MAKES NO REPRESENTATIONS ABOUT THE SUITABILITY OF THE
-// SOFTWARE FOR ANY PURPOSE. IT IS PROVIDED "AS IS" WITHOUT EXPRESS
-// OR IMPLIED WARRANTY.
-//
-// 5. The UI shall not be liable for any damages suffered by Licensee from
-// the use of this software.
-//
-// 6. The software was developed under agreements between the UI and the
-// Federal Government which entitle the Government to certain rights.
-//
-// *************************************************************************
-//
-// Developed by: The Pablo Research Group
-// University of Illinois at Urbana-Champaign
-// Department of Computer Science
-// 1304 W. Springfield Avenue
-// Urbana, IL 61801
-//
-// http://www-pablo.cs.uiuc.edu
-//
-// Send comments to: pablo-feedback@guitar.cs.uiuc.edu
-//
-// Copyright (c) 1987-1998
-// The University of Illinois Board of Trustees.
-// All Rights Reserved.
-//
-// PABLO is a registered trademark of
-// The Board of Trustees of the University of Illinois
-// registered in the U.S. Patent and Trademark Office.
-//
-// Project Manager and Principal Investigator:
-// Daniel A. Reed (reed@cs.uiuc.edu)
-//
-// Funded in part by the Defense Advanced Research Projects Agency under
-// DARPA contracts DABT63-94-C0049 (SIO Initiative), F30602-96-C-0161,
-// and DABT63-96-C-0027 by the National Science Foundation under the PACI
-// program and grants NSF CDA 94-01124 and ASC 97-20202, and by the
-// Department of Energy under contracts DOE B-341494, W-7405-ENG-48, and
-// 1-B-333164.
-//-------------------------------------------------------------------------*/
-/*--------------------------------------------------------------------------
- * File: ProcIDs.h
- * Purpose: define IDs for identifying procedures in traces
- *-------------------------------------------------------------------------*/
-
-#ifndef PROCIDS_H /* avoid re-inclusion */
-#define PROCIDS_H
-
-extern int *procTrace;
-/*
- * Define the event IDs that will be used for the various HDF events
- */
-#include "ProcTrace.h"
-
-#include "ProcMasks.h"
-
-#define ID_HDFprocName 9996
-#define ID_malloc 9997
-#define ID_free 9998
-#define ID_timeStamp 9999
-#define DUMMY_HDF 10000
-
-#define BEGIN_HDF (DUMMY_HDF + 1)
-#define END_HDF (ID_HDF_Last_Entry + DUMMY_HDF)
-#define NumHDFProcs ( ID_HDF_Last_Entry )
-
-enum MPIeventIDs {
- BEGIN_MPIO = END_HDF+1,
- HDFmpiOpenID = BEGIN_MPIO,
- HDFmpiCloseID,
- HDFmpiDeleteID,
- HDFmpiSetSizeID,
- HDFmpiPreallocateID,
- HDFmpiGetSizeID,
- HDFmpiGetGroupID,
- HDFmpiGetAmodeID,
- HDFmpiGetViewID,
- HDFmpiSetViewID,
- HDFmpiReadAtID,
- HDFmpiReadAtAllID,
- HDFmpiWriteAtID,
- HDFmpiWriteAtAllID,
- HDFmpiReadID,
- HDFmpiReadAllID,
- HDFmpiWriteID,
- HDFmpiWriteAllID,
- HDFmpiSeekID,
- HDFmpiGetPositionID,
- HDFmpiGetByteOffsetID,
- HDFmpiGetTypeExtentID,
- HDFmpiSetAtomicityID,
- HDFmpiGetAtomicityID,
- HDFmpiIreadID,
- HDFmpiIwriteID,
- HDFmpiIreadAtID,
- HDFmpiIwriteAtID,
- HDFmpiSyncID,
- END_MPIO
-};
-
-/*======================================================================*/
-/* Macros to tell if the ID is that of an HDF Entry or Exit */
-/*======================================================================*/
-#define isBeginHDFEvent( ID ) ( BEGIN_HDF <= (ID) && (ID) <= END_HDF )
-#define isEndHDFEvent( ID ) isBeginHDFEvent(-(ID))
-#define isBeginMPIOEvent( ID ) \
- ( BEGIN_MPIO <= (ID) && (ID) <= END_MPIO )
-#define isEndMPIOEvent( ID ) isBeginMPIOEvent(-(ID))
-#define isBeginIOEvent( ID ) \
- ( IOerrorID < (ID) && (ID) <= fsetposEndID && (ID)%2 == 1 )
-#define isEndIOEvent( ID ) \
- ( IOerrorID < (ID) && (ID) <= fsetposEndID && (ID)%2 == 0 )
-#define ProcIndex( ID ) ( (ID) - BEGIN_HDF )
-#define ProcIndexForHDFEntry( ID ) ( (ID) - BEGIN_HDF )
-#define ProcIndexForHDFExit( ID ) ProcIndexForHDFEntry(-ID)
-#define HDFIXtoEventID( ID ) ( (ID) + BEGIN_HDF )
-
-#ifdef PCF_BUILD
-#define TRACE_ON(mask, ID) \
-if ( procTrace[mask] || procTrace[ID] ) startHDFtraceEvent( ID )
-#define TRACE_OFF(mask, ID ) \
-if ( procTrace[mask] || procTrace[ID] ) endHDFtraceEvent( ID, 0, NULL, 0 )
-#else
-#define TRACE_ON(mask, ID) \
-if ( procTrace[mask] || procTrace[ID] ) startHDFtraceEvent( HDFIXtoEventID( ID ) )
-#define TRACE_OFF(mask, ID ) \
-if ( procTrace[mask] || procTrace[ID] ) endHDFtraceEvent(-HDFIXtoEventID(ID), 0, NULL, 0 )
-#endif /* PCF_BUILD */
-
-#endif /* PROCIDS_H */
diff --git a/pablo/ProcTrace.h b/pablo/ProcTrace.h
deleted file mode 100644
index e9e3d31..0000000
--- a/pablo/ProcTrace.h
+++ /dev/null
@@ -1,108 +0,0 @@
-/* This file is part of the Pablo Performance Analysis Environment
-//
-// (R)
-// The Pablo Performance Analysis Environment software is NOT in
-// the public domain. However, it is freely available without fee for
-// education, research, and non-profit purposes. By obtaining copies
-// of this and other files that comprise the Pablo Performance Analysis
-// Environment, you, the Licensee, agree to abide by the following
-// conditions and understandings with respect to the copyrighted software:
-//
-// 1. The software is copyrighted in the name of the Board of Trustees
-// of the University of Illinois (UI), and ownership of the software
-// remains with the UI.
-//
-// 2. Permission to use, copy, and modify this software and its documentation
-// for education, research, and non-profit purposes is hereby granted
-// to Licensee, provided that the copyright notice, the original author's
-// names and unit identification, and this permission notice appear on
-// all such copies, and that no charge be made for such copies. Any
-// entity desiring permission to incorporate this software into commercial
-// products should contact:
-//
-// Professor Daniel A. Reed reed@cs.uiuc.edu
-// University of Illinois
-// Department of Computer Science
-// 2413 Digital Computer Laboratory
-// 1304 West Springfield Avenue
-// Urbana, Illinois 61801
-// USA
-//
-// 3. Licensee may not use the name, logo, or any other symbol of the UI
-// nor the names of any of its employees nor any adaptation thereof in
-// advertizing or publicity pertaining to the software without specific
-// prior written approval of the UI.
-//
-// 4. THE UI MAKES NO REPRESENTATIONS ABOUT THE SUITABILITY OF THE
-// SOFTWARE FOR ANY PURPOSE. IT IS PROVIDED "AS IS" WITHOUT EXPRESS
-// OR IMPLIED WARRANTY.
-//
-// 5. The UI shall not be liable for any damages suffered by Licensee from
-// the use of this software.
-//
-// 6. The software was developed under agreements between the UI and the
-// Federal Government which entitle the Government to certain rights.
-//
-// *************************************************************************
-//
-// Developed by: The Pablo Research Group
-// University of Illinois at Urbana-Champaign
-// Department of Computer Science
-// 1304 W. Springfield Avenue
-// Urbana, IL 61801
-//
-// http://www-pablo.cs.uiuc.edu
-//
-// Send comments to: pablo-feedback@guitar.cs.uiuc.edu
-//
-// Copyright (c) 1987-1998
-// The University of Illinois Board of Trustees.
-// All Rights Reserved.
-//
-// PABLO is a registered trademark of
-// The Board of Trustees of the University of Illinois
-// registered in the U.S. Patent and Trademark Office.
-//
-// Project Manager and Principal Investigator:
-// Daniel A. Reed (reed@cs.uiuc.edu)
-//
-// Funded in part by the Defense Advanced Research Projects Agency under
-// DARPA contracts DABT63-94-C0049 (SIO Initiative), F30602-96-C-0161,
-// and DABT63-96-C-0027 by the National Science Foundation under the PACI
-// program and grants NSF CDA 94-01124 and ASC 97-20202, and by the
-// Department of Energy under contracts DOE B-341494, W-7405-ENG-48, and
-// 1-B-333164.
-//-------------------------------------------------------------------------*/
-/*--------------------------------------------------------------------------
- * File: ProcTrace.h
- * Purpose: define entities for tracing HDF procedures
- *-------------------------------------------------------------------------*/
-
-#ifndef PROCTRACE_H /* avoid re-inclusion */
-#define PROCTRACE_H
-#include <stdarg.h>
-/*======================================================================*/
-/* Assign HDF identifier routine tags */
-/*======================================================================*/
-#ifdef RUNTIME_TRACE
-#undef RUNTIME_TRACE
-#endif
-enum HDF_IDS {
-NO_TRACE = 0,
-RUNTIME_TRACE = 1,
-SUMMARY_TRACE,
-MPI_RUNTIME_TRACE,
-MPI_SUMMARY_TRACE,
-DETAILED=RUNTIME_TRACE,
-LAST_TRACE_TYPE=MPI_SUMMARY_TRACE,
-#include "HDFidList.h"
-NUM_HDF_IDS
-} ;
-
-#define SUPPRESS_MPIO_TRACE 6
-#define ID_HDF_Last_Entry ID_ALLHDF
-
-void HDFinitTrace( const char *, int procNum, int trace_id, ... );
-void HDFendTrace( void );
-void setHDFcallLevel( int );
-#endif /* PROCTRACE_H */
diff --git a/pablo/READ_ME b/pablo/READ_ME
deleted file mode 100644
index bebf43c..0000000
--- a/pablo/READ_ME
+++ /dev/null
@@ -1,18 +0,0 @@
-To build the Pablo Instrumented version of the HDF 5 library
-
-1) Configure the system as normal from the parent directory
-
-2) Make the normal HDF 5 library
-
-3) set the environment variable PABLO_TRACELIB to the path of the directory
- continaining the Pablo TraceLibrary. This directory should contain the
- lib and include directories as subdirectories
-
-4) If building to instrument MPI programs, uncomment the line beginning
- PABLO_MPI_FLAGS. In this case, the Pablo TraceLibrary should be built
- to trace the MPI-I/O calls.
-
-5) If you are going to link with the Pablo TraceLibraries, issue the
- make or make install commands
- If you are going to link with the Pablo PCF, issue one of the commands
- make PABLO_BLD=PCF or make PABLO_BLD=PCF install