LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
Search this Thread
Old 10-30-2004, 08:32 PM   #1
Dreampainter
LQ Newbie
 
Registered: Oct 2004
Posts: 1

Rep: Reputation: 0
get Physical memory in C/C++


Hi all,

I'm searching for a set of functions in C (or objects in C++) that returns the total and the available physical memory.

Does exists a STANDARD way, so that I can use the code also under Windows?

Bye and thanks!
Alex
 
Old 10-30-2004, 08:54 PM   #2
ToniT
Senior Member
 
Registered: Oct 2003
Location: Zurich, Switzerland
Distribution: Debian/unstable
Posts: 1,357

Rep: Reputation: 47
I don't know about any portable way, but in linux you can cat /proc/meminfo.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
free physical memory saavik Solaris / OpenSolaris 7 08-26-2005 12:22 PM
Less physical memory? ariek Debian 5 07-21-2005 02:23 PM
How to access physical memory in C? cyu021 Programming 6 03-27-2005 04:16 AM
how to use swap more than the physical memory Santosh_d Linux - General 9 03-24-2004 02:51 PM
How Much Physical Memory ? tied2 Linux - Newbie 3 06-17-2002 01:30 AM


All times are GMT -5. The time now is 02:01 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration