Commit Graph

394 Commits

Author SHA1 Message Date
Albert Cheng
7fbe30d5ab [svn-r11735] Purpose:
Cleanup.

Description:
Removed the home-made version of snprintf and vsnprintf since they
do not actually enforce the size parameter correctly and could corrupt
memory or as a security hole.
This block of code has been turned off since Aug 11, 2005 for all platforms
except Tflops.  No one has reported any problem since--sort of empirical
evidence that all platforms except Tflops support both functions.
Tflops has retired in September.  So, no need to keep this block of code.

Also, fixed the HDxxx macro to call the corresponding xxx function.

Platforms tested:
Tested in heping, both serial and parallel.
2005-11-16 13:09:38 -05:00
Quincey Koziol
671187fd2b [svn-r11733] Purpose:
Code cleanup

Description:
    Added some comments about the thread-specific memory for the error and
function stacks.

    Changed H5close() to not use the function stack (since it causes it to
be re-enabled after shutting it down)

    Changed thread-safe semaphore code to not use dynamicly allocated memory.

Platforms tested:
    FreeBSD 4.11 (sleipnir)
    Linux 2.4
    Too minor to require h5committest
2005-11-15 20:01:37 -05:00
Quincey Koziol
a1708eb023 [svn-r11712] Purpose:
New feature

Description:
    Check in baseline for compact group revisions, which radically revises the
source code for managing groups and object headers.

WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!
WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!

    This initiates the "unstable" phase of the 1.7.x branch, leading up
to the 1.8.0 release.  Please test this code, but do _NOT_ keep files created
with it - the format will change again before the release and you will not
be able to read your old files!!!

WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!
WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!  WARNING!!!!


Solution:
    There's too many changes to really describe them all, but some of them
include:
    - Stop abusing the H5G_entry_t structure and split it into two separate
        structures for non-symbol table node use within the library: H5O_loc_t
        for object locations in a file and H5G_name_t to store the path to
        an opened object.  H5G_entry_t is now only used for storing symbol
        table entries on disk.

    - Retire H5G_namei() in favor of a more general mechanism for traversing
        group paths and issuing callbacks on objects located.  This gets us out
        of the business of hacking H5G_namei() for new features, generally.

    - Revised H5O* routines to take a H5O_loc_t instead of H5G_entry_t

    - Lots more...

Platforms tested:
    h5committested and maybe another dozen configurations.... :-)
2005-11-14 21:55:39 -05:00
Quincey Koziol
d2f2b5090c [svn-r11598] Purpose:
Code cleanup

Description:
    Take out odd definition of HDalarm() and replace with standard macro
like the rest of the library.

Platforms tested:
    FreeBSD 4.11 (sleipnir)
    Too minor to require h5committest
2005-10-22 13:37:56 -05:00
Fang Guo
25b5aa05f3 [svn-r11480] Purpose:
Maintenance on Windows
Description:
No alarm function on Windows, opt out
Solution:

Platforms tested:
MSVS 6.0 on Windows XP
Misc. update:
2005-09-29 12:34:18 -05:00
Albert Cheng
827ba4f4e8 [svn-r11289] Purpose:
cleanup

Description:
Changed the conditional definitions of HDvsnrintf and HDsnprint be
dependent on TFLOPS being defined so that these are consistent with
the condition in H5.c in which the two functions are coded.

Platforms tested:
heping.

Misc. update:
2005-08-22 15:58:58 -05:00
Fang Guo
16dd775f8f [svn-r11288] Purpose:
Maintenance on Windows
Description:
Move Win32 Macros(snprintf and vsnprintf) to the right places
Solution:

Platforms tested:
MSVS 6.0 on Windows XP
heping
Misc. update:
2005-08-22 14:03:00 -05:00
Fang Guo
778c6a053d [svn-r11251] Purpose:
Maintenance on windows
Description:
Add two macros for windows, susbstitue functions HDsnprintf and HDvsnprintf
with  _snprintf and _vsnprintf when using Visual C++ on windows

