Hi Lothar, On Sun, Aug 16, 2009 at 6:53 PM, Lothar Scholz<sch...@scriptolutions.com> wrote: > PB> Yes, by many times. Part of that might be the expense of PHP's weak > PB> typing and references. > > No. Smalltalk, Javascript, Lua they all have the same problem with it
No, I disagree. Javascript, Lua and Smalltalk are much simpler languages. None of them have references, which make many of the implementation techniques more complicated. The weak typing you find in Lua and Javascript are not as complex as in PHP. Lua has no variable-variables. And there is plenty going on behind the scenes that make improving the interpreter hard. Take a look at Section 2 of my optimizer paper to see some of the challenges (https://www.cs.tcd.ie/~pbiggar/#wip-optimizer) > and they solve it in much more clever and performant ways. Javascript Yes, they often do. But there is still a larger challenge with PHP. > with its class free OO is even harder and with V8 they have a much > much better solution. Its very difficult for an interpreter to take advantage of PHP's static class hierarchy. So its not much of an advantage. V8 is a JIT, so its unfair to compare it to a straightforward interpreter. JIT's have plenty of disadvantages, most of all portability - V8 runs on very few platforms. > It's just the implementation - not the language. In my opinion, its almost certainly both. I've argued that pretty strongly in my papers. > <Strong Language Warning> > This sucks so huge and is such a > fucking lazy argument of an incompetent language development team. It think its more the lack of a language implementation team. I don't think there is anybody spending significant time on making the PHP interpreter faster. > I've seen that you talked about branch prediction misses in your > paper. Did you ever tried to compile the original PHP with different > compilers, for example from intel or sun studio? Did you test or have > you ever heard of someone who tested the influence of the profiling > feedback that modern C compilers offer? (Well don't ask me - it's > somewhere on my TODO list - but i also haven't had the time yet). I tried FDO with gcc 4.4 on phc generated code, but not on the PHP interpreter. I've not looked at other compilers either. Paul -- Paul Biggar paul.big...@gmail.com -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php