File tree Expand file tree Collapse file tree 7 files changed +21
-296
lines changed
Expand file tree Collapse file tree 7 files changed +21
-296
lines changed Original file line number Diff line number Diff line change @@ -190,7 +190,6 @@ distprep:
190190 $(MAKE ) -C utils distprep
191191 $(MAKE ) -C utils/adt jsonpath_gram.c jsonpath_scan.c
192192 $(MAKE ) -C utils/misc guc-file.c
193- $(MAKE ) -C utils/sort qsort_tuple.c
194193
195194
196195# #########################################################################
@@ -312,8 +311,7 @@ maintainer-clean: distclean
312311 storage/lmgr/lwlocknames.h \
313312 utils/adt/jsonpath_gram.c \
314313 utils/adt/jsonpath_scan.c \
315- utils/misc/guc-file.c \
316- utils/sort/qsort_tuple.c
314+ utils/misc/guc-file.c
317315
318316
319317# #########################################################################
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -21,12 +21,4 @@ OBJS = \
2121 tuplesort.o \
2222 tuplestore.o
2323
24- tuplesort.o : qsort_tuple.c
25-
26- qsort_tuple.c : gen_qsort_tuple.pl
27- $(PERL ) $(srcdir ) /gen_qsort_tuple.pl $< > $@
28-
2924include $(top_srcdir ) /src/backend/common.mk
30-
31- maintainer-clean :
32- rm -f qsort_tuple.c
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -676,8 +676,27 @@ static void tuplesort_updatemax(Tuplesortstate *state);
676676 * reduces to ApplySortComparator(), that is single-key MinimalTuple sorts
677677 * and Datum sorts.
678678 */
679- #include "qsort_tuple.c"
680679
680+ #define ST_SORT qsort_tuple
681+ #define ST_ELEMENT_TYPE SortTuple
682+ #define ST_COMPARE_RUNTIME_POINTER
683+ #define ST_COMPARE_ARG_TYPE Tuplesortstate
684+ #define ST_CHECK_FOR_INTERRUPTS
685+ #define ST_SCOPE static
686+ #define ST_DECLARE
687+ #define ST_DEFINE
688+ #include "lib/sort_template.h"
689+
690+ #define ST_SORT qsort_ssup
691+ #define ST_ELEMENT_TYPE SortTuple
692+ #define ST_COMPARE (a , b , ssup ) \
693+ ApplySortComparator((a)->datum1, (a)->isnull1, \
694+ (b)->datum1, (b)->isnull1, (ssup))
695+ #define ST_COMPARE_ARG_TYPE SortSupportData
696+ #define ST_CHECK_FOR_INTERRUPTS
697+ #define ST_SCOPE static
698+ #define ST_DEFINE
699+ #include "lib/sort_template.h"
681700
682701/*
683702 * tuplesort_begin_xxx
Original file line number Diff line number Diff line change @@ -665,16 +665,6 @@ sub GenerateFiles
665665 );
666666 }
667667
668- if (IsNewer(
669- ' src/backend/utils/sort/qsort_tuple.c' ,
670- ' src/backend/utils/sort/gen_qsort_tuple.pl' ))
671- {
672- print " Generating qsort_tuple.c...\n " ;
673- system (
674- ' perl src/backend/utils/sort/gen_qsort_tuple.pl > src/backend/utils/sort/qsort_tuple.c'
675- );
676- }
677-
678668 if (IsNewer(' src/bin/psql/sql_help.h' , ' src/bin/psql/create_help.pl' ))
679669 {
680670 print " Generating sql_help.h...\n " ;
Original file line number Diff line number Diff line change @@ -62,7 +62,6 @@ if %DIST%==1 if exist src\backend\storage\lmgr\lwlocknames.h del /q src\backend\
6262if %DIST% == 1 if exist src\pl\plpython\spiexceptions.h del /q src\pl\plpython\spiexceptions.h
6363if %DIST% == 1 if exist src\pl\plpgsql\src\plerrcodes.h del /q src\pl\plpgsql\src\plerrcodes.h
6464if %DIST% == 1 if exist src\pl\tcl\pltclerrcodes.h del /q src\pl\tcl\pltclerrcodes.h
65- if %DIST% == 1 if exist src\backend\utils\sort\qsort_tuple.c del /q src\backend\utils\sort\qsort_tuple.c
6665if %DIST% == 1 if exist src\bin\psql\sql_help.c del /q src\bin\psql\sql_help.c
6766if %DIST% == 1 if exist src\bin\psql\sql_help.h del /q src\bin\psql\sql_help.h
6867if %DIST% == 1 if exist src\common\kwlist_d.h del /q src\common\kwlist_d.h
You can’t perform that action at this time.
0 commit comments