A friendly place for programming greenhorns!
Big Moose Saloon
Search
|
Java FAQ
|
Recent Topics
Register / Login
Win a copy of
The Mikado Method
this week in the
Agile and other Processes
forum!
JavaRanch
»
Java Forums
»
Java
»
Beginning Java
Author
When will a variable use memory from stack and when will use memory from heap?
Mr Chan
Greenhorn
Joined: Jun 08, 2002
Posts: 2
posted
Jun 08, 2002 09:35:00
0
When will a variable use memory from stack and use memory from heap?
jason adam
Chicken Farmer ()
Ranch Hand
Joined: May 08, 2001
Posts: 1932
posted
Jun 09, 2002 13:25:00
0
This question is not based on I/O or streams, would probably be better answered in the beginners forum.
Jack J. Jackson
Greenhorn
Joined: Apr 20, 2002
Posts: 27
posted
Jun 10, 2002 20:12:00
0
Local variables are allocated from stack whereas instance and class variables are allocated as part of object instantiation and consume heap memory.
Jack
I agree. Here's the link:
http://ej-technologies/jprofiler
- if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
subject: When will a variable use memory from stack and when will use memory from heap?
Similar Threads
difference between stack and heap
Heap and Stack in memory
When will a variable use memory from stack and when will use memory from heap?
Pool and Heap's of Confusion
What is Stack memory & heap memory
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter