Re: Time since Login?

2009-04-23 Thread Greg Guerin
Scott Ribe wrote: "Microseconds" ;-) Could be. Or picoFortnights() with a conversion factor. -- GG ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderato

Re: Time since Login?

2009-04-22 Thread Scott Ribe
> There's > also a function, whose name I forget, that returns microseconds since > startup. "Microseconds" ;-) -- Scott Ribe scott_r...@killerbytes.com http://www.killerbytes.com/ (303) 722-0567 voice ___ Cocoa-dev mailing list (Cocoa-dev@lists.a

Re: Time since Login?

2009-04-22 Thread Alastair Houghton
On 22 Apr 2009, at 18:31, Gwynne Raskind wrote: On Apr 22, 2009, at 12:00 AM, Jeremy W. Sherman wrote: How about just nice(1)-ing the process doing the intense processing to be lower-priority, and letting the scheduler sort it all out? It's my understanding that nice() prioritization is eff

Re: Time since Login?

2009-04-22 Thread Sean McBride
On 4/22/09 3:43 AM, Trygve Inda said: >(b) elapsed time since startup The old TickCount() API returns this. -- Sean McBride, B. Eng s...@rogue-research.com Rogue Researchwww.rogue-research.com Ma

Re: Time since Login?

2009-04-22 Thread Greg Guerin
Trygve Inda wrote: (b) elapsed time since startup Boot-time is available from sysctl, name "kern.boottime". There's also a function, whose name I forget, that returns microseconds since startup. I wouldn't be surprised if there were additional ways to get this info. My goal is to d

Re: Time since Login?

2009-04-22 Thread Gwynne Raskind
On Apr 22, 2009, at 12:00 AM, Jeremy W. Sherman wrote: How about just nice(1)-ing the process doing the intense processing to be lower-priority, and letting the scheduler sort it all out? It's my understanding that nice() prioritization is effectively meaningless on Darwin, at least accordi

Re: Time since Login?

2009-04-22 Thread Dave DeLong
There's also the "w" command that you could run in an NSTask. Dave On Apr 22, 2009, at 1:21 AM, Uli Kusterer wrote: On 22.04.2009, at 04:43, Trygve Inda wrote: Is there also a way to determine some sort of overall system activity? There's Unix calls in the Kernel to do this, for instance

Re: Time since Login?

2009-04-22 Thread Uli Kusterer
On 22.04.2009, at 04:43, Trygve Inda wrote: Is there also a way to determine some sort of overall system activity? There's Unix calls in the Kernel to do this, for instance host_statistics() with the HOST_CPU_LOAD_INFO selector. They're a little fiddly to use because everything you do in

Re: Time since Login?

2009-04-21 Thread Jeremy W. Sherman
you to getloadavg(3) to find out how much work is going on and sysctl(3) to get the kern.boottime. —Jeremy 2009/4/21 Trygve Inda > How can I get: > > (a) elapsed time since login > > (b) elapsed time since startup > > ?? > > My goal is to delay some intense processing u

Time since Login?

2009-04-21 Thread Trygve Inda
How can I get: (a) elapsed time since login (b) elapsed time since startup ?? My goal is to delay some intense processing until the system is fully up and running as it seems to do a lot of housekeeping at startup. Is there also a way to determine some sort of overall system activity? It may