Re: pgsql: Add various assertions to heap pruning code. - Mailing list pgsql-committers

From Michael Paquier
Subject Re: pgsql: Add various assertions to heap pruning code.
Date
Msg-id YYTTuYykpVXEfnOr@paquier.xyz
Whole thread Raw
In response to pgsql: Add various assertions to heap pruning code.  (Peter Geoghegan <pg@bowt.ie>)
Responses Re: pgsql: Add various assertions to heap pruning code.
List pgsql-committers
Hi Peter,

On Fri, Nov 05, 2021 at 02:09:47AM +0000, Peter Geoghegan wrote:
> Add various assertions to heap pruning code.
>
> These assertions document (and verify) our high level assumptions about
> how pruning can and cannot affect existing items from target heap pages.
> For example, one of the new assertions verifies that pruning does not
> set a heap-only tuple to LP_DEAD.

This generates some warnings on Windows without asserts:
pruneheap.c(847): warning C4101: 'htup' unreferenced local variable
pruneheap.c(859): warning C4101: 'tolp' unreferenced local variable

You could move those two variables within their USE_ASSERT_CHECKING
blocks, for example.

Thanks,
--
Michael

Attachment

pgsql-committers by date:

Previous
From: Michael Paquier
Date:
Subject: pgsql: Improve psql tab completion for COMMENT
Next
From: Peter Eisentraut
Date:
Subject: pgsql: pgcrypto: Remove non-OpenSSL support