Add oldest_extant_version metric

This commit is contained in:
2024-07-18 14:19:11 -07:00
parent b45dec2f1f
commit 11c3ca6766
+5
View File
@@ -3262,6 +3262,7 @@ struct __attribute__((visibility("hidden"))) ConflictSet::Impl {
if (n == nullptr) {
removalKey = {};
oldestExtantVersion = oldestVersionAtGcBegin;
oldest_extant_version.set(oldestExtantVersion);
oldestVersionAtGcBegin = oldestVersionFullPrecision;
#if DEBUG_VERBOSE && !defined(NDEBUG)
fprintf(stderr,
@@ -3310,6 +3311,7 @@ struct __attribute__((visibility("hidden"))) ConflictSet::Impl {
newestVersionFullPrecision = oldestVersion;
oldest_version.set(oldestVersionFullPrecision);
newest_version.set(newestVersionFullPrecision);
oldest_extant_version.set(oldestExtantVersion);
tls.~WriteContext();
new (&tls) WriteContext();
@@ -3432,6 +3434,9 @@ struct __attribute__((visibility("hidden"))) ConflictSet::Impl {
GAUGE(oldest_version,
"The lowest version that doesn't result in \"TooOld\" for checks");
GAUGE(newest_version, "The version of the most recent call to addWrites");
GAUGE(
oldest_extant_version,
"A lower bound on the lowest version associated with an existing entry");
#if MEASURE_CHECK_CPU_TIME
COUNTER(check_cpu_seconds_total,
"Total cpu seconds spent in a call to check");