amcheck/verify_heapam doesn't check for interrupts
Peter Geoghegan <pg@bowt.ie>
From: Peter Geoghegan <pg@bowt.ie>
To: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Cc: Mark Dilger <mark.dilger@enterprisedb.com>,
Robert Haas <robertmhaas@gmail.com>
Date: 2021-08-26T21:38:18Z
Lists: pgsql-hackers
I just noticed that the new heapam amcheck verification code can take a very long time to respond to cancellations from pg_amcheck -- I saw that it took over 2 minutes on a large database on my workstation. It looks like we neglect to call CHECK_FOR_INTERRUPTS() anywhere inside verify_heapam.c. Is there any reason for this? Can't we just put a CHECK_FOR_INTERRUPTS() at the top of the outermost loop, inside verify_heapam()? Not sure if pg_amcheck itself is a factor here too -- didn't get that far. Thanks -- Peter Geoghegan
Commits
-
contrib/amcheck: Add heapam CHECK_FOR_INTERRUPTS().
- 191dce109be3 15.0 landed
- ba05dfe94304 14.0 landed