$start = Win32::GetTickCount(); sleep(2); #or some other crazy pieces of code $end = Win32::GetTickCount(); $length = $end - $start; print "It took us $length milliseconds to do the job.\n";