From: | tgl(at)postgresql(dot)org (Tom Lane) |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Invent an assign-hook mechanism for psql variables similar to the |
Date: | 2006-08-29 15:19:52 |
Message-ID: | 20060829151952.731399FB25E@postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Log Message:
-----------
Invent an assign-hook mechanism for psql variables similar to the one
existing for backend GUC variables, and use this to eliminate repeated
fetching/parsing of psql variables in psql's inner loops. In a trivial
test with lots of 'select 1;' commands, psql's CPU time went down almost
10%, although of course the effect on total elapsed time was much less.
Per discussion about how to ensure the upcoming FETCH_COUNT patch doesn't
cost any performance when not being used.
Modified Files:
--------------
pgsql/src/bin/psql:
command.c (r1.171 -> r1.172)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/command.c.diff?r1=1.171&r2=1.172)
common.c (r1.125 -> r1.126)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/common.c.diff?r1=1.125&r2=1.126)
copy.c (r1.66 -> r1.67)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/copy.c.diff?r1=1.66&r2=1.67)
describe.c (r1.143 -> r1.144)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/describe.c.diff?r1=1.143&r2=1.144)
input.c (r1.58 -> r1.59)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/input.c.diff?r1=1.58&r2=1.59)
large_obj.c (r1.45 -> r1.46)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/large_obj.c.diff?r1=1.45&r2=1.46)
mainloop.c (r1.82 -> r1.83)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/mainloop.c.diff?r1=1.82&r2=1.83)
prompt.c (r1.47 -> r1.48)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/prompt.c.diff?r1=1.47&r2=1.48)
settings.h (r1.28 -> r1.29)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/settings.h.diff?r1=1.28&r2=1.29)
startup.c (r1.135 -> r1.136)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/startup.c.diff?r1=1.135&r2=1.136)
variables.c (r1.25 -> r1.26)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/variables.c.diff?r1=1.25&r2=1.26)
variables.h (r1.18 -> r1.19)
(http://developer.postgresql.org/cvsweb.cgi/pgsql/src/bin/psql/variables.h.diff?r1=1.18&r2=1.19)
From | Date | Subject | |
---|---|---|---|
Next Message | Teodor Sigaev | 2006-08-29 15:47:49 | pgsql: Fix mistyping |
Previous Message | Teodor Sigaev | 2006-08-29 14:05:44 | pgsql: Fix BUG #2594: Gin Indexes cause server to crash when it builds |