Skip site navigation (1) Skip section navigation (2)

pgsql: Avoid detoast in texteq/textne/byteaeq/byteane forunequal-lengt

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Avoid detoast in texteq/textne/byteaeq/byteane forunequal-lengt
Date: 2011-01-18 19:12:41
Message-ID: E1PfGyv-0000iA-7D@gemulon.postgresql.org (view raw or flat)
Thread:
Lists: pgsql-committers
Avoid detoast in texteq/textne/byteaeq/byteane for unequal-length strings.

We can get the length of a compressed or out-of-line datum without actually
detoasting it.  If the lengths of two strings are unequal, we can then
conclude they are unequal without detoasting.  That saves considerable work
in an admittedly less-common case, without costing anything much when the
optimization doesn't apply.

Noah Misch

Branch
------
master

Details
-------
http://git.postgresql.org/gitweb?p=postgresql.git;a=commitdiff;h=1b393f4e5db4fd6bbc86a4e88785b6945a1541d0

Modified Files
--------------
src/backend/utils/adt/varlena.c |  116 +++++++++++++++++++++++++--------------
1 files changed, 75 insertions(+), 41 deletions(-)

pgsql-committers by date

Next:From: Bruce MomjianDate: 2011-01-18 20:53:57
Subject: pgsql: In test_fsync,adjust test headings to match wal_sync_method val
Previous:From: Magnus HaganderDate: 2011-01-18 19:04:05
Subject: pgsql: Log replication connections only when log_connections is on

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group