summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDana Robinson <43805+derobins@users.noreply.github.com>2022-03-10 22:14:05 (GMT)
committerGitHub <noreply@github.com>2022-03-10 22:14:05 (GMT)
commit01209d277767cc66d11d4c1ef874ed493000f78c (patch)
treeb6a667ac36b8e4c64233d2b16a8d08913ecaac71
parent1fb3743f04df101c7245ce045b67d371d462fd70 (diff)
downloadhdf5-01209d277767cc66d11d4c1ef874ed493000f78c.zip
hdf5-01209d277767cc66d11d4c1ef874ed493000f78c.tar.gz
hdf5-01209d277767cc66d11d4c1ef874ed493000f78c.tar.bz2
Removes remaining register keywords (#1481)
-rw-r--r--hl/tools/gif2h5/gif2mem.c32
-rw-r--r--hl/tools/gif2h5/hdfgifwr.c14
-rw-r--r--tools/lib/h5tools.c2
-rw-r--r--tools/lib/h5tools_str.c8
-rw-r--r--tools/src/h5perf/pio_engine.c2
-rw-r--r--tools/src/h5perf/pio_perf.c65
-rw-r--r--tools/src/h5perf/sio_engine.c2
-rw-r--r--tools/src/h5perf/sio_perf.c43
-rw-r--r--tools/test/h5dump/h5dumpgentest.c6
-rw-r--r--tools/test/perform/pio_standalone.c2
-rw-r--r--tools/test/perform/sio_standalone.c2
-rw-r--r--tools/test/perform/zip_perf.c6
12 files changed, 91 insertions, 93 deletions
diff --git a/hl/tools/gif2h5/gif2mem.c b/hl/tools/gif2h5/gif2mem.c
index 2c2225e..44e18e0 100644
--- a/hl/tools/gif2h5/gif2mem.c
+++ b/hl/tools/gif2h5/gif2mem.c
@@ -49,22 +49,22 @@ Gif2Mem(GIFBYTE *MemGif, GIFTOMEM *GifMemoryStruct)
GIFCOMMENT ** gifComment; /* Comment Extension structure */
GIFGRAPHICCONTROL **gifGraphicControl; /* Graphic Control Extension strct */
- register GIFWORD i; /* Loop counter */
- GIFBYTE Identifier; /* Extension block identifier holder */
- GIFBYTE Label; /* Extension block label holder */
- GIFBYTE ImageCount; /* Count of the number of images in the file */
- GIFBYTE ImageArray; /* Keep the size of the array to store Images */
- GIFBYTE CommentCount;
- GIFBYTE CommentArray;
- GIFBYTE ApplicationCount;
- GIFBYTE ApplicationArray;
- GIFBYTE PlainTextCount;
- GIFBYTE PlainTextArray;
- GIFBYTE GCEflag;
- GIFBYTE aTemp;
- GIFBYTE j;
- GIFBYTE w; /* Two more variables needed only while testing */
- GIFBYTE * b; /* Endian Ordering */
+ GIFWORD i; /* Loop counter */
+ GIFBYTE Identifier; /* Extension block identifier holder */
+ GIFBYTE Label; /* Extension block label holder */
+ GIFBYTE ImageCount; /* Count of the number of images in the file */
+ GIFBYTE ImageArray; /* Keep the size of the array to store Images */
+ GIFBYTE CommentCount;
+ GIFBYTE CommentArray;
+ GIFBYTE ApplicationCount;
+ GIFBYTE ApplicationArray;
+ GIFBYTE PlainTextCount;
+ GIFBYTE PlainTextArray;
+ GIFBYTE GCEflag;
+ GIFBYTE aTemp;
+ GIFBYTE j;
+ GIFBYTE w; /* Two more variables needed only while testing */
+ GIFBYTE *b; /* Endian Ordering */
/* Allocate memory for the GIF structures */
/* Plug the structs into GifMemoryStruct at the end */
diff --git a/hl/tools/gif2h5/hdfgifwr.c b/hl/tools/gif2h5/hdfgifwr.c
index 21b14d1..7126da9 100644
--- a/hl/tools/gif2h5/hdfgifwr.c
+++ b/hl/tools/gif2h5/hdfgifwr.c
@@ -188,13 +188,13 @@ hdfWriteGIF(FILE *fp, byte *pic, int ptype, int w, int h, const byte *rmap, cons
static void
compress(int init_bits, FILE *outfile, byte *data, int len)
{
- register long fcode;
- register int i = 0;
- register int c;
- register int ent;
- register int disp;
- register int hsize_reg;
- register int hshift;
+ long fcode;
+ int i = 0;
+ int c;
+ int ent;
+ int disp;
+ int hsize_reg;
+ int hshift;
/*
* Set up the globals: g_init_bits - initial number of bits g_outfile -
diff --git a/tools/lib/h5tools.c b/tools/lib/h5tools.c
index da55136..c7dba25 100644
--- a/tools/lib/h5tools.c
+++ b/tools/lib/h5tools.c
@@ -1052,7 +1052,7 @@ done:
H5_ATTR_PURE static size_t
h5tools_count_ncols(const char *s)
{
- register size_t i;
+ size_t i;
for (i = 0; *s; s++)
if (*s >= ' ')
diff --git a/tools/lib/h5tools_str.c b/tools/lib/h5tools_str.c
index 1fb2c68..7ad6a65 100644
--- a/tools/lib/h5tools_str.c
+++ b/tools/lib/h5tools_str.c
@@ -1401,10 +1401,10 @@ h5tools_str_sprint_reference(h5tools_str_t *str, H5R_ref_t *ref_vp)
static char *
h5tools_escape(char *s /*in,out*/, size_t size)
{
- register size_t i;
- const char * escape;
- char octal[8];
- size_t n = HDstrlen(s);
+ size_t i;
+ const char *escape;
+ char octal[8];
+ size_t n = HDstrlen(s);
for (i = 0; i < n; i++) {
switch (s[i]) {
diff --git a/tools/src/h5perf/pio_engine.c b/tools/src/h5perf/pio_engine.c
index e316245..1baaca2 100644
--- a/tools/src/h5perf/pio_engine.c
+++ b/tools/src/h5perf/pio_engine.c
@@ -420,7 +420,7 @@ pio_create_filename(iotype iot, const char *base_name, char *fullname, size_t si
/* If the prefix specifies the HDF5_PARAPREFIX directory, then
* default to using the "/tmp/$USER" or "/tmp/$LOGIN"
* directory instead. */
- register char *user, *login, *subdir;
+ char *user, *login, *subdir;
user = HDgetenv("USER");
login = HDgetenv("LOGIN");
diff --git a/tools/src/h5perf/pio_perf.c b/tools/src/h5perf/pio_perf.c
index c233684..003c4f2 100644
--- a/tools/src/h5perf/pio_perf.c
+++ b/tools/src/h5perf/pio_perf.c
@@ -200,7 +200,7 @@ static void output_results(const struct options *options, const char *name, min
off_t data_size);
static void output_times(const struct options *options, const char *name, minmax *table, int table_size);
static void output_report(const char *fmt, ...);
-static void print_indent(register int indent);
+static void print_indent(int indent);
static void usage(const char *prog);
static void report_parameters(struct options *opts);
static off_t squareo(off_t);
@@ -336,7 +336,7 @@ run_test_loop(struct options *opts)
/* start with max_num_procs and decrement it by half for each loop. */
/* if performance needs restart, fewer processes may be needed. */
for (num_procs = opts->max_num_procs; num_procs >= opts->min_num_procs; num_procs >>= 1) {
- register size_t buf_size;
+ size_t buf_size;
parms.num_procs = num_procs;
@@ -411,34 +411,34 @@ run_test_loop(struct options *opts)
static int
run_test(iotype iot, parameters parms, struct options *opts)
{
- results res;
- register int i, ret_value = SUCCESS;
- int comm_size;
- off_t raw_size;
- minmax * write_mpi_mm_table = NULL;
- minmax * write_mm_table = NULL;
- minmax * write_gross_mm_table = NULL;
- minmax * write_raw_mm_table = NULL;
- minmax * read_mpi_mm_table = NULL;
- minmax * read_mm_table = NULL;
- minmax * read_gross_mm_table = NULL;
- minmax * read_raw_mm_table = NULL;
- minmax * read_open_mm_table = NULL;
- minmax * read_close_mm_table = NULL;
- minmax * write_open_mm_table = NULL;
- minmax * write_close_mm_table = NULL;
- minmax write_mpi_mm = {0.0, 0.0, 0.0, 0};
- minmax write_mm = {0.0, 0.0, 0.0, 0};
- minmax write_gross_mm = {0.0, 0.0, 0.0, 0};
- minmax write_raw_mm = {0.0, 0.0, 0.0, 0};
- minmax read_mpi_mm = {0.0, 0.0, 0.0, 0};
- minmax read_mm = {0.0, 0.0, 0.0, 0};
- minmax read_gross_mm = {0.0, 0.0, 0.0, 0};
- minmax read_raw_mm = {0.0, 0.0, 0.0, 0};
- minmax read_open_mm = {0.0, 0.0, 0.0, 0};
- minmax read_close_mm = {0.0, 0.0, 0.0, 0};
- minmax write_open_mm = {0.0, 0.0, 0.0, 0};
- minmax write_close_mm = {0.0, 0.0, 0.0, 0};
+ results res;
+ int i, ret_value = SUCCESS;
+ int comm_size;
+ off_t raw_size;
+ minmax *write_mpi_mm_table = NULL;
+ minmax *write_mm_table = NULL;
+ minmax *write_gross_mm_table = NULL;
+ minmax *write_raw_mm_table = NULL;
+ minmax *read_mpi_mm_table = NULL;
+ minmax *read_mm_table = NULL;
+ minmax *read_gross_mm_table = NULL;
+ minmax *read_raw_mm_table = NULL;
+ minmax *read_open_mm_table = NULL;
+ minmax *read_close_mm_table = NULL;
+ minmax *write_open_mm_table = NULL;
+ minmax *write_close_mm_table = NULL;
+ minmax write_mpi_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_gross_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_raw_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_mpi_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_gross_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_raw_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_open_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_close_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_open_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_close_mm = {0.0, 0.0, 0.0, 0};
raw_size = parms.num_files * (off_t)parms.num_dsets * (off_t)parms.num_bytes;
parms.io_type = iot;
@@ -1098,10 +1098,9 @@ output_report(const char *fmt, ...)
* things.
* Return: Nothing
* Programmer: Bill Wendling, 29. October 2001
- * Modifications:
*/
static void
-print_indent(register int indent)
+print_indent(int indent)
{
int myrank;
@@ -1278,7 +1277,7 @@ report_parameters(struct options *opts)
static struct options *
parse_command_line(int argc, const char *const *argv)
{
- register int opt;
+ int opt;
struct options *cl_opts;
cl_opts = (struct options *)malloc(sizeof(struct options));
diff --git a/tools/src/h5perf/sio_engine.c b/tools/src/h5perf/sio_engine.c
index 95ec3ce..bdd2c08 100644
--- a/tools/src/h5perf/sio_engine.c
+++ b/tools/src/h5perf/sio_engine.c
@@ -328,7 +328,7 @@ sio_create_filename(iotype iot, const char *base_name, char *fullname, size_t si
/* If the prefix specifies the HDF5_PREFIX directory, then
* default to using the "/tmp/$USER" or "/tmp/$LOGIN"
* directory instead. */
- register char *user, *login, *subdir;
+ char *user, *login, *subdir;
user = HDgetenv("USER");
login = HDgetenv("LOGIN");
diff --git a/tools/src/h5perf/sio_perf.c b/tools/src/h5perf/sio_perf.c
index 87b9d65..dc2e15e 100644
--- a/tools/src/h5perf/sio_perf.c
+++ b/tools/src/h5perf/sio_perf.c
@@ -173,7 +173,7 @@ static void accumulate_minmax_stuff(const minmax *mm, int count, minm
static void output_results(const struct options *options, const char *name, minmax *table, int table_size,
off_t data_size);
static void output_report(const char *fmt, ...);
-static void print_indent(register int indent);
+static void print_indent(int indent);
static void usage(const char *prog);
static void report_parameters(struct options *opts);
@@ -299,25 +299,25 @@ run_test_loop(struct options *opts)
static int
run_test(iotype iot, parameters parms, struct options *opts)
{
- results res;
- register int i, ret_value = SUCCESS;
- off_t raw_size;
- minmax * write_sys_mm_table = NULL;
- minmax * write_mm_table = NULL;
- minmax * write_gross_mm_table = NULL;
- minmax * write_raw_mm_table = NULL;
- minmax * read_sys_mm_table = NULL;
- minmax * read_mm_table = NULL;
- minmax * read_gross_mm_table = NULL;
- minmax * read_raw_mm_table = NULL;
- minmax write_sys_mm = {0.0, 0.0, 0.0, 0};
- minmax write_mm = {0.0, 0.0, 0.0, 0};
- minmax write_gross_mm = {0.0, 0.0, 0.0, 0};
- minmax write_raw_mm = {0.0, 0.0, 0.0, 0};
- minmax read_sys_mm = {0.0, 0.0, 0.0, 0};
- minmax read_mm = {0.0, 0.0, 0.0, 0};
- minmax read_gross_mm = {0.0, 0.0, 0.0, 0};
- minmax read_raw_mm = {0.0, 0.0, 0.0, 0};
+ results res;
+ int i, ret_value = SUCCESS;
+ off_t raw_size;
+ minmax *write_sys_mm_table = NULL;
+ minmax *write_mm_table = NULL;
+ minmax *write_gross_mm_table = NULL;
+ minmax *write_raw_mm_table = NULL;
+ minmax *read_sys_mm_table = NULL;
+ minmax *read_mm_table = NULL;
+ minmax *read_gross_mm_table = NULL;
+ minmax *read_raw_mm_table = NULL;
+ minmax write_sys_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_gross_mm = {0.0, 0.0, 0.0, 0};
+ minmax write_raw_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_sys_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_gross_mm = {0.0, 0.0, 0.0, 0};
+ minmax read_raw_mm = {0.0, 0.0, 0.0, 0};
raw_size = (off_t)parms.num_bytes;
parms.io_type = iot;
@@ -657,10 +657,9 @@ output_report(const char *fmt, ...)
* things.
* Return: Nothing
* Programmer: Bill Wendling, 29. October 2001
- * Modifications:
*/
static void
-print_indent(register int indent)
+print_indent(int indent)
{
indent *= TAB_SPACE;
diff --git a/tools/test/h5dump/h5dumpgentest.c b/tools/test/h5dump/h5dumpgentest.c
index 5258211..339b563 100644
--- a/tools/test/h5dump/h5dumpgentest.c
+++ b/tools/test/h5dump/h5dumpgentest.c
@@ -3914,9 +3914,9 @@ gent_multi(void)
static void
gent_large_objname(void)
{
- hid_t fid, group, group2;
- char grp_name[128];
- register int i;
+ hid_t fid, group, group2;
+ char grp_name[128];
+ int i;
fid = H5Fcreate(FILE37, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT);
diff --git a/tools/test/perform/pio_standalone.c b/tools/test/perform/pio_standalone.c
index 032bfba..a074d2c 100644
--- a/tools/test/perform/pio_standalone.c
+++ b/tools/test/perform/pio_standalone.c
@@ -92,7 +92,7 @@ get_option(int argc, const char **argv, const char *opts, const struct h5_long_o
sp = 1;
}
else {
- register char *cp; /* pointer into current token */
+ char *cp; /* pointer into current token */
/* short command line option */
opt_opt = argv[H5_optind][sp];
diff --git a/tools/test/perform/sio_standalone.c b/tools/test/perform/sio_standalone.c
index 7c22b53..353dad3 100644
--- a/tools/test/perform/sio_standalone.c
+++ b/tools/test/perform/sio_standalone.c
@@ -92,7 +92,7 @@ get_option(int argc, const char **argv, const char *opts, const struct h5_long_o
sp = 1;
}
else {
- register char *cp; /* pointer into current token */
+ char *cp; /* pointer into current token */
/* short command line option */
opt_opt = argv[H5_optind][sp];
diff --git a/tools/test/perform/zip_perf.c b/tools/test/perform/zip_perf.c
index 74b1685..87a7122 100644
--- a/tools/test/perform/zip_perf.c
+++ b/tools/test/perform/zip_perf.c
@@ -336,8 +336,8 @@ parse_size_directive(const char *size)
static void
fill_with_random_data(Bytef *src, uLongf src_len)
{
- register unsigned u;
- h5_stat_t stat_buf;
+ unsigned u;
+ h5_stat_t stat_buf;
if (HDstat("/dev/urandom", &stat_buf) == 0) {
uLongf len = src_len;
@@ -386,7 +386,7 @@ do_write_test(unsigned long file_size, unsigned long min_buf_size, unsigned long
Bytef * src;
for (src_len = min_buf_size; src_len <= max_buf_size; src_len <<= 1) {
- register unsigned long i, iters;
+ unsigned long i, iters;
iters = file_size / src_len;
src = (Bytef *)HDcalloc(1, sizeof(Bytef) * src_len);