Solved

Heap, Stack & C++ Builder

Posted on 1997-07-23
3
849 Views
Last Modified: 2012-05-04
Hello, you all.  I'm working in an application for Windows95, with C++ Builder. I need to modify the size of stack and heap, because I run out of memory in runtime,
when my application tries to load big files. Could
you explain me how can I vary the size of stack & heap
using the code source or in another way? Thanks a lot...
0
Comment
Question by:mayorgas
3 Comments
 
LVL 4

Accepted Solution

by:
AVaulin earned 100 total points
Comment Utility
Modify what you want with STACKSIZE and HEAPSIZE module-definition statements in your .def (module-definition) file.
0
 

Expert Comment

by:BigRog
Comment Utility
For C++Builder it's simple.  With your project open, select the menu Options->Project, then select the tab titled Linker.  You will see the min and max stack sizes, ands that's all there is to it.  

As far as the heap size, you don't need to worry about that, you have access to all the available memory, so stack is all you need to modify.

Good luck,
BigRog
0
 

Author Comment

by:mayorgas
Comment Utility
The answer from AVaulin seems to be right for C++, but in C++ Builder, it seems better using the way explained by BigRog.
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Unlike C#, C++ doesn't have native support for sealing classes (so they cannot be sub-classed). At the cost of a virtual base class pointer it is possible to implement a pseudo sealing mechanism The trick is to virtually inherit from a base class…
What is C++ STL?: STL stands for Standard Template Library and is a part of standard C++ libraries. It contains many useful data structures (containers) and algorithms, which can spare you a lot of the time. Today we will look at the STL Vector. …
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now