Skip to content

Commit 3063eb1

Browse files
Remove obsolete IndexBulkDeleteResult stats field.
The pages_removed field is no longer used for anything. It hasn't been possible for an index to physically shrink since old-style VACUUM FULL was removed by commit 0a469c8.
1 parent 62535ca commit 3063eb1

File tree

2 files changed

+4
-9
lines changed

2 files changed

+4
-9
lines changed

src/backend/access/gist/gistvacuum.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -546,9 +546,6 @@ gistvacuum_delete_empty_pages(IndexVacuumInfo *info, GistVacState *vstate)
546546

547547
ReleaseBuffer(buffer);
548548

549-
/* update stats */
550-
vstate->stats->pages_removed += deleted;
551-
552549
/*
553550
* We can stop the scan as soon as we have seen the downlinks, even if
554551
* we were not able to remove them all.

src/include/access/genam.h

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,16 +63,14 @@ typedef struct IndexVacuumInfo
6363
* of which this is just the first field; this provides a way for ambulkdelete
6464
* to communicate additional private data to amvacuumcleanup.
6565
*
66-
* Note: pages_removed is the amount by which the index physically shrank,
67-
* if any (ie the change in its total size on disk). pages_deleted and
68-
* pages_free refer to free space within the index file. Some index AMs
69-
* may compute num_index_tuples by reference to num_heap_tuples, in which
70-
* case they should copy the estimated_count field from IndexVacuumInfo.
66+
* Note: pages_deleted and pages_free refer to free space within the index
67+
* file. Some index AMs may compute num_index_tuples by reference to
68+
* num_heap_tuples, in which case they should copy the estimated_count field
69+
* from IndexVacuumInfo.
7170
*/
7271
typedef struct IndexBulkDeleteResult
7372
{
7473
BlockNumber num_pages; /* pages remaining in index */
75-
BlockNumber pages_removed; /* # removed during vacuum operation */
7674
bool estimated_count; /* num_index_tuples is an estimate */
7775
double num_index_tuples; /* tuples remaining */
7876
double tuples_removed; /* # removed during vacuum operation */

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy