From 9e859565e49b62e4610b9340436835d6d190db34 Mon Sep 17 00:00:00 2001 From: Quincey Koziol Date: Sat, 17 Apr 2004 11:06:34 -0500 Subject: [svn-r8368] Purpose: Code optimization Description: Compute value for array instead of using memset(), since we are looping through the array indices anyway. Platforms tested: Solaris 2.7 (arabica) FreeBSD 4.9 (sleipnir) too minor to require h5committest --- src/H5Sall.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/H5Sall.c b/src/H5Sall.c index fac8d96..4509986 100644 --- a/src/H5Sall.c +++ b/src/H5Sall.c @@ -152,14 +152,15 @@ H5S_all_iter_block (const H5S_sel_iter_t *iter, hssize_t *start, hssize_t *end) assert (start); assert (end); - /* Get the start of the 'all' block */ - /* (Always '0' coordinates for now) */ - HDmemset(start,0,sizeof(hssize_t)*iter->rank); + for(u=0; urank; u++) { + /* Set the start of the 'all' block */ + /* (Always '0' coordinates for now) */ + start[u]=0; - /* Compute the end of the 'all' block */ - /* (Always size of the extent for now) */ - for(u=0; urank; u++) + /* Compute the end of the 'all' block */ + /* (Always size of the extent for now) */ end[u]=iter->dims[u]-1; + } /* end for */ FUNC_LEAVE_NOAPI(SUCCEED); } /* H5S_all_iter_coords() */ -- cgit v0.12