pg.ddx.io pgsql-hackers@postgresql.org mailing list archive
help / color / mirror / Atom feed From: Tom Lane <tgl@sss.pgh.pa.us>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Mark Dilger <mark.dilger@enterprisedb.com>
Cc: Noah Misch <noah@leadboat.com>
Cc: Peter Geoghegan <pg@bowt.ie>
Cc: Thomas Munro <thomas.munro@gmail.com>
Cc: Andrey M. Borodin <x4mmm@yandex-team.ru>
Cc: Stephen Frost <sfrost@snowman.net>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: Amul Sul <sulamul@gmail.com>
Cc: Dilip Kumar <dilipbalaut@gmail.com>
Cc: Andres Freund <andres@anarazel.de>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Subject: Re: pg_amcheck contrib application
Date: Sat, 13 Mar 2021 09:50:54 -0500
Message-ID: <2611912.1615647054@sss.pgh.pa.us> (raw )
In-Reply-To: <CA+Tgmoakmgv7Pd0sHJedzWB=j-+htESZrei2PaEnLJ8mhqSZXA@mail.gmail.com >
References: <CA+TgmoZ1DP0pkLyuG9y7Jtn2v7N-+dnVxbvBAT__u4-d=UYmbw@mail.gmail.com >
<A80D68F6-E38F-482D-9522-E2FB6AAFE8A1@enterprisedb.com >
<CA+TgmoY3_U=QuQWo4DArBSp+tg2MiCHLwDN_9U2H_iTxj3UcjA@mail.gmail.com >
<9E76E46A-48B2-4869-BD0C-422204C1F767@enterprisedb.com >
<F0A1FD70-A2F4-4528-8A03-8650CAEC0554@enterprisedb.com >
<CA+TgmoYoW2NNQC5qzEfsR9cYWpigqQgP_h5MZCLVt1XRbsXTXQ@mail.gmail.com >
<C37D28BA-3BA3-4776-B812-17F05F3472D8@enterprisedb.com >
<2574324.1615611372@sss.pgh.pa.us >
<2588078.1615613250@sss.pgh.pa.us >
<2589781.1615615635@sss.pgh.pa.us >
<20210313061655.GC3099026@rfd.leadboat.com >
<6BBDE6C1-3F40-4009-896D-9CA9D87BEC9A@enterprisedb.com >
<2590503.1615616574@sss.pgh.pa.us >
<E57D4481-19AB-4291-AB2D-3364CA073AD3@enterprisedb.com >
<2591070.1615617371@sss.pgh.pa.us >
<1911287A-3420-4C23-ACF7-4D92EA580B70@enterprisedb.com >
<CA+Tgmoakmgv7Pd0sHJedzWB=j-+htESZrei2PaEnLJ8mhqSZXA@mail.gmail.com >
Robert Haas <robertmhaas@gmail.com> writes:
> I think it would be good to use a non-zero value here. We're doing a
> lot of poking into raw bytes here, and if something goes wrong, a zero
> value is more likely to look like something normal than whatever else.
> I suggest picking a value where all 8 bytes are the same, but not
> zero, and ideally chosen so that they don't look much like any of the
> surrounding bytes.
Actually, it seems like we can let pack/unpack deal with byte-swapping
within 32-bit words; what we lose by not using 'q' format is just the
ability to correctly swap the two 32-bit words. Hence, any value in
which upper and lower halves are the same should work, say
0x1234567812345678.
regards, tom lane
view thread (161+ messages) latest in thread
Message-ID: <2611912.1615647054@sss.pgh.pa.us>
Permalink: ../2611912.1615647054@sss.pgh.pa.us/
Also on: postgresql.org/message-id/2611912.1615647054@sss.pgh.pa.us
copy link · copy postgr.es
reply Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: tgl@sss.pgh.pa.us, robertmhaas@gmail.com, mark.dilger@enterprisedb.com, noah@leadboat.com, pg@bowt.ie, thomas.munro@gmail.com, x4mmm@yandex-team.ru, sfrost@snowman.net, michael@paquier.xyz, sulamul@gmail.com, dilipbalaut@gmail.com, andres@anarazel.de
Subject: Re: pg_amcheck contrib application
In-Reply-To: <2611912.1615647054@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox