Reputation: 1
Is it possible to know how much memory a program will need?
Upvotes: 0
Views: 647
Reputation: 72294
The usual method is to use some form of profiler. Many IDEs include their own, Netbeans for example has a particularly good profiler (in my opinion) for Java applications. This will show the memory consumption of your program as its running, and is good for testing for things such as memory leaks as well as overall consumption.
If you've only got the binary, then you'll just have to use a basic tool such as task manager or pmap. This won't give you nearly as much detail though.
Upvotes: 2
Reputation: 108
if you're using an IDE then it will probably have some in-built feature by which you can see the same...
In case you are executing directly, I guess probably the Task Manager is the best way.
Upvotes: 0