Solution:

Platforms tested:
MSVC 6.0 on Windows XP
heping
Misc. update:
2005-08-16 12:24:04 -05:00
Quincey Koziol
6b45f5172c [svn-r11245] Purpose:
Code cleanup

Description:
    Trim trailing whitespace, which is making 'diff'ing the two branches
difficult.

Solution:
    Ran this script in each directory:

foreach f (*.[ch] *.cpp)
    sed 's/[[:blank:]]*$//' $f > sed.out && mv sed.out $f
end


Platforms tested:
    FreeBSD 4.11 (sleipnir)
    Too minor to require h5committest
2005-08-13 15:53:35 -05:00
Quincey Koziol
34bd25f361 [svn-r11144] Purpose:
New port

Description:
    Elena asked me to check in her NEC SX-6 work, so here it is! :-)

Platforms tested:
    FreeBSD 4.11 (sleipnir)
    NEC SX-6 (by Elena)
2005-07-22 20:55:12 -05:00
James Laird
b0e5134171 [svn-r10730] Purpose:
Portability feature

Description:
The random() and srandom() functions are not available on all machines.
Set up the configure script to automatically detect them, rather than
requiring their presence or absence to be hardcoded.

Solution:
Added AC_CHECK_FUNCS macro to configure.in and replaced
#ifdef WIN32 conditionals with #ifdef H5_HAVE_RANDOM conditionals.

Platforms tested:
sleipnir, Windows
2005-05-05 12:38:59 -05:00
Quincey Koziol
f6fd474fe4 [svn-r10716] Purpose:
Code cleanup

Description:
    Migrate MPE macros to H5private.h, in preparation for using the
H5MPprivate.h file for "memory pool" API.

Platforms tested:
    FreeBSD 4.11 (sleipnir) w/parallel
    Too minor to require h5committest
2005-05-02 14:54:19 -05:00
James Laird
1b7ae2a5b7 [svn-r10701]
Purpose:
Bug fix

Description:
Some platforms (Windows) don't have the long long type, which causes automatic
Fortran type matching to fail.
A solution is to use HDF5's long_long type.

Solution:
Changed H5match_types.c to use long_long type.  Moved definition
of long_long out of H5private.h and into H5public.h.

Platforms tested:
mir, copper, pommier
2005-04-29 17:00:32 -05:00
Quincey Koziol
563a8dd140 [svn-r9861] Purpose:
Bug fix

Description:
    Add detect vasprintf() routine and use it instead of vsnprintf() when
formatting error descriptions if it's available.

    Added configure test to detect "broken" vsnprintf() implementations which
don't return the correct number of character for strings that are too long to
fit into the buffer provided (currently a problem on the SGIs and probably the
HP).

    Re-wrote error formatting code in H5Epush_stack() to handle broken
vsnprintf() implementations, etc.

Platforms tested:
    IRIX64 6.5 (modi4)
    h5committest
2005-01-23 22:26:37 -05:00
Quincey Koziol
d363f95d6d [svn-r9858] Purpose:
Code cleanup

Description:
    Clean up a few rements from the Pablo removal

Platforms tested:
    None, very minor
2005-01-22 08:38:49 -05:00
Elena Pourmal
c1df1b3ea4 [svn-r9857] Purpose: Maintenance
Description: Removed PABLO from the source

Solution:

Platforms tested: arabica with 64-bit, copper with parallel,
                  heping with GNU C and C++ and PGI fortran (but
                  I disabled hl, there is some weird problem only
                  on heping: F9XMODFLAG is not
                  propagated to the Makefile files

Misc. update:
2005-01-21 20:16:57 -05:00
Quincey Koziol
76ba1a99d3 [svn-r9805] Purpose:
Code cleanup

Description:
    Remove obsolete support for Watcom C compiler.

Platforms tested:
    None - too minor to require any.
2005-01-11 10:43:13 -05:00
Quincey Koziol
427ff7da28 [svn-r9727] Purpose:
Bug Fix/Code Cleanup/Doc Cleanup/Optimization/Branch Sync :-)

