summaryrefslogtreecommitdiff
path: root/numsort.c
diff options
context:
space:
mode:
Diffstat (limited to 'numsort.c')
-rw-r--r--numsort.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/numsort.c b/numsort.c
index 1186d54..70bdd2a 100644
--- a/numsort.c
+++ b/numsort.c
@@ -32,19 +32,16 @@ DoNumSort (void)
{
const char* context = "CPU:Numeric Sort";
SortStruct* numsortstruct = &global_numsortstruct;
+ long* arraybase = NULL;
clock_t total_time = 0;
int iterations = 0;
- long* arraybase = NULL;
-
int num_arrays = 1;
+ static int is_adjusted = FALSE;
- /*
- ** See if we need to do self adjustment code.
- */
- if (numsortstruct->adjust == FALSE) {
- numsortstruct->adjust = TRUE;
+ if (is_adjusted == FALSE) {
+ is_adjusted = TRUE;
/*
- ** Self-adjustment code. The system begins by sorting 1
+ ** Self-is_adjustedment code. The system begins by sorting 1
** array. If it does that in no time, then two arrays
** are built and sorted. This process continues until
** enough arrays are built to handle the tolerance.