Calculate how long a PHP script takes to run