Description:
    Generally speaking, this is the "signed->unsigned" change to selections.
However, in the process of merging code back, things got stickier and stickier
until I ended up doing a big "sync the two branches up" operation.  So... I
brought back all the "infrastructure" fixes from the development branch to the
release branch (which I think were actually making some improvement in
performance) as well as fixed several bugs which had been fixed in one branch,
but not the other.

    I've also tagged the repository before making this checkin with the label
"before_signed_unsigned_changes".

Platforms tested:
    FreeBSD 4.10 (sleipnir) w/parallel & fphdf5
    FreeBSD 4.10 (sleipnir) w/threadsafe
    FreeBSD 4.10 (sleipnir) w/backward compatibility
    Solaris 2.7 (arabica) w/"purify options"
    Solaris 2.8 (sol) w/FORTRAN & C++
    AIX 5.x (copper) w/parallel & FORTRAN
    IRIX64 6.5 (modi4) w/FORTRAN
    Linux 2.4 (heping) w/FORTRAN & C++


Misc. update:
2004-12-29 09:26:20 -05:00
Raymond Lu
f558ddfb18 [svn-r9654] Purpose:
Description:  In file H5FDsec2.c and H5FDlog.c, there's statements like
     H5_ASSIGN_OVERFLOW(file->eof,sb.st_size,off_t,haddr_t);
It assumes sb.st_size from h5_stat_t is of type off_t.  But on Windows, it
has type __int64.  So the H5_ASSIGN_OVERFLOW statement may cause problem.
Instead of trying to do switch between Windows and other systems in H5FDsec2.c
and H5FDlog.c, define a substituting type in H5private.h to fix the problem.
On Windows, this type is __int64; on other systems, it is off_t.


Platforms tested:  fuss.  Simple fix.  Already did h5committest for v1.6.
2004-12-10 17:08:12 -05:00
MuQun Yang
babfbc2f9d [svn-r9474] Purpose:
Updating H5api_adpt.h to help the implementation of Fortran DLL on windows.


Description:
1. More functions need to be added prefix macro for exporting and importing
   fortran DLL on Windows.
2. unlink was _unlink on windows and use HDunlink to specify this.

Solution:

Platforms tested:
linux 2.4(h5committest not finished yet, but should work since the change is minor and it is passed with pgi compiler)

Misc. update:
2004-10-27 17:41:57 -05:00
Raymond Lu
cb7f03a26f [svn-r9183] Purpose: New feature
Description:  Restore 6 old error API functions back to the library to be backward
compatible with v1.6.  They are H5Epush, H5Eprint, H5Ewalk, H5Eclear, H5Eset_auto,
H5Eget_auto.  These functions do not have error stack  as parameter.

Solution:  Internally, these functions use default error stack.

Platforms tested:  h5committest and fuss.

Misc. update: RELEASE.txt
2004-09-01 12:43:30 -05:00
Elena Pourmal
0a965d2236 [svn-r9154]
Purpose: Maintenance/bug fixes (OSF1 C++ and missing Fortran APIs)

Description: bringing 1.6 changes to 1.7

Solution:

Platforms tested: OSF1, Solaris 2.8, AIX5.1

Misc. update:
2004-08-24 22:44:59 -05:00
Quincey Koziol
e3c46f3eef [svn-r9037] Purpose:
Code cleanup/bug fix

Description:
    Check for _O_BINARY being defined instead of O_BINARY, since we actually use
_O_BINARY.  (Note that this only affects Windows)

Platforms tested:
    FreeBSD 4.10 (sleipnir)
    Not tested w/h5committest
2004-08-06 14:05:20 -05:00
Quincey Koziol
7c3df64cc4 [svn-r8731] Purpose:
Code cleanup & minor optimization

