pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
press - pr: Adding the list of spanish-speaking regional contacts.
2+ messages / 2 participants
[nested] [flat]

* press - pr: Adding the list of spanish-speaking regional contacts.
@ 2009-06-29 21:42 User Jcasanov <jcasanov@pgfoundry.org>
  0 siblings, 0 replies; 2+ messages in thread

From: jcasanov@pgfoundry.org @ 2009-06-29 21:42 UTC (permalink / raw)
  To: pgsql-committers

Log Message:
-----------
Adding the list of spanish-speaking regional contacts.

Modified Files:
--------------
    pr/releases/8.4/es:
        presskit84.html.es (r1.4 -> r1.5)
        (http://cvs.pgfoundry.org/cgi-bin/cvsweb.cgi/press/pr/releases/8.4/es/presskit84.html.es?r1=1.4&r...)
        release.txt.es (r1.3 -> r1.4)
        (http://cvs.pgfoundry.org/cgi-bin/cvsweb.cgi/press/pr/releases/8.4/es/release.txt.es?r1=1.3&r2=1....)




^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* pgsql: Turn tail recursion into iteration in CommitTransactionCommand()
@ 2024-03-08 11:19 Alexander Korotkov <akorotkov@postgresql.org>
  0 siblings, 0 replies; 2+ messages in thread

From: Alexander Korotkov @ 2024-03-08 11:19 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Turn tail recursion into iteration in CommitTransactionCommand()

Usually the compiler will optimize away the tail recursion anyway, but
if it doesn't, you can drive the function into stack overflow. For
example:

    (n=1000000; printf "BEGIN;"; for ((i=1;i<=$n;i++)); do printf "SAVEPOINT s$i;"; done; printf "ERROR; COMMIT;") | psql >/dev/null

In order to get better readability and less changes to the existing code the
recursion-replacing loop is implemented as a wrapper function.

Report by Egor Chindyaskin and Alexander Lakhin.
Discussion: https://postgr.es/m/1672760457.940462079%40f306.i.mail.ru
Author: Alexander Korotkov, Heikki Linnakangas

Branch
------
master

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

Modified Files
--------------
src/backend/access/transam/xact.c | 151 ++++++++++++++++++++++++++------------
1 file changed, 106 insertions(+), 45 deletions(-)



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2024-03-08 11:19 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2009-06-29 21:42 press - pr: Adding the list of spanish-speaking regional contacts. User Jcasanov <jcasanov@pgfoundry.org>
2024-03-08 11:19 pgsql: Turn tail recursion into iteration in CommitTransactionCommand() Alexander Korotkov <akorotkov@postgresql.org>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox