Stack memory

C

c.lang.myself

I have doubts about validity of question below...but still due to my
curiosity i am asking.........
-----
We have 3 main portion in our memory analysis
*code segment
*heap
*stack

We can easily know memory available for heap by regular call for
malloc....which in my environment comes as 61KB

Now my question is can we also know maximum amount of stack memory
available in our environment.....
or there is some sharing of memory b/w heap and stack...?
 
I

Ian Collins

I have doubts about validity of question below...but still due to my
curiosity i am asking.........
-----
We have 3 main portion in our memory analysis
*code segment
*heap
*stack

We can easily know memory available for heap by regular call for
malloc....which in my environment comes as 61KB
That small?
Now my question is can we also know maximum amount of stack memory
available in our environment.....
or there is some sharing of memory b/w heap and stack...?

These questions are very system specific, how memory is partitioned and
size limits will be specified by your implementation's documentation.
 
C

c.lang.myself

That small?
I am using borland Turbo C environment..
These questions are very system specific, how memory is partitioned and
size limits will be specified by your implementation's documentation.

Can we know what is maximum amount of stack available in our
system.....
 
B

Barry Schwarz

I am using borland Turbo C environment..

Can we know what is maximum amount of stack available in our
system.....

There is no portable way. If you ask in a newsgroup that discusses
your system, you may find a system specific method.
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,772
Messages
2,569,593
Members
45,111
Latest member
KetoBurn
Top