Description:
    Re-work the way interface initialization routines are specified in the
library to avoid the overhead of checking for them in routines where there is
no interface initialization routine.  This cleans up warnings with gcc 3.4,
reduces the library binary size a bit (about 2-3%) and should speedup the
library's execution slightly.

Platforms tested:
    FreeBSD 4.10 (sleipnir) w/gcc34
    h5committest
2004-06-23 10:36:35 -05:00
Albert Cheng
e4d5623692 [svn-r8370] Purpose:
Bug fix.

Description:
Not all machines (like Sun and AIX) support fabsl() and fabsf() used
in test/dtypes.c.  Changed the coding to use macro names HDfabsl and
HDfabsf.  Also set the two macros to use ABS for now so that they will
work for all machines. (need more portable fixes which would involve
configure.)

Platforms tested:
h5committested. (also tested in LANL QSC and Theta).
2004-04-17 12:17:32 -05:00
Quincey Koziol
c3d9b510b4 [svn-r8287] Purpose:
Bug fix/code cleanup

Description:
    Copy Robb's feature in SSlib that checks that the name of the function
used in the FUNC_ENTER macro is actually the name of function.

    Fixed a bunch of typos & copy-n-pasto's for functions with incorrect names.

Platforms tested:
    FreeBSD 4.9 (sleipnir) w/parallel
    too minor to require h5committest
2004-03-30 15:41:45 -05:00
Quincey Koziol
feaa5bb9d5 [svn-r8038] Purpose:
Bug fix

Description:
    When two property lists are compared, the H5Pequal routine was just
comparing the raw information for the property values.  This causes problems
when the raw information contains pointers to other information.

Solution:
    Allow a 'compare' callback to be registered for properties, so that a user
application get perform the comparison itself, allowing for "deep" compares of
the property value.
    This was exported to the H5Pregister & H5Pinsert routines in the development
branch, but not the release branch.

Platforms tested:
    FreeBSD 4.9 (sleipnir)
    h5committest
2004-01-08 09:55:11 -05:00
Quincey Koziol
4da7b1ee9b [svn-r8009] Purpose:
Bug fix

Description:
    Add special-case handling to floating-point conversion tests to avoid
problems with denormalized values on Cray T3E & T90 platforms.  (Still not
working on Cray SV1, but at least it's closer).

Solution:
    Detect denormalized values and don't try to operate on them on the Crays.

Platforms tested:
    FreeBSD 4.9 (sleipnir)
    Cray T3E (hubble.cray.com)
    Cray T90 (gypsy.cray.com)
2003-12-31 15:36:37 -05:00
Quincey Koziol
31431be374 [svn-r7917] Purpose:
Code cleanup

Description:
    Clean up compiler warnings, especially the 'FUNC' variable not used which
comes out in production mode.

Solution:
    Had to add a new FUNC_ENTER_NOAPI_NOINIT_NOFUNC macro for those non-API
functions which don't need the 'FUNC' variable defined.  (This will be _so_
much easier when C99 is standard on all our supposed platforms, since it has a
__FUNC__ macro... )

Platforms tested:
    FreeBSD 4.9 (sleipnir)
    too minor for h5committest (although there were lots of files changed, the
        change was minor in each one)
2003-12-06 15:38:31 -05:00
Quincey Koziol
59e9042d5a [svn-r7872] Purpose:
New macro

Description:
    Introduce LLONG_MIN macro to match LLONG_MAX macro

Platforms tested:
    FreeBSD 4.9 (sleipnir)
    too minor to require h5committest
2003-11-21 16:57:09 -05:00
Quincey Koziol
dd969f1ead [svn-r7827] Purpose:
Bug fix

Description:
    Make --disable-hsizet work properly again by fixing a couple of tests and
correcting the definition of SSIZET_MAX.

Platforms tested:
    FreeBSD 4.9 (sleipnir)
    h5committest not used, as it doesn't test this configuration.
