tableam: Avoid relying on relation size to determine validity of tids.

Andres Freund <andres@anarazel.de>

Commit: 147e3722f7e531f15ba389a4d518efe8cd0bd736
Author: Andres Freund <andres@anarazel.de>
Date: 2019-05-18T01:56:55Z
Releases: 12.0
tableam: Avoid relying on relation size to determine validity of tids.

Instead add a tableam callback to do so. To avoid adding per
validation overhead, pass a scan to tuple_tid_valid. In heap's case
we'd otherwise incurred a RelationGetNumberOfBlocks() call for each
tid - which'd have added noticable overhead to nodeTidscan.c.

Author: Andres Freund
Reviewed-By: Ashwin Agrawal
Discussion: https://postgr.es/m/20190515185447.gno2jtqxyktylyvs@alap3.anarazel.de

Files

Discussion