Date: Wed, 24 Oct 2007 15:15:20 -0500
From: Ole Weidner <email@hidden>
Subject: system info / system stats library?
To: email@hidden
Message-ID: <email@hidden>
Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed
Hi,
is there any C/Obj-C library available that provides convenient
access to system stats (like the ones System Profiler provides)? I'm
especially interested in getting the # of CPUs/cores CPU type and
some memory statistics.
You want sysctl(3). For example:
int numCPUs;
size_t len = sizeof(int);
sysctlbyname("hw.activecpu", &numCPUs, &len, 0, 0);
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Unix-porting mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden