forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit7df159a
committed
Delete empty pages during GiST VACUUM.
To do this, we scan GiST two times. In the first pass we make note ofempty leaf pages and internal pages. At second pass we scan throughinternal pages, looking for downlinks to the empty pages.Deleting internal pages is still not supported, like in nbtree, the lastchild of an internal page is never deleted. That means that if you have aworkload where new keys are always inserted to different area than whereold keys are removed, the index will still grow without bound. But the rateof growth will be an order of magnitude slower than before.Author: Andrey BorodinDiscussion:https://www.postgresql.org/message-id/B1E4DF12-6CD3-4706-BDBD-BF3283328F60@yandex-team.ru1 parentdf816f6 commit7df159a
File tree
11 files changed
+626
-49
lines changed- src
- backend/access
- gist
- rmgrdesc
- include/access
- test/regress
- expected
- sql
11 files changed
+626
-49
lines changedLines changed: 48 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
413 | 413 |
| |
414 | 414 |
| |
415 | 415 |
| |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
416 | 464 |
| |
417 | 465 |
| |
418 | 466 |
| |
|
Lines changed: 15 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
704 | 704 |
| |
705 | 705 |
| |
706 | 706 |
| |
| 707 | + | |
| 708 | + | |
| 709 | + | |
707 | 710 |
| |
708 | 711 |
| |
709 | 712 |
| |
| |||
838 | 841 |
| |
839 | 842 |
| |
840 | 843 |
| |
| 844 | + | |
| 845 | + | |
| 846 | + | |
| 847 | + | |
| 848 | + | |
| 849 | + | |
| 850 | + | |
| 851 | + | |
| 852 | + | |
| 853 | + | |
| 854 | + | |
| 855 | + | |
841 | 856 |
| |
842 | 857 |
| |
843 | 858 |
| |
|
Lines changed: 31 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
23 | 23 |
| |
24 | 24 |
| |
25 | 25 |
| |
| 26 | + | |
26 | 27 |
| |
27 | 28 |
| |
28 | 29 |
| |
| |||
829 | 830 |
| |
830 | 831 |
| |
831 | 832 |
| |
| 833 | + | |
| 834 | + | |
| 835 | + | |
832 | 836 |
| |
833 |
| - | |
| 837 | + | |
834 | 838 |
| |
835 | 839 |
| |
836 | 840 |
| |
837 |
| - | |
838 |
| - | |
| 841 | + | |
| 842 | + | |
| 843 | + | |
| 844 | + | |
| 845 | + | |
| 846 | + | |
| 847 | + | |
| 848 | + | |
| 849 | + | |
| 850 | + | |
| 851 | + | |
| 852 | + | |
| 853 | + | |
| 854 | + | |
| 855 | + | |
| 856 | + | |
| 857 | + | |
839 | 858 |
| |
840 | 859 |
| |
841 | 860 |
| |
| |||
859 | 878 |
| |
860 | 879 |
| |
861 | 880 |
| |
| 881 | + | |
| 882 | + | |
| 883 | + | |
| 884 | + | |
| 885 | + | |
| 886 | + | |
| 887 | + | |
| 888 | + | |
| 889 | + | |
862 | 890 |
| |
863 | 891 |
| |
864 | 892 |
| |
|
0 commit comments
Comments
(0)