pgsql: Replace direct assignments to VARATT_SIZEP(x) with SET_VARSIZE(x,

From: tgl(at)postgresql(dot)org (Tom Lane)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Replace direct assignments to VARATT_SIZEP(x) with SET_VARSIZE(x,
Date: 2007-02-27 23:48:10
Message-ID: 20070227234810.6C1C89FB32A@postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Log Message:
-----------
Replace direct assignments to VARATT_SIZEP(x) with SET_VARSIZE(x, len).
Get rid of VARATT_SIZE and VARATT_DATA, which were simply redundant with
VARSIZE and VARDATA, and as a consequence almost no code was using the
longer names. Rename the length fields of struct varlena and various
derived structures to catch anyplace that was accessing them directly;
and clean up various places so caught. In itself this patch doesn't
change any behavior at all, but it is necessary infrastructure if we hope
to play any games with the representation of varlena headers.
Greg Stark and Tom Lane

Modified Files:
--------------
pgsql/contrib/btree_gist:
btree_bit.c (r1.6 -> r1.7)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/btree_gist/btree_bit.c.diff?r1=1.6&r2=1.7)
btree_utils_var.c (r1.17 -> r1.18)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/btree_gist/btree_utils_var.c.diff?r1=1.17&r2=1.18)
pgsql/contrib/chkpass:
chkpass.c (r1.18 -> r1.19)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/chkpass/chkpass.c.diff?r1=1.18&r2=1.19)
pgsql/contrib/cube:
cube.c (r1.30 -> r1.31)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/cube/cube.c.diff?r1=1.30&r2=1.31)
cubedata.h (r1.7 -> r1.8)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/cube/cubedata.h.diff?r1=1.7&r2=1.8)
cubeparse.y (r1.16 -> r1.17)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/cube/cubeparse.y.diff?r1=1.16&r2=1.17)
pgsql/contrib/fuzzystrmatch:
dmetaphone.c (r1.10 -> r1.11)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/fuzzystrmatch/dmetaphone.c.diff?r1=1.10&r2=1.11)
pgsql/contrib/hstore:
hstore_op.c (r1.3 -> r1.4)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/hstore/hstore_op.c.diff?r1=1.3&r2=1.4)
pgsql/contrib/intagg:
int_aggregate.c (r1.25 -> r1.26)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/intagg/int_aggregate.c.diff?r1=1.25&r2=1.26)
pgsql/contrib/intarray:
_int_bool.c (r1.9 -> r1.10)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/intarray/_int_bool.c.diff?r1=1.9&r2=1.10)
_int_tool.c (r1.8 -> r1.9)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/intarray/_int_tool.c.diff?r1=1.8&r2=1.9)
pgsql/contrib/ltree:
ltree_op.c (r1.14 -> r1.15)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/ltree/ltree_op.c.diff?r1=1.14&r2=1.15)
pgsql/contrib/pg_trgm:
trgm_op.c (r1.6 -> r1.7)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/pg_trgm/trgm_op.c.diff?r1=1.6&r2=1.7)
pgsql/contrib/pgcrypto:
pgcrypto.c (r1.25 -> r1.26)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/pgcrypto/pgcrypto.c.diff?r1=1.25&r2=1.26)
pgp-pgsql.c (r1.8 -> r1.9)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/pgcrypto/pgp-pgsql.c.diff?r1=1.8&r2=1.9)
pgsql/contrib/sslinfo:
sslinfo.c (r1.5 -> r1.6)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/sslinfo/sslinfo.c.diff?r1=1.5&r2=1.6)
pgsql/contrib/tsearch2:
common.c (r1.9 -> r1.10)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/tsearch2/common.c.diff?r1=1.9&r2=1.10)
ginidx.c (r1.4 -> r1.5)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/tsearch2/ginidx.c.diff?r1=1.4&r2=1.5)
query.c (r1.31 -> r1.32)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/tsearch2/query.c.diff?r1=1.31&r2=1.32)
rank.c (r1.22 -> r1.23)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/tsearch2/rank.c.diff?r1=1.22&r2=1.23)
ts_cfg.c (r1.21 -> r1.22)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/tsearch2/ts_cfg.c.diff?r1=1.21&r2=1.22)
ts_stat.c (r1.16 -> r1.17)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/tsearch2/ts_stat.c.diff?r1=1.16&r2=1.17)
ts_stat.h (r1.6 -> r1.7)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/tsearch2/ts_stat.h.diff?r1=1.6&r2=1.7)
tsvector.c (r1.27 -> r1.28)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/tsearch2/tsvector.c.diff?r1=1.27&r2=1.28)
tsvector.h (r1.8 -> r1.9)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/tsearch2/tsvector.h.diff?r1=1.8&r2=1.9)
tsvector_op.c (r1.7 -> r1.8)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/tsearch2/tsvector_op.c.diff?r1=1.7&r2=1.8)
pgsql/contrib/xml2:
xpath.c (r1.14 -> r1.15)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/xml2/xpath.c.diff?r1=1.14&r2=1.15)
xslt_proc.c (r1.7 -> r1.8)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/contrib/xml2/xslt_proc.c.diff?r1=1.7&r2=1.8)
pgsql/doc/src/sgml:
xfunc.sgml (r1.125 -> r1.126)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/doc/src/sgml/xfunc.sgml.diff?r1=1.125&r2=1.126)
pgsql/src/backend/access/common:
heaptuple.c (r1.115 -> r1.116)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/access/common/heaptuple.c.diff?r1=1.115&r2=1.116)
indextuple.c (r1.80 -> r1.81)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/access/common/indextuple.c.diff?r1=1.80&r2=1.81)
reloptions.c (r1.3 -> r1.4)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/access/common/reloptions.c.diff?r1=1.3&r2=1.4)
pgsql/src/backend/access/heap:
tuptoaster.c (r1.70 -> r1.71)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/access/heap/tuptoaster.c.diff?r1=1.70&r2=1.71)
pgsql/src/backend/catalog:
pg_conversion.c (r1.35 -> r1.36)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/catalog/pg_conversion.c.diff?r1=1.35&r2=1.36)
pgsql/src/backend/executor:
execQual.c (r1.214 -> r1.215)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/executor/execQual.c.diff?r1=1.214&r2=1.215)
pgsql/src/backend/libpq:
be-fsstubs.c (r1.84 -> r1.85)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/libpq/be-fsstubs.c.diff?r1=1.84&r2=1.85)
pqformat.c (r1.43 -> r1.44)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/libpq/pqformat.c.diff?r1=1.43&r2=1.44)
pgsql/src/backend/storage/large_object:
inv_api.c (r1.121 -> r1.122)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/storage/large_object/inv_api.c.diff?r1=1.121&r2=1.122)
pgsql/src/backend/utils/adt:
acl.c (r1.137 -> r1.138)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/acl.c.diff?r1=1.137&r2=1.138)
array_userfuncs.c (r1.21 -> r1.22)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/array_userfuncs.c.diff?r1=1.21&r2=1.22)
arrayfuncs.c (r1.136 -> r1.137)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/arrayfuncs.c.diff?r1=1.136&r2=1.137)
cash.c (r1.69 -> r1.70)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/cash.c.diff?r1=1.69&r2=1.70)
char.c (r1.46 -> r1.47)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/char.c.diff?r1=1.46&r2=1.47)
date.c (r1.128 -> r1.129)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/date.c.diff?r1=1.128&r2=1.129)
datum.c (r1.33 -> r1.34)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/datum.c.diff?r1=1.33&r2=1.34)
dbsize.c (r1.10 -> r1.11)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/dbsize.c.diff?r1=1.10&r2=1.11)
encode.c (r1.18 -> r1.19)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/encode.c.diff?r1=1.18&r2=1.19)
float.c (r1.148 -> r1.149)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/float.c.diff?r1=1.148&r2=1.149)
formatting.c (r1.128 -> r1.129)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/formatting.c.diff?r1=1.128&r2=1.129)
genfile.c (r1.15 -> r1.16)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/genfile.c.diff?r1=1.15&r2=1.16)
geo_ops.c (r1.94 -> r1.95)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/geo_ops.c.diff?r1=1.94&r2=1.95)
int.c (r1.78 -> r1.79)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/int.c.diff?r1=1.78&r2=1.79)
int8.c (r1.64 -> r1.65)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/int8.c.diff?r1=1.64&r2=1.65)
like.c (r1.67 -> r1.68)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/like.c.diff?r1=1.67&r2=1.68)
like_match.c (r1.14 -> r1.15)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/like_match.c.diff?r1=1.14&r2=1.15)
mac.c (r1.36 -> r1.37)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/mac.c.diff?r1=1.36&r2=1.37)
nabstime.c (r1.149 -> r1.150)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/nabstime.c.diff?r1=1.149&r2=1.150)
network.c (r1.67 -> r1.68)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/network.c.diff?r1=1.67&r2=1.68)
numeric.c (r1.100 -> r1.101)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/numeric.c.diff?r1=1.100&r2=1.101)
oid.c (r1.70 -> r1.71)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/oid.c.diff?r1=1.70&r2=1.71)
oracle_compat.c (r1.69 -> r1.70)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/oracle_compat.c.diff?r1=1.69&r2=1.70)
pg_lzcompress.c (r1.24 -> r1.25)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/pg_lzcompress.c.diff?r1=1.24&r2=1.25)
pgstatfuncs.c (r1.38 -> r1.39)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/pgstatfuncs.c.diff?r1=1.38&r2=1.39)
quote.c (r1.21 -> r1.22)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/quote.c.diff?r1=1.21&r2=1.22)
regexp.c (r1.68 -> r1.69)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/regexp.c.diff?r1=1.68&r2=1.69)
ruleutils.c (r1.251 -> r1.252)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/ruleutils.c.diff?r1=1.251&r2=1.252)
selfuncs.c (r1.227 -> r1.228)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/selfuncs.c.diff?r1=1.227&r2=1.228)
timestamp.c (r1.173 -> r1.174)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/timestamp.c.diff?r1=1.173&r2=1.174)
varbit.c (r1.52 -> r1.53)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/varbit.c.diff?r1=1.52&r2=1.53)
varchar.c (r1.121 -> r1.122)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/varchar.c.diff?r1=1.121&r2=1.122)
varlena.c (r1.154 -> r1.155)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/varlena.c.diff?r1=1.154&r2=1.155)
version.c (r1.14 -> r1.15)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/version.c.diff?r1=1.14&r2=1.15)
xml.c (r1.31 -> r1.32)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/adt/xml.c.diff?r1=1.31&r2=1.32)
pgsql/src/backend/utils/cache:
relcache.c (r1.255 -> r1.256)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/cache/relcache.c.diff?r1=1.255&r2=1.256)
pgsql/src/backend/utils/mb:
mbutils.c (r1.61 -> r1.62)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/mb/mbutils.c.diff?r1=1.61&r2=1.62)
pgsql/src/include/access:
htup.h (r1.91 -> r1.92)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/access/htup.h.diff?r1=1.91&r2=1.92)
tupmacs.h (r1.31 -> r1.32)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/access/tupmacs.h.diff?r1=1.31&r2=1.32)
pgsql/src/include:
c.h (r1.218 -> r1.219)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/c.h.diff?r1=1.218&r2=1.219)
postgres.h (r1.76 -> r1.77)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/postgres.h.diff?r1=1.76&r2=1.77)
pgsql/src/include/utils:
array.h (r1.62 -> r1.63)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/utils/array.h.diff?r1=1.62&r2=1.63)
geo_decls.h (r1.52 -> r1.53)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/utils/geo_decls.h.diff?r1=1.52&r2=1.53)
numeric.h (r1.23 -> r1.24)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/utils/numeric.h.diff?r1=1.23&r2=1.24)
pg_lzcompress.h (r1.13 -> r1.14)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/utils/pg_lzcompress.h.diff?r1=1.13&r2=1.14)
rel.h (r1.97 -> r1.98)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/utils/rel.h.diff?r1=1.97&r2=1.98)
varbit.h (r1.25 -> r1.26)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/include/utils/varbit.h.diff?r1=1.25&r2=1.26)
pgsql/src/tutorial:
funcs.c (r1.16 -> r1.17)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/tutorial/funcs.c.diff?r1=1.16&r2=1.17)
funcs_new.c (r1.12 -> r1.13)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/tutorial/funcs_new.c.diff?r1=1.12&r2=1.13)

Browse pgsql-committers by date

  From Date Subject
Next Message Henry B. Hotz 2007-02-28 05:23:21 Re: [COMMITTERS] pgsql: Update Solaris FAQ.
Previous Message Bruce Momjian 2007-02-27 23:12:51 pgsql: Update release timeline to use unnumber lists HTML.