mallinfo for 64bit

A

Amit Gupta

Greetings

I am not sure if this is the right forum, however if you know the
answer, please post.

What is the alternative to mallinfo, for 64bit systems, for getting
the memory footprint within a program?

Thanks
Amit
 
I

Ian Collins

Amit said:
Greetings

I am not sure if this is the right forum, however if you know the
answer, please post.

What is the alternative to mallinfo, for 64bit systems, for getting
the memory footprint within a program?
Have you checked your documentation or man pages? mallinfo() isn't
standard, so you will have to check your specific version.
 
A

Amit Gupta

Have you checked your documentation or man pages? mallinfo() isn't
standard, so you will have to check your specific version.

Sorry, but what do you mean, check your specific version?
 
M

Mark McIntyre

Sorry, but what do you mean, check your specific version?

He means that since mallinfo() isn't standardised, each platform may
implement it differently. Yo uneed to read the manpages for your
version to determine what it does, and then probably ask in
comp.unix.programmer for advice.
--
Mark McIntyre

"Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are,
by definition, not smart enough to debug it."
--Brian Kernighan
 
K

Keith Thompson

Mark McIntyre said:
On Thu, 08 Nov 2007 20:54:10 -0000, in comp.lang.c , Amit Gupta


He means that since mallinfo() isn't standardised, each platform may
implement it differently. Yo uneed to read the manpages for your
version to determine what it does, and then probably ask in
comp.unix.programmer for advice.

He means that since mallinfo() isn't defined by the C standard, it may
not exist at all on your system. It's also possible that different
systems could have functions with the same name that do different
things. The documentation for your OS, or for your compiler, or for
your runtime library is the first place to look. If that fails, try a
newsgroup that deals with your system; if you're on a Unix-like
system, that would be comp.unix.programmer.

(mallinfo() isn't defined by POSIX, but it's part of the GNU libc.)
 

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,764
Messages
2,569,566
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top