Hi Brian,

On Thu, Jun 4, 2015 at 7:33 AM, Brian Moon <br...@moonspot.net> wrote:

> This is a better representation of what you are trying to show. It removes
> all the magic call back stuff that could be adding to the slowness you are
> seeing. In addition, it does not create a new object on every call for the
> object method. Creating a new object is going to explicitly slow things
> down. But, it's not related to the call time.
>
> http://3v4l.org/biM9G
>

This version adds up precision errors because microtime() precision is not
high enough for
the purpose. Since the error is random, it does not affect proportion much
but total
execution time. Following damn code does better job for these kinds of
benchmarks.

http://3v4l.org/eJK07

See the total amount of execution time recorded.
If we really need pure execution time, then it should record "for loop"
execution time
with empty body.

Regards,

--
Yasuo Ohgaki
yohg...@ohgaki.net

Reply via email to