in reply to Script execution time

time() and $^T will be giving you elapsed real time, but in whole seconds.

To get something with a finer grain, you should look at Time::HiRes. That provides:

Update: Time::HiRes::time() is supported on Winders. Unfortunately Time::HiRes::clock_gettime() isn't... Time::HiRes::clock() I find is also not implemented on Winders :-(

However, testing on Linux and Windows XP, suggests that the following is supported by POSIX:

use POSIX qw(CLOCKS_PER_SEC) ; my ($realtime, $user, $system, $cuser, $csystem) = POSIX::times() ;
where this is retrning: the elapsed realtime since some point in the past (such as system startup); user and system times for this process; and user and system times used by child processes. They are in units of CLOCKS_PER_SEC, which on my XP is 1000 (so ms).