2003-11-08 09:21:49 -05:00
Quincey Koziol
71ec0f5777 [svn-r7669] Purpose:
Refactor code

Description:
    Use "template macro" technique to eliminate a huge amount of repeated code
in type initialization code (almost 1000 lines, between this change and the
changes to the H5Tconv.c file earlier).
    This centralizes the common parts of the code and makes the different parts
of the code more obvious.

Platforms tested:
    FreeBSD 4.9 (sleipnir)
    too minor to require h5committest
2003-10-20 11:43:40 -05:00
Quincey Koziol
ece7defd50 [svn-r7662] Purpose:
Refactor integer conversion macros

Description:
    Turned integer conversion macros "inside" out, using an interlocking
macro technique similar to templates in C++.  The macro which actually performs
the conversion is now invoked "genericly" from inside another macro, which
will allow the inner conversion loop to be optimized in a much easier way.

    This "psuedo-template" technique could be useful for other semi-repetitious
patterns in the library - possibly the datatype initialization code...

Platforms tested:
    FreeBSD 4.9 (sleipnir)
    h5committest
2003-10-17 22:20:26 -05:00
Quincey Koziol
7e9c4449d4 [svn-r7411] Purpose:
Code cleanup

Description:
    De-linted more modules

Platforms tested:
    FreeBSD 4.8 (sleipnir) w/ & w/o stream enabled
    too minor to require h5committest
2003-08-26 10:03:03 -05:00
Quincey Koziol
1186c0b7fa [svn-r7297] Purpose:
Code cleanup

Description:
    Changed lines like:
        H5E_clear(H5E_get_my_stack());

    to:
        H5E_clear(NULL);

    which performs the same operation.

Platforms tested:
    h5committested
2003-08-08 13:47:43 -05:00
Raymond Lu
0d22a663df [svn-r7265] *** empty log message *** 2003-07-25 21:55:47 -05:00
Raymond Lu
4b0fa0dbf0 [svn-r7256] Purpose: gradual checkin for error api
Platforms tested: RH 8(simple checkin)
2003-07-22 22:13:27 -05:00
Quincey Koziol
e9cc951e03 [svn-r7232] Purpose:
Bug fix

Description:
    When a non-default indexed storage B-tree internal 'K' value is set by the
user, the chunked datasets created in that file (until it is closed) use the
user's 'K' value and the data can be accessed correctly, but the 'K' value is
not stored in the file.
    However, once the file is closed and re-opened, the non-default 'K' value
is lost and the data in the chunked datasets will not be able to be accessed
correctly.

Solution:
    Store the indexed storage B-tree internal 'K' value in the superblock.

Platforms tested:
    FreeBSD 4.8 (sleipnir)
    h5committest
2003-07-16 09:56:58 -05:00
Quincey Koziol
cf53e4aa24 [svn-r7203] Purpose:
Code cleanup

Description:
    Change names of macro parameters to H5_ASSIGN_OVERFLOW to make them
easier to understand.

Platforms tested:
    FreeBSD 4.8 (sleipnir)
    h5committest
2003-07-10 14:44:01 -05:00
Quincey Koziol
4fe4a51818 [svn-r7186] Purpose:
Code cleanup

Description:
    More tweaks to clean up warnings from lint.

Platforms tested:
    FreeBSD 4.8 (sleipnir)
    not major enough to h5committest
2003-07-09 09:34:35 -05:00
Quincey Koziol
f2048a2379 [svn-r7184] Purpose:
Code cleanup

Description:
    Clean up various warnings from lint

Platforms tested:
    FreeBSD 4.8 (sleipnir)
    no major changes requiring h5committest
2003-07-08 16:05:27 -05:00
Quincey Koziol
c0f9f41be8 [svn-r7027] Purpose:
Bug fix

Description:
    MPE instrumentation was out of date and wasn't reporting the correct name
of the API functions in the library.

