diff --git a/mps/code/config.h b/mps/code/config.h index 07531878614..2f753eb1e11 100644 --- a/mps/code/config.h +++ b/mps/code/config.h @@ -32,13 +32,13 @@ #if defined(CONFIG_VAR_WI) || defined(CONFIG_VAR_WE) /* White-hot varieties */ /* no asserts */ /* ... so CHECKLEVEL_INITIAL is irrelevant */ -/* no debug diagnostic statistic meters */ +/* no debug statistic meters */ /* no telemetry log events */ #elif defined(CONFIG_VAR_HI) || defined(CONFIG_VAR_HE) /* Hot varieties */ #define CONFIG_ASSERT #define CHECKLEVEL_INITIAL CheckLevelMINIMAL -/* no debug diagnostic statistic meters */ +/* no debug statistic meters */ /* no telemetry log events */ #elif defined(CONFIG_VAR_DI) /* Diagnostic variety */ @@ -69,7 +69,7 @@ #elif defined(CONFIG_VAR_II) /* Ice, Internal; variety.ii (HotLog) */ #define CONFIG_ASSERT #define CHECKLEVEL_INITIAL CheckLevelMINIMAL -/* no debug diagnostic statistic meters */ +/* no debug statistic meters */ #define CONFIG_LOG #endif @@ -89,12 +89,17 @@ #if defined(CONFIG_DEBUG) -/* DEBUG = DIAGNOSTICS = STATISTICs = METERs */ -/* WARNING: this changes the size and fields of MPS structs */ -#define DIAGNOSTICS +/* CONFIG_DEBUG = STATISTICS = METERs */ +/* Note: the STATISTICS define used to be called "DIAGNOSTICS" (even */ +/* though it controls the STATISTIC system), but the term */ +/* "diagnostic" means something else now: see design/diag/. */ +/* RHSK 2007-06-28 */ +/* WARNING: this may change the size and fields of MPS structs */ +/* (...but see STATISTIC_DECL, which is invariant) */ +#define STATISTICS #define MPS_DEBUG_STRING "debug" #else -#define DIAGNOSTICS_NONE +#define STATISTICS_NONE #define MPS_DEBUG_STRING "nondebug" #endif diff --git a/mps/code/meter.h b/mps/code/meter.h index 3e8902a6497..6912ca7afc0 100644 --- a/mps/code/meter.h +++ b/mps/code/meter.h @@ -44,12 +44,12 @@ extern void MeterEmit(Meter meter); /* Hack: owner is typically only used for MeterInit */ #define METER_ACC(meter, delta) \ STATISTIC(MeterAccumulate(&(meter), delta)) -#if defined(DIAGNOSTICS) +#if defined(STATISTICS) #define METER_WRITE(meter, stream) MeterWrite(&(meter), stream) -#elif defined(DIAGNOSTICS_NONE) +#elif defined(STATISTICS_NONE) #define METER_WRITE(meter, stream) (ResOK) #else -#error "Diagnostics not configured." +#error "No statistics configured." #endif #define METER_EMIT(meter) STATISTIC(MeterEmit(meter)) diff --git a/mps/code/mpm.h b/mps/code/mpm.h index 404d0bac54a..44b045b0c1d 100644 --- a/mps/code/mpm.h +++ b/mps/code/mpm.h @@ -911,7 +911,7 @@ extern Size VMMapped(VM vm); extern void StackProbe(Size depth); -/* STATISTIC -- gather diagnostics (in some varieties) +/* STATISTIC -- gather statistics (in some varieties) * * The argument of STATISTIC is an expression; the expansion followed by * a semicolon is syntactically a statement. @@ -920,7 +920,7 @@ extern void StackProbe(Size depth); * a semicolon is syntactically a statement. * * STATISTIC_WRITE is inserted in WriteF arguments to output the values - * of diagnostic fields. + * of statistic fields. * * .statistic.whitehot: The implementation of STATISTIC for * non-statistical varieties passes the parameter to DISCARD to ensure @@ -928,13 +928,13 @@ extern void StackProbe(Size depth); * passed as part of a comma-expression so that its type is not * important. This permits an expression of type void. */ -#if defined(DIAGNOSTICS) +#if defined(STATISTICS) #define STATISTIC(gather) BEGIN (gather); END #define STATISTIC_STAT(gather) BEGIN gather; END #define STATISTIC_WRITE(format, arg) (format), (arg), -#elif defined(DIAGNOSTICS_NONE) +#elif defined(STATISTICS_NONE) #define STATISTIC(gather) DISCARD(((gather), 0)) #define STATISTIC_STAT(gather) DISCARD_STAT(gather) @@ -942,7 +942,7 @@ extern void StackProbe(Size depth); #else -#error "No diagnostics configured." +#error "No statistics configured." #endif diff --git a/mps/code/mpmtypes.h b/mps/code/mpmtypes.h index f7da1f58d7c..868bfa283ae 100644 --- a/mps/code/mpmtypes.h +++ b/mps/code/mpmtypes.h @@ -454,12 +454,12 @@ typedef double WriteFD; * leave them in, see design.mps.metrics. */ -#if defined(DIAGNOSTICS) +#if defined(STATISTICS) #define STATISTIC_DECL(field) field -#elif defined(DIAGNOSTICS_NONE) +#elif defined(STATISTICS_NONE) #define STATISTIC_DECL(field) field #else -#error "No diagnostics configured." +#error "No statistics configured." #endif