phpgroupware-developers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Phpgroupware-developers] i++ versus ++i


From: Joseph Engo
Subject: Re: [Phpgroupware-developers] i++ versus ++i
Date: Fri, 06 Feb 2004 23:11:56 -0500
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.6b) Gecko/20031205 Thunderbird/0.4

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Sure, its only a very minor preformance increase.  I don't suggest we
bulk change code ... only for new code.

I have adapted to MANY changes over the years, this wouldn't be
anything different.

Jeff Bachtel wrote:

| The benchmark results indicate that doing the change is a waste of
| developer effort. Add to that the possible error in an assignment
| case, and the time to track down and fix the error, and I can't see
|  why you would possibly switch from the syntax you are more
| comfortable using.
|
|> Very intresting ... I will make a note of using preincrements
|> from now on.  I don't think we should change all the code for it,
|> but if you see something in a section of code you are working on,
|> might as well go ahead and change it.
|>
|> Chris Weiss wrote:
|>
|> | So I did a benchmark, 100 iteration of 100,000 increments and
|> averaged them. | The pre-increment is .004 seconds faster on
|> average on P4 2.24Ghz using php | 4.3.1 CLI that comes with
|> Mandrake 9.1. | | So there's about a 40 nanosecond difference
|> between the two with | ++$i being | faster.
|
|
|
| _______________________________________________
| Phpgroupware-developers mailing list
| address@hidden
| http://mail.gnu.org/mailman/listinfo/phpgroupware-developers


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFAJGWL/AzmiD/o0voRAuMGAJkBbsNXgclkPBm/MAZIhYHC4mLKxACeNuvx
tfFRTUvR9AqJyea8NEhsgj0=
=C1y8
-----END PGP SIGNATURE-----






reply via email to

[Prev in Thread] Current Thread [Next in Thread]