programs memory

This is a discussion on programs memory within the C Programming forums, part of the General Programming Boards category; tell me how to calculate how much memory a c program takes please.............

  1. #1
    Registered User
    Join Date
    Jan 2010
    Posts
    5

    Exclamation programs memory

    tell me how to calculate how much memory a c program takes
    please..........

  2. #2
    qny
    qny is offline
    Registered User
    Join Date
    Sep 2012
    Posts
    355
    If you're on a POSIX system, try getrlimit().

  3. #3
    Algorithm Dissector iMalc's Avatar
    Join Date
    Dec 2005
    Location
    New Zealand
    Posts
    6,308
    You don't. The system does it for you.
    On Windows you use a tool like Process Explorer to show you the application's private bytes statistic etc.
    My homepage
    Advice: Take only as directed - If symptoms persist, please see your debugger

    Linus Torvalds: "But it clearly is the only right way. The fact that everybody else does it some other way only means that they are wrong"

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. memory frames in programs
    By cs32 in forum C Programming
    Replies: 15
    Last Post: 01-11-2008, 04:06 AM
  2. Memory allocation for C programs
    By bhupesh.kec in forum C Programming
    Replies: 6
    Last Post: 01-08-2008, 04:32 AM
  3. Programs in memory
    By cboard_member in forum Tech Board
    Replies: 8
    Last Post: 03-19-2006, 06:30 PM
  4. Accessing memory of other programs
    By Inquirer in forum C Programming
    Replies: 4
    Last Post: 10-07-2003, 04:43 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21