Re: tuple radix sort

From: cca5507 <cca5507(at)qq(dot)com>
To: John Naylor <johncnaylorls(at)gmail(dot)com>
Cc: zengman <zengman(at)halodbtech(dot)com>, pgsql-hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: tuple radix sort
Date: 2026-04-08 08:20:47
Message-ID: tencent_1FF6C288DAB8947599693C9B833F3BB2D007@qq.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> I also thought we should change this cast:
>
>         if (ssup->comparator == ssup_datum_signed_cmp)
>         {
> -               norm_datum1 = orig + ((uint64) PG_INT64_MAX) + 1;
> +               norm_datum1 = orig + (Int64GetDatum(PG_INT64_MAX)) + 1;
>         }
>
> Upthread you mention something else about treating Datum as an
> integer, but I'm not sure if this is what you meant since you didn't
> say. If you have concrete suggestions, feel free to share them.

I think we can keep it as is now. The idea of don't treat datum as an integer comes from:

https://www.postgresql.org/message-id/flat/8246d7ff-f4b7-4363-913e-827dadfeb145%40eisentraut.org

--
Regards,
ChangAo Chen

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Chao Li 2026-04-08 08:22:10 Re: PoC: Add condition variable support to WaitEventSetWait()
Previous Message Fujii Masao 2026-04-08 08:11:50 Re: Exit walsender before confirming remote flush in logical replication