File tree Expand file tree Collapse file tree 3 files changed +0
-35
lines changed Expand file tree Collapse file tree 3 files changed +0
-35
lines changed Original file line number Diff line number Diff line change @@ -1026,33 +1026,6 @@ _bt_first(IndexScanDesc scan, ScanDirection dir)
10261026 if (goback )
10271027 offnum = OffsetNumberPrev (offnum );
10281028
1029- /*
1030- * By here the scan position is now set for the first key. If all further
1031- * tuples are expected to match we set the SK_BT_MATCHED flag to avoid
1032- * re-checking the scan key later. This is a big win for slow key matches
1033- * though is still significant even for fast datatypes.
1034- */
1035- switch (startKeys [0 ]-> sk_strategy )
1036- {
1037- case BTEqualStrategyNumber :
1038- break ;
1039-
1040- case BTGreaterEqualStrategyNumber :
1041- case BTGreaterStrategyNumber :
1042- if (ScanDirectionIsForward (dir ))
1043- startKeys [0 ]-> sk_flags |= SK_BT_MATCHED ;
1044- break ;
1045-
1046- case BTLessEqualStrategyNumber :
1047- case BTLessStrategyNumber :
1048- if (ScanDirectionIsBackward (dir ))
1049- startKeys [0 ]-> sk_flags |= SK_BT_MATCHED ;
1050- break ;
1051-
1052- default :
1053- break ;
1054- }
1055-
10561029 /* remember which buffer we have pinned, if any */
10571030 Assert (!BTScanPosIsValid (so -> currPos ));
10581031 so -> currPos .buf = buf ;
Original file line number Diff line number Diff line change @@ -1429,13 +1429,6 @@ _bt_checkkeys(IndexScanDesc scan,
14291429 bool isNull ;
14301430 Datum test ;
14311431
1432- /*
1433- * If the scan key has already matched we can skip this key, as long
1434- * as the index tuple does not contain NULL values.
1435- */
1436- if (key -> sk_flags & SK_BT_MATCHED && !IndexTupleHasNulls (tuple ))
1437- continue ;
1438-
14391432 /* row-comparison keys need special processing */
14401433 if (key -> sk_flags & SK_ROW_HEADER )
14411434 {
Original file line number Diff line number Diff line cha
64E9
nge @@ -646,7 +646,6 @@ typedef BTScanOpaqueData *BTScanOpaque;
646646 */
647647#define SK_BT_REQFWD 0x00010000 /* required to continue forward scan */
648648#define SK_BT_REQBKWD 0x00020000 /* required to continue backward scan */
649- #define SK_BT_MATCHED 0x00040000 /* required to skip further key match */
650649#define SK_BT_INDOPTION_SHIFT 24 /* must clear the above bits */
651650#define SK_BT_DESC (INDOPTION_DESC << SK_BT_INDOPTION_SHIFT)
652651#define SK_BT_NULLS_FIRST (INDOPTION_NULLS_FIRST << SK_BT_INDOPTION_SHIFT)
You can’t perform that action at this time.
0 commit comments