Re: Default of max_stack_depth and getrlimit

From: Cédric Villemain <cedric(dot)villemain(at)dalibo(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Cc: "Heikki Linnakangas" <heikki(at)enterprisedb(dot)com>
Subject: Re: Default of max_stack_depth and getrlimit
Date: 2008-07-21 16:50:38
Message-ID: 200807211850.43686.cedric.villemain@dalibo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Le Monday 21 July 2008, Heikki Linnakangas a écrit :
> Cédric Villemain wrote:
> > Le Monday 21 July 2008, Heikki Linnakangas a écrit :
> >> I think we should differentiate between "infinite" and "unknown" in the
> >> return value of get_stack_depth_limit(), and use max_stack_depth of 2MB
> >> in case of infinite, and fall back to the 100kB only in the unknown
> >> case.
> >
> > Why 2MB ? I believed that 3.5MB is the effective good maximum , is that
> > too much ?
>
> 2MB is the value we set max_stack_depth to, unless getrlimit() says that
> the actual stack limit is lower than that.
>
> I believe the 2MB figure is just an arbitrary value, thought to be quite
> safe, but also high enough that most people won't need to raise it.
> Before we started to use getrlimit(), we used to just default
> max_stack_depth=2MB.

Ok, thank you for the explanation.

>
> --
> Heikki Linnakangas
> EnterpriseDB http://www.enterprisedb.com

--
Cédric Villemain
Administrateur de Base de Données
Cel: +33 (0)6 74 15 56 53
http://dalibo.com - http://dalibo.org

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message David E. Wheeler 2008-07-21 18:55:51 Re: PATCH: CITEXT 2.0 v4
Previous Message Heikki Linnakangas 2008-07-21 16:14:37 Re: Default of max_stack_depth and getrlimit