Re: [HACKERS] [COMMITTERS] pgsql: pageinspect: Try to fix some bugs in previous commit. - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [HACKERS] [COMMITTERS] pgsql: pageinspect: Try to fix some bugs in previous commit.
Date
Msg-id 25729.1486141488@sss.pgh.pa.us
Whole thread Raw
In response to Re: [HACKERS] [COMMITTERS] pgsql: pageinspect: Try to fix some bugs in previous commit.  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: [HACKERS] [COMMITTERS] pgsql: pageinspect: Try to fix some bugsin previous commit.
List pgsql-hackers
Robert Haas <robertmhaas@gmail.com> writes:
> So based on that theory, here's a patch.
> ...
> In short, this patch makes hashfuncs.c consistent about (1) using the
> next wider signed type to report unsigned values and (2) using the
> GetDatum macro that matches the SQL return type in width and
> signedness.  Objections?

I haven't actually reviewed the patch, but your description of it sounds
sane.

One thing to think about is what will happen if someday we want to use
64-bit hash codes (a day I think is not that far away).  It sounds like
you've already chosen bigint for any output field that represents a
hash code or a related value such as a mask ... but it wouldn't hurt
to look through the fields with that in mind.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Alexander Korotkov
Date:
Subject: [HACKERS] LWLock optimization for multicore Power machines
Next
From: Tom Lane
Date:
Subject: Re: \if, \elseif, \else, \endif (was Re: [HACKERS] PSQL commands: \quit_if, \quit_unless)