From c8e2d422fd556292ab751392bf76f713fe9e9fc1 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Wed, 14 Aug 2024 08:02:32 +0200 Subject: Remove TRACE_SORT macro The TRACE_SORT macro guarded the availability of the trace_sort GUC setting. But it has been enabled by default ever since it was introduced in PostgreSQL 8.1, and there have been no reports that someone wanted to disable it. So just remove the macro to simplify things. (For the avoidance of doubt: The trace_sort GUC is still there. This only removes the rarely-used macro guarding it.) Reviewed-by: Heikki Linnakangas Discussion: https://www.postgresql.org/message-id/flat/be5f7162-7c1d-44e3-9a78-74dcaa6529f2%40eisentraut.org --- src/backend/utils/adt/numeric.c | 6 ------ 1 file changed, 6 deletions(-) (limited to 'src/backend/utils/adt/numeric.c') diff --git a/src/backend/utils/adt/numeric.c b/src/backend/utils/adt/numeric.c index d0f09237100..763a7f4be0f 100644 --- a/src/backend/utils/adt/numeric.c +++ b/src/backend/utils/adt/numeric.c @@ -2127,13 +2127,11 @@ numeric_abbrev_abort(int memtupcount, SortSupport ssup) */ if (abbr_card > 100000.0) { -#ifdef TRACE_SORT if (trace_sort) elog(LOG, "numeric_abbrev: estimation ends at cardinality %f" " after " INT64_FORMAT " values (%d rows)", abbr_card, nss->input_count, memtupcount); -#endif nss->estimating = false; return false; } @@ -2149,24 +2147,20 @@ numeric_abbrev_abort(int memtupcount, SortSupport ssup) */ if (abbr_card < nss->input_count / 10000.0 + 0.5) { -#ifdef TRACE_SORT if (trace_sort) elog(LOG, "numeric_abbrev: aborting abbreviation at cardinality %f" " below threshold %f after " INT64_FORMAT " values (%d rows)", abbr_card, nss->input_count / 10000.0 + 0.5, nss->input_count, memtupcount); -#endif return true; } -#ifdef TRACE_SORT if (trace_sort) elog(LOG, "numeric_abbrev: cardinality %f" " after " INT64_FORMAT " values (%d rows)", abbr_card, nss->input_count, memtupcount); -#endif return false; } -- cgit v1.2.3