Live data from Hacker News

PHP 7 Virtual Machine

nikic.github.io

1–10 of 128 posts

Re: PHP 7 Virtual Machine

#2
Great write up. Thank you for writing this. I've always been interested in the PHP VM, but it is not documented. Nikic is one smart dude.

Re: PHP 7 Virtual Machine

#3
It's fairly impressive that the php7 core team was able to release something that competes well with HHVM from a performance perspective.

I assume they are working with significantly fewer advantages and resources than Facebook, so that's a pretty nice result.

Re: PHP 7 Virtual Machine

#4
post #3

It's fairly impressive that the php7 core team was able to release something that competes well with HHVM from a performance perspective. I assume they are working with significantly fewer advantages and resources than Facebook, so that's a pretty nice result.

HHVM was released in 2011, while PHP 7 was released in 2015. So perhaps in that extra time there was additional techniques, optimizations, and technology that allowed PHP 7 to stay comparable in terms of performance to HHVM.

Re: PHP 7 Virtual Machine

#5
post #3

It's fairly impressive that the php7 core team was able to release something that competes well with HHVM from a performance perspective. I assume they are working with significantly fewer advantages and resources than Facebook, so that's a pretty nice result.

HHVM was released in 2011, while PHP 7 was released in 2015. So perhaps in that extra time there was additional techniques, optimizations, and technology that allowed PHP 7 to stay comparable in terms of performance to HHVM.

There was a long time to catch up, yes. But HHVM did several big improvements to their JIT tech between then and now.

PHP7 also rolled out with very little noise about stability, migration issues, etc.

Not knocking FB at all, just noting the PHP folks did a nice job.

Re: PHP 7 Virtual Machine

#6
It's always pleasant to see PHP occasionally get a positive moment in the limelight on HN. It's oft scorned yet powers a very large chunk of the web. With the work done on 7 it's also one of the fastest scripting languages around and deserves a little more credit if I'm honest.

Re: PHP 7 Virtual Machine

#8
post #7

I wonder if it's possible to compile it for iOS? I need a templating engine in my app, and php seems like the most popular one.

PHP is a whole lot more than just a templating engine. I think you would find that much more effort than is required just to make some templates.

Re: PHP 7 Virtual Machine

#9
Another one of nikic's seminal guides into the workings of PHP. It was him who wrote the foreach guide on StackOverflow http://stackoverflow.com/a/14854568/308851 .

Another note: if I ever catch you using these cute "finally ... interesting edge-cases" described in this article, your PR will be refused. Yes, yes, it's very smart, and you might win an obfuscation contest but in a professional environment we like code that can be understood even when the emergency phone kicks us out of bed. If it's five times as long, I care not, but if it requires me to think hard on the code, I do.

Re: PHP 7 Virtual Machine

#10
post #8
post #7

I wonder if it's possible to compile it for iOS? I need a templating engine in my app, and php seems like the most popular one.

PHP is a whole lot more than just a templating engine. I think you would find that much more effort than is required just to make some templates.

Perhaps you can send me down the righ path?

I want my users to be able to send emails from their iPads, and those emails would be generated based on templates. There will be many such templates built in, and eventually users will be able to hire web developer-type person to make custom templates.

My thinking was that PHP is the most popular language for that sort of thing, so it would be nice if could support that. My second choice is handlebars. I'm not sure if JSX would do the job?

Any thoughts appreciated.

Post reply on HN