stack size limit ?

Discussion in 'Javascript' started by Une Bévue, Jun 4, 2008.

  1. Une Bévue

    Une Bévue Guest

    does exist a constant in JavScript (UA dependent) telling us the stack
    size limit ?

    from google I've found 1000 for Firefox, 100 for Safari 3
    verified experimetally

    The latest Webkit accepts a stack size of 5655 (on Mac OS X 10.4.11)
    --
    Une Bévue
    Une Bévue, Jun 4, 2008
    #1
    1. Advertising

  2. Une Bévue

    Evertjan. Guest

    Une Bév ue wrote on 04 jun 2008 in comp.lang.javascript:
    > does exist a constant in JavScript (UA dependent) telling us the stack
    > size limit ?
    >
    > from google I've found 1000 for Firefox, 100 for Safari 3
    > verified experimetally


    There are many stacks [li-fo memory] in JS.

    Do you mean the subroutine/function stack?
    This was discussed here in this NG recently for recursion.

    Or the mathmatical parser stack?

    Or ...?

    > The latest Webkit accepts a stack size of 5655 (on Mac OS X 10.4.11)


    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
    Evertjan., Jun 4, 2008
    #2
    1. Advertising

  3. Une Bévue

    Jorge Guest

    On Jun 4, 10:41 am, (Une
    Bévue) wrote:
    > does exist a constant in JavScript (UA dependent) telling us the stack
    > size limit ?


    Nope, I don't think so.

    >
    > from google I've found 1000 for Firefox, 100 for Safari 3
    > verified experimetally
    >
    > The latest Webkit accepts a stack size of 5655 (on Mac OS X 10.4.11)


    javascript:(function f(p){document.write(p+'<br>'); f(p+1); })(0)

    Betas:

    WebKit/Safari r34088 --> 139808 (!)
    FF3.0pre --> 2999
    IE8.0.6001 --> 2340

    Non-betas:

    Safari 3.1.1 --> 498
    FF2 --> 999
    IE 7.0.5730.11 --> 2507
    Opera 9.27 --> 3328

    cljs thread : "Javascript recursion limit"

    --Jorge.
    Jorge, Jun 4, 2008
    #3
  4. Une Bévue

    Une Bévue Guest

    Evertjan. <> wrote:

    > There are many stacks [li-fo memory] in JS.
    >
    > Do you mean the subroutine/function stack?
    > This was discussed here in this NG recently for recursion.


    subroutine/function stack.

    > Or the mathmatical parser stack?



    --
    Une Bévue
    Une Bévue, Jun 4, 2008
    #4
  5. Une Bévue

    Une Bévue Guest

    Jorge <> wrote:
    > javascript:(function f(p){document.write(p+'<br>'); f(p+1); })(0)
    >
    > Betas:
    >
    > WebKit/Safari r34088 --> 139808 (!)
    > FF3.0pre --> 2999
    > IE8.0.6001 --> 2340
    >
    > Non-betas:
    >
    > Safari 3.1.1 --> 498
    > FF2 --> 999
    > IE 7.0.5730.11 --> 2507
    > Opera 9.27 --> 3328
    >
    > cljs thread : "Javascript recursion limit"
    >
    > --Jorge.


    thanks for the tips !

    --
    Une Bévue
    Une Bévue, Jun 4, 2008
    #5
  6. [Sorry for posting the followup here, .invalid is filtered out]

    Jorge wrote:
    > On Jun 4, 10:41 am, (Une
    > Bévue) wrote:
    >> The latest Webkit accepts a stack size of 5655 (on Mac OS X 10.4.11)

    > javascript:(function f(p){document.write(p+'<br>'); f(p+1); })(0)
    >
    > Betas:
    >
    > WebKit/Safari r34088 --> 139808 (!)
    > FF3.0pre --> 2999
    > IE8.0.6001 --> 2340
    >
    > Non-betas:
    >
    > Safari 3.1.1 --> 498
    > FF2 --> 999
    > IE 7.0.5730.11 --> 2507
    > Opera 9.27 --> 3328


    However, in most cases the stack size would _not_ equal the number of
    recursions a stack can support:

    http://en.wikipedia.org/wiki/Call_stack#Structure


    PointedEars
    --
    Prototype.js was written by people who don't know javascript for people
    who don't know javascript. People who don't know javascript are not
    the best source of advice on designing systems that use javascript.
    -- Richard Cornford, cljs, <f806at$ail$1$>
    Thomas 'PointedEars' Lahn, Jun 5, 2008
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Andy Leszczynski
    Replies:
    1
    Views:
    724
    Christian Tismer
    Dec 9, 2005
  2. sunny
    Replies:
    5
    Views:
    2,087
    CBFalconer
    Aug 17, 2006
  3. Replies:
    1
    Views:
    1,056
    Victor Bazarov
    Jun 28, 2005
  4. Surinder Singh
    Replies:
    1
    Views:
    1,172
    Richard Bos
    Dec 20, 2007
  5. Replies:
    0
    Views:
    1,286
Loading...

Share This Page