[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
#!/usr/bin/perl -w
|
2004-12-29 22:26:20 +08:00
|
|
|
##
|
|
|
|
## 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.
|
|
|
|
##
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
require 5.003;
|
|
|
|
$Source = "";
|
|
|
|
|
|
|
|
##############################################################################
|
|
|
|
# A map from type name to type letter. We use this map for two reasons:
|
|
|
|
# 1. We want the debugging stuff in the source code to be as unobtrusive as
|
|
|
|
# possible, which means as compact as possible.
|
|
|
|
# 2. It's easier (faster) to parse these one and two-letter types in the C
|
|
|
|
# functions that display debugging results.
|
|
|
|
#
|
|
|
|
# All type strings are one or two characters. One-character strings
|
|
|
|
# are always lower case and should be used for common types.
|
|
|
|
# Two-character strings begin with an upper-case letter which is
|
|
|
|
# usually the same as the package name.
|
|
|
|
#
|
2003-10-08 05:10:53 +08:00
|
|
|
%TypeString = ("haddr_t" => "a",
|
|
|
|
"hbool_t" => "b",
|
|
|
|
"double" => "d",
|
2006-11-18 05:02:48 +08:00
|
|
|
"H5_iter_order_t" => "Io",
|
2006-12-12 08:42:19 +08:00
|
|
|
"H5_index_t" => "Ii",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5D_alloc_time_t" => "Da",
|
|
|
|
"H5D_fill_time_t" => "Df",
|
|
|
|
"H5D_fill_value_t" => "DF",
|
|
|
|
"H5D_layout_t" => "Dl",
|
2003-10-14 23:46:38 +08:00
|
|
|
"H5D_space_status_t" => "Ds",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5FD_mpio_xfer_t" => "Dt",
|
|
|
|
"herr_t" => "e",
|
|
|
|
"H5E_direction_t" => "Ed",
|
|
|
|
"H5E_error_t*" => "Ee",
|
2003-10-14 23:46:38 +08:00
|
|
|
"H5E_major_t" => "i",
|
|
|
|
"H5E_minor_t" => "i",
|
|
|
|
"H5E_type_t" => "Et",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5F_close_degree_t" => "Fd",
|
|
|
|
"H5F_scope_t" => "Fs",
|
2003-10-14 23:46:38 +08:00
|
|
|
"H5G_obj_t" => "Go",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5G_stat_t*" => "Gs",
|
2006-10-02 18:24:03 +08:00
|
|
|
"H5L_type_t" => "Ll",
|
2006-08-03 07:41:53 +08:00
|
|
|
"unsigned long" => "Lu",
|
2003-10-08 05:10:53 +08:00
|
|
|
"hsize_t" => "h",
|
|
|
|
"hssize_t" => "Hs",
|
|
|
|
"hid_t" => "i",
|
|
|
|
"int" => "Is",
|
2005-04-29 00:40:07 +08:00
|
|
|
"int32_t" => "Is",
|
2003-10-08 05:10:53 +08:00
|
|
|
"unsigned" => "Iu",
|
|
|
|
"unsigned int" => "Iu",
|
|
|
|
"H5I_type_t" => "It",
|
|
|
|
"MPI_Comm" => "Mc",
|
|
|
|
"MPI_Info" => "Mi",
|
|
|
|
"H5FD_mem_t" => "Mt",
|
|
|
|
"off_t" => "o",
|
|
|
|
"H5P_class_t" => "p",
|
|
|
|
"H5R_type_t" => "Rt",
|
|
|
|
"char*" => "s",
|
|
|
|
"H5S_class_t" => "Sc",
|
|
|
|
"H5S_seloper_t" => "Ss",
|
|
|
|
"H5S_sel_type" => "St",
|
2004-06-30 05:03:33 +08:00
|
|
|
"htri_t" => "t",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5T_cset_t", => "Tc",
|
|
|
|
"H5T_direction_t", => "Td",
|
|
|
|
"H5T_norm_t" => "Tn",
|
|
|
|
"H5T_order_t" => "To",
|
|
|
|
"H5T_pad_t" => "Tp",
|
|
|
|
"H5T_pers_t" => "Te",
|
|
|
|
"H5T_sign_t" => "Ts",
|
|
|
|
"H5T_class_t" => "Tt",
|
|
|
|
"H5T_str_t" => "Tz",
|
|
|
|
"void*" => "x",
|
|
|
|
"void**" => "x",
|
|
|
|
"FILE*" => "x",
|
|
|
|
"H5A_operator_t" => "x",
|
2006-11-18 05:02:48 +08:00
|
|
|
"H5AC_cache_config_t*" => "x",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5D_operator_t" => "x",
|
|
|
|
"H5E_auto_t" => "x",
|
2006-11-18 05:02:48 +08:00
|
|
|
"H5E_auto_stack_t" => "x",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5E_walk_t" => "x",
|
2006-11-18 05:02:48 +08:00
|
|
|
"H5E_walk_stack_t" => "x",
|
|
|
|
"H5FD_t*" => "x",
|
|
|
|
"H5FD_class_t*" => "x",
|
|
|
|
"H5FD_stream_fapl_t*" => "x",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5G_iterate_t" => "x",
|
2006-10-02 18:24:03 +08:00
|
|
|
"H5L_class_t" => "x",
|
2006-11-18 05:02:48 +08:00
|
|
|
"H5L_iterate_t" => "x",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5MM_allocate_t" => "x",
|
|
|
|
"H5MM_free_t" => "x",
|
|
|
|
"H5P_cls_create_func_t" => "x",
|
|
|
|
"H5P_cls_copy_func_t" => "x",
|
|
|
|
"H5P_cls_close_func_t" => "x",
|
|
|
|
"H5P_iterate_t" => "x",
|
|
|
|
"H5P_prp_create_func_t" => "x",
|
|
|
|
"H5P_prp_copy_func_t" => "x",
|
|
|
|
"H5P_prp_close_func_t" => "x",
|
|
|
|
"H5P_prp_delete_func_t" => "x",
|
|
|
|
"H5P_prp_get_func_t" => "x",
|
|
|
|
"H5P_prp_set_func_t" => "x",
|
|
|
|
"H5T_cdata_t**" => "x",
|
|
|
|
"H5T_conv_t" => "x",
|
2004-06-30 05:03:33 +08:00
|
|
|
"H5T_conv_except_func_t" => "x",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5Z_func_t" => "x",
|
|
|
|
"H5Z_filter_func_t" => "x",
|
|
|
|
"size_t" => "z",
|
2005-11-18 23:55:22 +08:00
|
|
|
"H5Z_SO_scale_type_t" => "Za",
|
2003-10-14 23:46:38 +08:00
|
|
|
"H5Z_class_t*" => "Zc",
|
2003-10-08 05:10:53 +08:00
|
|
|
"H5Z_EDC_t" => "Ze",
|
|
|
|
"H5Z_filter_t" => "Zf",
|
|
|
|
"ssize_t" => "Zs",
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
);
|
|
|
|
|
|
|
|
##############################################################################
|
|
|
|
# Print an error message.
|
|
|
|
#
|
|
|
|
sub errmesg ($$@) {
|
|
|
|
my ($file, $func, @mesg) = @_;
|
|
|
|
my ($mesg) = join "", @mesg;
|
|
|
|
my ($lineno) = 1;
|
|
|
|
if ($Source =~ /(.*?\n)($func)/s) {
|
|
|
|
local $_ = $1;
|
|
|
|
$lineno = tr/\n/\n/;
|
|
|
|
}
|
|
|
|
|
|
|
|
print "$file: in function \`$func\':\n";
|
|
|
|
print "$file:$lineno: $mesg\n";
|
|
|
|
}
|
|
|
|
|
|
|
|
##############################################################################
|
|
|
|
# Given a C data type return the type string that goes with it.
|
|
|
|
#
|
|
|
|
sub argstring ($$$) {
|
|
|
|
my ($file, $func, $atype) = @_;
|
[svn-r526] Changes since 19980721
----------------------
./tools/h5ls.c
If the dataset is of type H5T_NATIVE_CHAR then we print the
value as a string. This is temporary -- I plan to add better
control of this later but needed something now for debugging.
./src/H5Fistore.c
Squashed a bug in the chunk caching code that caused the wrong
chunk to be returned.
./bin/trace
./src/H5.c
Added support for printing values of array arguments when the
size of the array is supplied by some previous argument. You
must declare the argument as an array in order for the
automatic tracing stuff to work. For instance, the third
argument of H5Pset_chunk() is an array whose size is
determined by the second argument `ndims'. Here's how you
should declare it:
herr_t
H5Pset_chunk(hid_t plist_id, intn rank, hsize_t dims[/*rank*/])
The comment inside the `[]' is the name of some previous
integer argument (int, unsigned, size_t, ssize_t, hsize_t,
hssize_t). The trace output will look something like:
H5Pset_chunk(plist=1234567, rank=2, dims=0x112233 {11, 22})
Changed tracing so that data types are printed out
symbolically when possible.
Changed tracing so data type initializations are not printed.
This used to be confusing because lots of H5Tcopy() and
H5Tregister...() calls showed up before the applications first
explicit API call.
./src/H5Ipublic.h
Changed the file atom group from zero to one so printing of
atoms during tracing is more consistent -- they're all big
numbers now.
./src/H5A.c
./src/H5E.c
./src/H5F.c
./src/H5G.c
./src/H5Sselect.c
./src/H5T.c
./src/H5TB.c
./src/H5Z.c
Accidently modified these when working on the tracing, but
nothing should have changed.
./src/H5P.c
Changed the definition of H5Pset_chunk() for tracing.
./src/H5S.c
./src/H5Spublic.h
Changed the definitions of H5Sset_extent_simple() and
H5Screate_simple() for tracing. Changed the FUNC_ENTER() name
for H5Screate_simple() so tracing shows the correct name.
1998-07-22 21:51:51 +08:00
|
|
|
my ($ptr, $tstr, $array) = (0, "!", "");
|
1998-07-08 04:13:31 +08:00
|
|
|
my ($fq_atype);
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
|
|
|
|
# Normalize the data type by removing redundant white space,
|
|
|
|
# certain type qualifiers, and indirection.
|
|
|
|
$atype =~ s/^\bconst\b//;
|
1999-04-30 23:54:52 +08:00
|
|
|
$atype =~ s/\bUNUSED\b//g;
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
$atype =~ s/\s+/ /g;
|
|
|
|
$ptr = length $1 if $atype =~ s/(\*+)//;
|
|
|
|
$atype =~ s/^\s+//;
|
|
|
|
$atype =~ s/\s+$//;
|
[svn-r526] Changes since 19980721
----------------------
./tools/h5ls.c
If the dataset is of type H5T_NATIVE_CHAR then we print the
value as a string. This is temporary -- I plan to add better
control of this later but needed something now for debugging.
./src/H5Fistore.c
Squashed a bug in the chunk caching code that caused the wrong
chunk to be returned.
./bin/trace
./src/H5.c
Added support for printing values of array arguments when the
size of the array is supplied by some previous argument. You
must declare the argument as an array in order for the
automatic tracing stuff to work. For instance, the third
argument of H5Pset_chunk() is an array whose size is
determined by the second argument `ndims'. Here's how you
should declare it:
herr_t
H5Pset_chunk(hid_t plist_id, intn rank, hsize_t dims[/*rank*/])
The comment inside the `[]' is the name of some previous
integer argument (int, unsigned, size_t, ssize_t, hsize_t,
hssize_t). The trace output will look something like:
H5Pset_chunk(plist=1234567, rank=2, dims=0x112233 {11, 22})
Changed tracing so that data types are printed out
symbolically when possible.
Changed tracing so data type initializations are not printed.
This used to be confusing because lots of H5Tcopy() and
H5Tregister...() calls showed up before the applications first
explicit API call.
./src/H5Ipublic.h
Changed the file atom group from zero to one so printing of
atoms during tracing is more consistent -- they're all big
numbers now.
./src/H5A.c
./src/H5E.c
./src/H5F.c
./src/H5G.c
./src/H5Sselect.c
./src/H5T.c
./src/H5TB.c
./src/H5Z.c
Accidently modified these when working on the tracing, but
nothing should have changed.
./src/H5P.c
Changed the definition of H5Pset_chunk() for tracing.
./src/H5S.c
./src/H5Spublic.h
Changed the definitions of H5Sset_extent_simple() and
H5Screate_simple() for tracing. Changed the FUNC_ENTER() name
for H5Screate_simple() so tracing shows the correct name.
1998-07-22 21:51:51 +08:00
|
|
|
if ($atype =~ /(.*)\[(.*)\]$/) {
|
|
|
|
($array, $atype) = ($2, $1);
|
1998-08-28 00:48:50 +08:00
|
|
|
$atype =~ s/\s+$//;
|
[svn-r526] Changes since 19980721
----------------------
./tools/h5ls.c
If the dataset is of type H5T_NATIVE_CHAR then we print the
value as a string. This is temporary -- I plan to add better
control of this later but needed something now for debugging.
./src/H5Fistore.c
Squashed a bug in the chunk caching code that caused the wrong
chunk to be returned.
./bin/trace
./src/H5.c
Added support for printing values of array arguments when the
size of the array is supplied by some previous argument. You
must declare the argument as an array in order for the
automatic tracing stuff to work. For instance, the third
argument of H5Pset_chunk() is an array whose size is
determined by the second argument `ndims'. Here's how you
should declare it:
herr_t
H5Pset_chunk(hid_t plist_id, intn rank, hsize_t dims[/*rank*/])
The comment inside the `[]' is the name of some previous
integer argument (int, unsigned, size_t, ssize_t, hsize_t,
hssize_t). The trace output will look something like:
H5Pset_chunk(plist=1234567, rank=2, dims=0x112233 {11, 22})
Changed tracing so that data types are printed out
symbolically when possible.
Changed tracing so data type initializations are not printed.
This used to be confusing because lots of H5Tcopy() and
H5Tregister...() calls showed up before the applications first
explicit API call.
./src/H5Ipublic.h
Changed the file atom group from zero to one so printing of
atoms during tracing is more consistent -- they're all big
numbers now.
./src/H5A.c
./src/H5E.c
./src/H5F.c
./src/H5G.c
./src/H5Sselect.c
./src/H5T.c
./src/H5TB.c
./src/H5Z.c
Accidently modified these when working on the tracing, but
nothing should have changed.
./src/H5P.c
Changed the definition of H5Pset_chunk() for tracing.
./src/H5S.c
./src/H5Spublic.h
Changed the definitions of H5Sset_extent_simple() and
H5Screate_simple() for tracing. Changed the FUNC_ENTER() name
for H5Screate_simple() so tracing shows the correct name.
1998-07-22 21:51:51 +08:00
|
|
|
}
|
1998-07-08 04:13:31 +08:00
|
|
|
$fq_atype = $atype . ('*' x $ptr);
|
|
|
|
|
|
|
|
if ($ptr>0 && exists $TypeString{$fq_atype}) {
|
|
|
|
$ptr = 0;
|
|
|
|
$tstr = $TypeString{$fq_atype};
|
|
|
|
} elsif ($ptr>0 && exists $TypeString{"$atype*"}) {
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
--$ptr;
|
|
|
|
$tstr = $TypeString{"$atype*"};
|
|
|
|
} elsif (!exists $TypeString{$atype}) {
|
2000-11-11 04:45:33 +08:00
|
|
|
errmesg $file, $func, "untraceable type \`$atype", '*'x$ptr, "\'";
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
} else {
|
|
|
|
$tstr = $TypeString{$atype};
|
|
|
|
}
|
[svn-r526] Changes since 19980721
----------------------
./tools/h5ls.c
If the dataset is of type H5T_NATIVE_CHAR then we print the
value as a string. This is temporary -- I plan to add better
control of this later but needed something now for debugging.
./src/H5Fistore.c
Squashed a bug in the chunk caching code that caused the wrong
chunk to be returned.
./bin/trace
./src/H5.c
Added support for printing values of array arguments when the
size of the array is supplied by some previous argument. You
must declare the argument as an array in order for the
automatic tracing stuff to work. For instance, the third
argument of H5Pset_chunk() is an array whose size is
determined by the second argument `ndims'. Here's how you
should declare it:
herr_t
H5Pset_chunk(hid_t plist_id, intn rank, hsize_t dims[/*rank*/])
The comment inside the `[]' is the name of some previous
integer argument (int, unsigned, size_t, ssize_t, hsize_t,
hssize_t). The trace output will look something like:
H5Pset_chunk(plist=1234567, rank=2, dims=0x112233 {11, 22})
Changed tracing so that data types are printed out
symbolically when possible.
Changed tracing so data type initializations are not printed.
This used to be confusing because lots of H5Tcopy() and
H5Tregister...() calls showed up before the applications first
explicit API call.
./src/H5Ipublic.h
Changed the file atom group from zero to one so printing of
atoms during tracing is more consistent -- they're all big
numbers now.
./src/H5A.c
./src/H5E.c
./src/H5F.c
./src/H5G.c
./src/H5Sselect.c
./src/H5T.c
./src/H5TB.c
./src/H5Z.c
Accidently modified these when working on the tracing, but
nothing should have changed.
./src/H5P.c
Changed the definition of H5Pset_chunk() for tracing.
./src/H5S.c
./src/H5Spublic.h
Changed the definitions of H5Sset_extent_simple() and
H5Screate_simple() for tracing. Changed the FUNC_ENTER() name
for H5Screate_simple() so tracing shows the correct name.
1998-07-22 21:51:51 +08:00
|
|
|
return ("*" x $ptr) . ($array?"[$array]":"") . $tstr;
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
##############################################################################
|
|
|
|
# Given information about an API function, rewrite that function with
|
|
|
|
# updated tracing information.
|
|
|
|
#
|
|
|
|
sub rewrite_func ($$$$$) {
|
|
|
|
my ($file, $type, $name, $args, $body) = @_;
|
|
|
|
my ($arg,$trace);
|
|
|
|
my (@arg_name, @arg_str);
|
|
|
|
local $_;
|
|
|
|
|
|
|
|
# Parse return value
|
|
|
|
my $rettype = argstring $file, $name, $type;
|
|
|
|
goto error if $rettype =~ /!/;
|
|
|
|
|
|
|
|
# Parse arguments
|
|
|
|
if ($args eq "void") {
|
1998-07-08 04:13:31 +08:00
|
|
|
$trace = "H5TRACE0(\"$rettype\",\"\");\n";
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
} else {
|
1998-07-08 04:13:31 +08:00
|
|
|
# Split arguments. First convert `/*in,out*/' to get rid of the
|
|
|
|
# comma, then split the arguments on commas.
|
|
|
|
$args =~ s/(\/\*\s*in),\s*(out\s*\*\/)/$1_$2/g;
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
my @args = split /,[\s\n]*/, $args;
|
[svn-r526] Changes since 19980721
----------------------
./tools/h5ls.c
If the dataset is of type H5T_NATIVE_CHAR then we print the
value as a string. This is temporary -- I plan to add better
control of this later but needed something now for debugging.
./src/H5Fistore.c
Squashed a bug in the chunk caching code that caused the wrong
chunk to be returned.
./bin/trace
./src/H5.c
Added support for printing values of array arguments when the
size of the array is supplied by some previous argument. You
must declare the argument as an array in order for the
automatic tracing stuff to work. For instance, the third
argument of H5Pset_chunk() is an array whose size is
determined by the second argument `ndims'. Here's how you
should declare it:
herr_t
H5Pset_chunk(hid_t plist_id, intn rank, hsize_t dims[/*rank*/])
The comment inside the `[]' is the name of some previous
integer argument (int, unsigned, size_t, ssize_t, hsize_t,
hssize_t). The trace output will look something like:
H5Pset_chunk(plist=1234567, rank=2, dims=0x112233 {11, 22})
Changed tracing so that data types are printed out
symbolically when possible.
Changed tracing so data type initializations are not printed.
This used to be confusing because lots of H5Tcopy() and
H5Tregister...() calls showed up before the applications first
explicit API call.
./src/H5Ipublic.h
Changed the file atom group from zero to one so printing of
atoms during tracing is more consistent -- they're all big
numbers now.
./src/H5A.c
./src/H5E.c
./src/H5F.c
./src/H5G.c
./src/H5Sselect.c
./src/H5T.c
./src/H5TB.c
./src/H5Z.c
Accidently modified these when working on the tracing, but
nothing should have changed.
./src/H5P.c
Changed the definition of H5Pset_chunk() for tracing.
./src/H5S.c
./src/H5Spublic.h
Changed the definitions of H5Sset_extent_simple() and
H5Screate_simple() for tracing. Changed the FUNC_ENTER() name
for H5Screate_simple() so tracing shows the correct name.
1998-07-22 21:51:51 +08:00
|
|
|
my $argno = 0;
|
|
|
|
my %names;
|
1998-07-08 04:13:31 +08:00
|
|
|
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
for $arg (@args) {
|
|
|
|
unless ($arg=~/^(([a-z_A-Z]\w*\s+)+\**)
|
[svn-r526] Changes since 19980721
----------------------
./tools/h5ls.c
If the dataset is of type H5T_NATIVE_CHAR then we print the
value as a string. This is temporary -- I plan to add better
control of this later but needed something now for debugging.
./src/H5Fistore.c
Squashed a bug in the chunk caching code that caused the wrong
chunk to be returned.
./bin/trace
./src/H5.c
Added support for printing values of array arguments when the
size of the array is supplied by some previous argument. You
must declare the argument as an array in order for the
automatic tracing stuff to work. For instance, the third
argument of H5Pset_chunk() is an array whose size is
determined by the second argument `ndims'. Here's how you
should declare it:
herr_t
H5Pset_chunk(hid_t plist_id, intn rank, hsize_t dims[/*rank*/])
The comment inside the `[]' is the name of some previous
integer argument (int, unsigned, size_t, ssize_t, hsize_t,
hssize_t). The trace output will look something like:
H5Pset_chunk(plist=1234567, rank=2, dims=0x112233 {11, 22})
Changed tracing so that data types are printed out
symbolically when possible.
Changed tracing so data type initializations are not printed.
This used to be confusing because lots of H5Tcopy() and
H5Tregister...() calls showed up before the applications first
explicit API call.
./src/H5Ipublic.h
Changed the file atom group from zero to one so printing of
atoms during tracing is more consistent -- they're all big
numbers now.
./src/H5A.c
./src/H5E.c
./src/H5F.c
./src/H5G.c
./src/H5Sselect.c
./src/H5T.c
./src/H5TB.c
./src/H5Z.c
Accidently modified these when working on the tracing, but
nothing should have changed.
./src/H5P.c
Changed the definition of H5Pset_chunk() for tracing.
./src/H5S.c
./src/H5Spublic.h
Changed the definitions of H5Sset_extent_simple() and
H5Screate_simple() for tracing. Changed the FUNC_ENTER() name
for H5Screate_simple() so tracing shows the correct name.
1998-07-22 21:51:51 +08:00
|
|
|
([a-z_A-Z]\w*)(\[.*?\])?
|
1998-07-08 04:13:31 +08:00
|
|
|
(\s*\/\*\s*(in|out|in_out)\s*\*\/)?\s*$/x) {
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
errmesg $file, $name, "unable to parse \`$arg\'";
|
|
|
|
goto error;
|
|
|
|
} else {
|
|
|
|
my ($atype, $aname, $array, $adir) = ($1, $3, $4, $6);
|
[svn-r526] Changes since 19980721
----------------------
./tools/h5ls.c
If the dataset is of type H5T_NATIVE_CHAR then we print the
value as a string. This is temporary -- I plan to add better
control of this later but needed something now for debugging.
./src/H5Fistore.c
Squashed a bug in the chunk caching code that caused the wrong
chunk to be returned.
./bin/trace
./src/H5.c
Added support for printing values of array arguments when the
size of the array is supplied by some previous argument. You
must declare the argument as an array in order for the
automatic tracing stuff to work. For instance, the third
argument of H5Pset_chunk() is an array whose size is
determined by the second argument `ndims'. Here's how you
should declare it:
herr_t
H5Pset_chunk(hid_t plist_id, intn rank, hsize_t dims[/*rank*/])
The comment inside the `[]' is the name of some previous
integer argument (int, unsigned, size_t, ssize_t, hsize_t,
hssize_t). The trace output will look something like:
H5Pset_chunk(plist=1234567, rank=2, dims=0x112233 {11, 22})
Changed tracing so that data types are printed out
symbolically when possible.
Changed tracing so data type initializations are not printed.
This used to be confusing because lots of H5Tcopy() and
H5Tregister...() calls showed up before the applications first
explicit API call.
./src/H5Ipublic.h
Changed the file atom group from zero to one so printing of
atoms during tracing is more consistent -- they're all big
numbers now.
./src/H5A.c
./src/H5E.c
./src/H5F.c
./src/H5G.c
./src/H5Sselect.c
./src/H5T.c
./src/H5TB.c
./src/H5Z.c
Accidently modified these when working on the tracing, but
nothing should have changed.
./src/H5P.c
Changed the definition of H5Pset_chunk() for tracing.
./src/H5S.c
./src/H5Spublic.h
Changed the definitions of H5Sset_extent_simple() and
H5Screate_simple() for tracing. Changed the FUNC_ENTER() name
for H5Screate_simple() so tracing shows the correct name.
1998-07-22 21:51:51 +08:00
|
|
|
$names{$aname} = $argno++;
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
$adir ||= "in";
|
|
|
|
$atype =~ s/\s+$//;
|
|
|
|
push @arg_name, $aname;
|
1998-07-08 04:13:31 +08:00
|
|
|
|
|
|
|
if ($adir eq "out") {
|
|
|
|
push @arg_str, "x";
|
|
|
|
} else {
|
[svn-r526] Changes since 19980721
----------------------
./tools/h5ls.c
If the dataset is of type H5T_NATIVE_CHAR then we print the
value as a string. This is temporary -- I plan to add better
control of this later but needed something now for debugging.
./src/H5Fistore.c
Squashed a bug in the chunk caching code that caused the wrong
chunk to be returned.
./bin/trace
./src/H5.c
Added support for printing values of array arguments when the
size of the array is supplied by some previous argument. You
must declare the argument as an array in order for the
automatic tracing stuff to work. For instance, the third
argument of H5Pset_chunk() is an array whose size is
determined by the second argument `ndims'. Here's how you
should declare it:
herr_t
H5Pset_chunk(hid_t plist_id, intn rank, hsize_t dims[/*rank*/])
The comment inside the `[]' is the name of some previous
integer argument (int, unsigned, size_t, ssize_t, hsize_t,
hssize_t). The trace output will look something like:
H5Pset_chunk(plist=1234567, rank=2, dims=0x112233 {11, 22})
Changed tracing so that data types are printed out
symbolically when possible.
Changed tracing so data type initializations are not printed.
This used to be confusing because lots of H5Tcopy() and
H5Tregister...() calls showed up before the applications first
explicit API call.
./src/H5Ipublic.h
Changed the file atom group from zero to one so printing of
atoms during tracing is more consistent -- they're all big
numbers now.
./src/H5A.c
./src/H5E.c
./src/H5F.c
./src/H5G.c
./src/H5Sselect.c
./src/H5T.c
./src/H5TB.c
./src/H5Z.c
Accidently modified these when working on the tracing, but
nothing should have changed.
./src/H5P.c
Changed the definition of H5Pset_chunk() for tracing.
./src/H5S.c
./src/H5Spublic.h
Changed the definitions of H5Sset_extent_simple() and
H5Screate_simple() for tracing. Changed the FUNC_ENTER() name
for H5Screate_simple() so tracing shows the correct name.
1998-07-22 21:51:51 +08:00
|
|
|
if (defined $array) {
|
|
|
|
$atype .= "*";
|
|
|
|
if ($array =~ /^\[\/\*([a-z_A-Z]\w*)\*\/\]$/) {
|
|
|
|
my $asize = $1;
|
|
|
|
if (exists $names{$asize}) {
|
|
|
|
$atype .= '[a' . $names{$asize} . ']';
|
|
|
|
} else {
|
|
|
|
warn "bad array size: $asize";
|
|
|
|
$atype .= "*";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
1998-07-08 04:13:31 +08:00
|
|
|
push @arg_str, argstring $file, $name, $atype;
|
|
|
|
}
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
}
|
|
|
|
}
|
2006-12-12 09:49:59 +08:00
|
|
|
$trace = "H5TRACE" . scalar(@arg_str) . "(\"$rettype\", \"";
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
$trace .= join("", @arg_str) . "\"";
|
|
|
|
my $len = 4 + length $trace;
|
|
|
|
for (@arg_name) {
|
1998-08-28 00:48:50 +08:00
|
|
|
if ($len + length >= 77) {
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
$trace .= ",\n $_";
|
|
|
|
$len = 13 + length;
|
|
|
|
} else {
|
2006-12-12 09:49:59 +08:00
|
|
|
$trace .= ", $_";
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
$len += 1 + length;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
$trace .= ");\n";
|
|
|
|
}
|
|
|
|
goto error if grep {/!/} @arg_str;
|
|
|
|
|
|
|
|
# The H5TRACE() statement
|
|
|
|
if ($body =~ /\/\*[ \t]*NO[ \t]*TRACE[ \t]*\*\//) {
|
|
|
|
if ($body =~ /\s*H5TRACE\d+\s*\(/) {
|
|
|
|
errmesg $file, $name, "warning: trace info was not updated";
|
|
|
|
} else {
|
|
|
|
errmesg $file, $name, "warning: trace info was not inserted";
|
|
|
|
}
|
|
|
|
} elsif ($body =~ s/((\n[ \t]*)H5TRACE\d+\s*\(.*?\);)\n/"$2$trace"/es) {
|
|
|
|
# Replaced an H5TRACE macro
|
2003-10-14 23:46:38 +08:00
|
|
|
} elsif ($body=~s/((\n[ \t]*)FUNC_ENTER\w*\s*\(.*?\);??)\n/"$1$2$trace"/es) {
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
# Added an H5TRACE macro after a FUNC_ENTER macro.
|
|
|
|
} else {
|
|
|
|
errmesg $file, $name, "unable to insert tracing information";
|
1999-08-11 04:21:32 +08:00
|
|
|
print "body = ", $body, "\n";
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
goto error;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
error:
|
1998-08-28 00:48:50 +08:00
|
|
|
return "\n$type\n$name($args)\n$body";
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
##############################################################################
|
|
|
|
# Process each source file, rewriting API functions with updated
|
|
|
|
# tracing information.
|
|
|
|
#
|
|
|
|
my $total_api = 0;
|
|
|
|
for $file (@ARGV) {
|
2005-12-03 02:46:20 +08:00
|
|
|
# Ignore some files that do not need tracing macros
|
|
|
|
unless ($file eq "H5FDmulti.c" or $file eq "src/H5FDmulti.c" or $file eq "H5FDstdio.c" or $file eq "src/H5FDstdio.c") {
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
|
2005-12-03 02:46:20 +08:00
|
|
|
# Snarf up the entire file
|
|
|
|
open SOURCE, $file or die "$file: $!\n";
|
|
|
|
$Source = join "", <SOURCE>;
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
close SOURCE;
|
2005-12-03 02:46:20 +08:00
|
|
|
|
|
|
|
# Make modifications
|
|
|
|
my $original = $Source;
|
|
|
|
my $napi = $Source =~ s/\n([A-Za-z]\w*(\s+[a-z]\w*)*)\s*\n #type
|
|
|
|
(H5[A-Z]{0,2}[^_A-Z0-9]\w*) #name
|
|
|
|
\s*\((.*?)\)\s* #args
|
|
|
|
(\{.*?\n\}[^\n]*) #body
|
|
|
|
/rewrite_func($file,$1,$3,$4,$5)/segx;
|
|
|
|
$total_api += $napi;
|
|
|
|
|
|
|
|
# If the source changed then print out the new version
|
|
|
|
if ($original ne $Source) {
|
|
|
|
printf "%s: instrumented %d API function%s\n",
|
|
|
|
$file, $napi, 1==$napi?"":"s";
|
|
|
|
rename $file, "$file~" or die "unable to make backup";
|
|
|
|
open SOURCE, ">$file" or die "unable to modify source";
|
|
|
|
print SOURCE $Source;
|
|
|
|
close SOURCE;
|
|
|
|
}
|
[svn-r429] Changes since 19980616
----------------------
./html/tracing.html NEW
This entire update is to make it possible for the library to
print the name, arguments, and return value of every API call
without requiring any extra work from developers or app
programmers. This file describes how this all works.
./configure.in
Added the `--enable-tracing' switch. If you use it then the
library will include code to print API function names,
argument names and values, and function return values.
However, you must then turn on the tracing by setting the
HDF5_TRACE environment variable to a file descriptor number.
The default is `--disable-tracing' since enabling it causes a
slight increase in library size and a slowdown resulting from
an extra function call for each API function call (I couldn't
even measure the slowdown :-)
./bin/trace NEW
A perl script that synchronizes the H5TRACE() macro calls in
the *.c files with the function return type and formal
argument names and types. If you use GNU make and gcc then
this will be done automatically, otherwise just invoke this
script with the names of one or more .c files. You could do
it by hand to, but encoding argument types is a little tricky
at first.
./config/commence.in
Added the $(TRACE) macro, which defaults to the no-op.
Added -D_POSIX_SOURCE to the compiler command line.
./src/Makefile.in
Override the default for $(TRACE).
./config/depend.in
Automatically calls $(TRACE) to synchronize the H5TRACE()
macros in any source file that changed. As with makefile
dependencies, one way to force synchronization of all files is
to remove the `.depend' file.
./MANIFEST
Added new files.
./src/H5Eprivate.h
Modified HRETURN_ERROR() and HRETURN() for tracing.
./src/H5.c
./src/H5private.h
This is where the real tracing work really happens, in
H5_trace().
./src/H5A.c
./src/H5D.c
./src/H5G.c
./src/H5P.c
./src/H5S.c
./src/H5Z.c
Added H5TRACE() calls to all API functions. You don't really
need these changes if you don't want to merge your stuff
because they can be generated automatically by going to the
hdf5/src directory and saying ../bin/trace *.c
./src/H5T.c
Added H5TRACE() calls. Other stuff below.
./src/H5E.c
./src/H5Epublic.h
Added H5TRACE() calls. Created a type H5E_auto_t for the
`func' argument of H5Eset_auto() and H5Eget_auto() to make
those arguments easier to parse for tracing. It should also
make it clearer for users that don't know how to read
complicated ANSI data types.
./src/H5F.c
Added H5TRACE() calls. Changed a couple `uintn' argument
types in API functions to `unsigned int' since `uintn' part of
the API. Changed a few "can't" and "cant" error messages to
"unable to".
./src/H5Ipublic.h
Removed H5_DIRECTORY from the H5I_group_t enum. It wasn't
used anywhere.
./src/H5Tconv.c
Removed an unused label.
./src/H5Fistore.c
./src/H5Oattr.c
./src/H5Odtype.c
./src/H5T.c
./test/dsets.c
./test/dtypes.c
Fixed a warning about a variable possibly used before it's
initialized. Added __unused__ to turn off some unused
argument warnings that pop up when debugging is turned off and
optimizations are turned on.
1998-06-18 04:46:29 +08:00
|
|
|
}
|
|
|
|
}
|