heapam: Don't mimic MarkBufferDirtyHint() in inplace updates
Previously heap_inplace_update_and_unlock() used an operation order similar to
MarkBufferDirty(), to reduce the number of different approaches used for
updating buffers. However, in an upcoming patch, MarkBufferDirtyHint() will
switch to using the update protocol used by most other places (enabled by hint
bits only being set while holding a share-exclusive lock).
Luckily it's pretty easy to adjust heap_inplace_update_and_unlock(). As a
comment already foresaw, we can use the normal order, with the slight change
of updating the buffer contents after WAL logging.
Reviewed-by: Heikki Linnakangas <hlinnaka@iki.fi>
Reviewed-by: Noah Misch <noah@leadboat.com>
Discussion: https://postgr.es/m/5ubipyssiju5twkb7zgqwdr7q2vhpkpmuelxfpanetlk6ofnop@hvxb4g2amb2d
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/f4a4ce52c0d1565c13c436ea17960d22787ea752
Modified Files
--------------
src/backend/access/heap/heapam.c | 35 +++++++++++++----------------------
1 file changed, 13 insertions(+), 22 deletions(-)