| From: | John Naylor <john(dot)naylor(at)postgresql(dot)org> |
|---|---|
| To: | pgsql-committers(at)lists(dot)postgresql(dot)org |
| Subject: | pgsql: Simplify SortSupport for the macaddr data type |
| Date: | 2026-04-07 06:33:53 |
| Message-ID: | E1wA00W-003Lky-37@gemulon.postgresql.org |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-committers |
Simplify SortSupport for the macaddr data type
As of commit 6aebedc38 Datums are 64-bit values. Since MAC addresses
have only 6 bytes, the abbreviated key always contains the entire
MAC address and is thus authoritative (for practical purposes -- the
tuple sort machinery has no way of knowing that). Abbreviating this
datatype is cheap, and aborting abbreviation prevents optimizations
like radix sort, so remove cardinality estimation.
Author: Aleksander Alekseev <aleksander(at)tigerdata(dot)com>
Reviewed-by: Andrey Borodin <x4mmm(at)yandex-team(dot)ru>
Reviewed-by: Michael Paquier <michael(at)paquier(dot)xyz>
Suggested-by: John Naylor <johncnaylorls(at)gmail(dot)com>
Discussion: https://postgr.es/m/CAJ7c6TMk10rF_LiMz6j9rRy1rqk-5s+wBPuBefLix4cY+-4s1w@mail.gmail.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/30229be755e703cf23fd73e95c5a515f9011cb5a
Modified Files
--------------
src/backend/utils/adt/mac.c | 101 +++-----------------------------------------
1 file changed, 6 insertions(+), 95 deletions(-)
| From | Date | Subject | |
|---|---|---|---|
| Next Message | John Naylor | 2026-04-07 08:53:32 | pgsql: Use .h for the file containing the page checksum code fragment |
| Previous Message | Michael Paquier | 2026-04-07 06:25:19 | pgsql: Mark JumbleState as a const in the post_parse_analyze hook |