pgsql: Use PageIndexTupleOverwrite() within nbtree.

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

pgsql: Use PageIndexTupleOverwrite() within nbtree.

Peter Geoghegan-4
Use PageIndexTupleOverwrite() within nbtree.

Use the PageIndexTupleOverwrite() bufpage.c routine within nbtree
instead of deleting a tuple and re-inserting its replacement.  This
makes the intent of affected code slightly clearer.  It also makes
CREATE INDEX slightly faster, since there is no longer a need to shift
every leaf page's line pointer array back and forth during index builds.

Author: Peter Geoghegan, Anastasia Lubennikova
Reviewed-By: Anastasia Lubennikova
Discussion: https://postgr.es/m/CAH2-Wz=Zk=B9+Vwm376WuO7YTjFc2SSskifQm4Nme3RRRPtOSQ@...

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/af0ba49809b57203d87702b315b64f1fd53c728d

Modified Files
--------------
src/backend/access/nbtree/nbtpage.c |  9 ++++-----
src/backend/access/nbtree/nbtsort.c | 21 ++++++---------------
2 files changed, 10 insertions(+), 20 deletions(-)