Re: Re: self operator within a double quoted string

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

 



On Wed, Apr 17, 2013 at 11:30 PM, NaMarPi <namarpi@xxxxxxxxx> wrote:

> I found that double quoted strings are more elegant in some situations
> than single ones, and I like identical solutions for identical problems,
> so that's why I asked this question.
>
> But finally found a reason why use single quoted strings instead of double:
> because the number of generated opcodes is less in the former case.
>
> Here is a detailed explanation (the url does not exist anymore,
> so make a search on the url and load the cashed version of the page):
>
> blog.golemon.com/2006/06/how-long-is-piece-of-string.html
>
> If anyone can run the vld package and share the currently relevant
> opcodes, it will be appreciated.
>
>
 First of all, I find the url is working fine for me. While it clearly
shows that there are more opcodes generated for a specific method, it does
not show performance difference. These opcodes are virtual opcodes, that
are to be translated by the engine, and there is no guarantee that each
opcode required the same amount of cpu cycles to process, and it could
perfectly be that the instruction with the most opcodes generated is
actually the fastest of all. A real comparison would benchmark this by cpu
cycles instead of number of opcodes.

- Matijn

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux