]> granicus.if.org Git - postgresql/commit
Add a fast pre-check for equality of equal-length strings.
authorRobert Haas <rhaas@postgresql.org>
Fri, 19 Sep 2014 16:39:00 +0000 (12:39 -0400)
committerRobert Haas <rhaas@postgresql.org>
Fri, 19 Sep 2014 16:39:00 +0000 (12:39 -0400)
commite246b3d6eac09d0770e6f68e69f2368d02db88af
treec5add391a0d8d6a69c8c108d1c949542f5611f7a
parent491c029dbc4206779cf659aa0ff986af7831d2ff
Add a fast pre-check for equality of equal-length strings.

Testing reveals that that doing a memcmp() before the strcoll() costs
practically nothing, at least on the systems we tested, and it speeds
up sorts containing many equal strings significatly.

Peter Geoghegan.  Review by myself and Heikki Linnakangas.  Comments
rewritten by me.
src/backend/utils/adt/varlena.c