Skip to content

Commit 782365a

Browse files
committed
Remove useless picksplit-doesn't-support-secondary-split log spam.
This LOG message was put in over five years ago with the evident expectation that we'd make all GiST opclasses support secondary split directly. However, no such thing ever happened, and indeed the number of opclasses supporting it decreased to zero in 9.2. The reason is that improving on the default implementation isn't that easy --- the opclass-specific code that did exist, before 9.2, doesn't appear to have been any improvement over the default. Hence, remove the message altogether. There's certainly no point in nagging users about this in released branches, but I doubt that we'll ever implement complete opclass-specific support anyway.
1 parent a260208 commit 782365a

File tree

1 file changed

+5
-15
lines changed

1 file changed

+5
-15
lines changed

src/backend/access/gist/gistsplit.c

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -458,11 +458,6 @@ gistUserPicksplit(Relation r, GistEntryVector *entryvec, int attno, GistSplitVec
458458

459459
/* Do a generic split */
460460
genericPickSplit(giststate, entryvec, sv, attno);
461-
462-
/* Clean up if we're in a secondary split */
463-
if (sv->spl_ldatum_exists || sv->spl_rdatum_exists)
464-
supportSecondarySplit(r, giststate, attno, sv,
465-
v->spl_lattr[attno], v->spl_rattr[attno]);
466461
}
467462
else
468463
{
@@ -471,18 +466,13 @@ gistUserPicksplit(Relation r, GistEntryVector *entryvec, int attno, GistSplitVec
471466
sv->spl_left[sv->spl_nleft - 1] = (OffsetNumber) (entryvec->n - 1);
472467
if (sv->spl_right[sv->spl_nright - 1] == InvalidOffsetNumber)
473468
sv->spl_right[sv->spl_nright - 1] = (OffsetNumber) (entryvec->n - 1);
474-
475-
/* Clean up if we're in a secondary split */
476-
if (sv->spl_ldatum_exists || sv->spl_rdatum_exists)
477-
{
478-
elog(LOG, "picksplit method for column %d of index \"%s\" doesn't support secondary split",
479-
attno + 1, RelationGetRelationName(r));
480-
481-
supportSecondarySplit(r, giststate, attno, sv,
482-
v->spl_lattr[attno], v->spl_rattr[attno]);
483-
}
484469
}
485470

471+
/* Clean up if PickSplit didn't take care of a secondary split */
472+
if (sv->spl_ldatum_exists || sv->spl_rdatum_exists)
473+
supportSecondarySplit(r, giststate, attno, sv,
474+
v->spl_lattr[attno], v->spl_rattr[attno]);
475+
486476
/* emit union datums computed by PickSplit back to v arrays */
487477
v->spl_lattr[attno] = sv->spl_ldatum;
488478
v->spl_rattr[attno] = sv->spl_rdatum;

0 commit comments

Comments
 (0)