Platforms tested:
    IBM p690 (copper)
    h5committest not performed because it doesn't test MPE.
2003-06-11 21:59:49 -05:00
Quincey Koziol
2e07d8035f [svn-r6970] Purpose:
Twist code

Description:
    Try to find a happy definition of HSSIZET_MAX, HSSIZET_MIN and HSIZET_MAX
for all platforms.

Platforms tested:
    FreeBSD 4.8 (sleipnir)
    h5committested
2003-06-05 09:53:21 -05:00
Quincey Koziol
c508e1ddc4 [svn-r6963] Purpose:
Code cleanup

Description:
    Fix HSIZET_MAX, HSSIZET_MAX and HSSIZET_MIN to work with Windows (hopefully)

Platforms tested:
    h5committested
2003-06-04 15:26:35 -05:00
Quincey Koziol
a3f07ee927 [svn-r6955] Purpose:
Code cleanup

Description:
    Tweak HSIZET_MAX macro and add HSSIZE_MAX and HSSIZET_MIN macros.

Platforms tested:
    FreeBSD 4.8 (sleipnir) w/C++
    FreeBSD 4.8 (sleipnir) w/parallel
    h5committested
2003-06-04 10:33:24 -05:00
Quincey Koziol
8fc3673745 [svn-r6430] Purpose:
Code cleanup (sorta)

Description:
    Updated to new copyright information as I browsed these files.
2003-02-24 15:13:07 -05:00
Quincey Koziol
168d67dbd2 [svn-r6383] Purpose:
New feature for developers.

Description:
    Added "function stack" tracing to library.  This allows developers (there
    is no public API) to call H5FS_print within the library and get a listing
    of the functions traversed to reach that point in the library.  Eventually,
    I may add support for reporting the parameters to each function also...

    Mainly for debugging parallel I/O programs, but I think it will come in
    handy in other cases also.

    The function stack tracking is controlled with a configure switch:
    --enable-funcstack, which defaults to enabled currently.  When we branch
    for 1.6, we should change the default setting on the branch to be disabled.

    Also, added a destructor to the thread-specific keys when thread-safety is
    turned on in the library.  Otherwise, they were leaking memory and causing
    difficult to debug errors in threaded programs (like the test/ttsafe test).

Platforms tested:
    Tested h5committest {arabica (fortran), eirene (fortran, C++)
	modi4 (parallel, fortran)}

    FreeBSD 4.7 (sleipnir) w/thread-safety enabled.

Misc. update:
    Updated MANIFEST with new files added (src/H5FS.c & src/H5FDprivate.h)

    Update release_docs/RELEASE with thread-safety bug fix.
2003-02-07 16:14:19 -05:00
MuQun Yang
3715140146 [svn-r6283]
Purpose:
Change some macros to make windows happy
Description:
Currently no srandom and random functions on windows,
Function gethostname cannot be resolved when DLL turned on
Solution:
use srand and rand to replace srandom and random
turn off the option to check gethostname
Platforms tested:
windows 2000, linux 2.2.18smp
Misc. update:
    Update MANIFEST if you add or remove any file.
    Update release_docs/RELEASE for bug fixes, new features, etc.
    Update applicable document files too.
2003-01-14 16:23:09 -05:00
Quincey Koziol
3d4529bf2a [svn-r6272] Purpose:
Code cleanup

Description:
    Fix preprocessor macros to declare variables correctly.

Platforms tested:
    MS Visual Studio
2003-01-13 10:03:05 -05:00
Quincey Koziol
8e391ad35a [svn-r6269] Purpose:
Code cleanup

Description:
    Various code cleanups to allow the development branch to be compiled with
    a C++ compiler (i.e. CC=g++ )

Platforms tested:
    Tested h5committest {arabica (fortran), eirene (fortran, C++)
	modi4 (parallel, fortran)}
    FreeBSD 4.7 (sleipnir) C++
2003-01-13 08:15:49 -05:00