[2744] in java-interest

home help back first fref pref prev next nref lref last post

Re: Stack Overflow

daemon@ATHENA.MIT.EDU (Arthur van Hoff)
Thu Oct 12 14:41:10 1995

Date: Thu, 12 Oct 1995 09:57:11 -0700
From: Arthur.Vanhoff@Eng.Sun.COM (Arthur van Hoff)
To: n1061925@dodo.fit.qut.edu.au
Cc: java-interest@java.Eng.Sun.COM


Hi Rick,

> I read the article :
>     HotJava : The Security Story (page 2 particularly)
> 
> Can anyone give me an example (if possible in Java codes )
> How stack overflow can happen, and how Java handles it ?

Stack overflow of the operand stack can't happen because the
virtual machine is required to run with a bounded stack. This
is verified by the byte-code verifier.

Execution stack overflow is possible if you cause unbounded
recursion. Stack frames are heap allocated (in blocks). An
overflow occurs when you run out of heap space, or when you
reach a user definable limit. I believe this limit is checked
on each method invokation.

Have fun,

	Arthur van Hoff
	
-
Note to Sun employees: this is an EXTERNAL mailing list!
Info: send 'help' to java-interest-request@java.sun.com

home help back first fref pref prev next nref lref last post