Re: More tests to stress directly checksum_impl.h - Mailing list pgsql-hackers

From Tom Lane
Subject Re: More tests to stress directly checksum_impl.h
Date
Msg-id 18588.1583525067@sss.pgh.pa.us
Whole thread Raw
In response to More tests to stress directly checksum_impl.h  (Michael Paquier <michael@paquier.xyz>)
Responses Re: More tests to stress directly checksum_impl.h  (Michael Paquier <michael@paquier.xyz>)
List pgsql-hackers
Michael Paquier <michael@paquier.xyz> writes:
> Attached is a patch to close the gap by adding new tests to
> pageinspect aimed at detecting any formula change.  The trick is to
> make the page data representative enough so as it is possible to
> detect problems if any part of the formulas are changed, like updates
> of pg_checksum_block or checksumBaseOffsets.
> Any thoughts or other ideas?

I wonder whether big-endian machines will compute the same values.
A quick look at our checksum implementation makes it look like the
results will depend on the endianness.

Between that and the BLCKSZ dependency, it's not clear that we can
test this with just a plain old expected-file test case.  Might
need to fall back to a TAP test.

Another way would be variant output files, which could be a sane
solution if we put this in its own test script.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: range_deserialize + range_get_flags
Next
From: Tom Lane
Date:
Subject: Re: effective_io_concurrency's steampunk spindle maths