Re: AppleScript runs slow on Intel Macs
Re: AppleScript runs slow on Intel Macs
- Subject: Re: AppleScript runs slow on Intel Macs
- From: Christopher Nebel <email@hidden>
- Date: Thu, 21 Sep 2006 12:15:43 -0700
On Sep 21, 2006, at 8:45 AM, hackmiester (Hunter Fuller) wrote:
On 21 September 2006, at 10:41, Mark J. Reed wrote:
On 9/21/06, hackmiester (Hunter Fuller)
<email@hidden> wrote:
$ date; osascript speed.scpt; date
FYI, the usual UNIXy way to do that is just:
$ time osascript speed.scpt
I know, but honestly, I had no idea how to read that output. How DO
you decode it exactly? Here's my output from that command.
$ time osascript speed.scpt
Thursday 21 September 2006 10:43:7
real 0m0.642s
user 0m0.304s
sys 0m0.110s
There is a catch here, which is that there's more than one "time"
command -- some shells have their own built-in version, and the
outputs differ. For example, I use tcsh(1):
% time osascript -e 2+2 > /dev/null
0.270u 0.050s 0:00.40 80.0% 0+0k 0+1io 0pf+0w
Moderately cryptic, though there is a decoder ring (that is, the tcsh
man page). If I use time(1) explicitly, I get something a bit more
readable:
% /usr/bin/time osascript -e 2+2 > /dev/null
0.35 real 0.26 user 0.04 sys
...which is pretty much what Hunter saw. To elaborate:
"real" time is also known as "wall clock" time -- that is, the
physical start-to-finish time. Depending on how much else is going on
in the system and time the process spends idling (waiting for an event
reply, say), this may be much larger than the sum of the other two
numbers. "user" time is the time spent executing code that belongs to
that process, and "sys" time is the time spent executing kernel code.
--Chris Nebel
AppleScript Engineering
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden