9 Replies - 4935 Views - Last Post: 22 December 2015 - 01:46 PM

#1 ArtificialSoldier  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 1842
  • View blog
  • Posts: 5,793
  • Joined: 15-January 14

PHP 7 Is Available

Post icon  Posted 03 December 2015 - 03:34 PM

From their email:
 

Quote

Today, were pleased to announce that PHP 7.0 - the fastest and most efficient PHP ever - is officially released!

PHP 7.0 brings you unprecedented levels of real-world performance and throughput by utilizing the new and advanced Zend Engine 3.0, designed and refactored for speed and reduced memory consumption. This translates to real-world benefits: greatly decreased response times, superior user experiences, and the ability to serve more users with fewer servers to maximize the power of your PHP 7.0 deployment.

The explosive performance improvements of PHP 7.0 range between 50% and 200% on real-world apps - without changing a single line of code.

PHP 7.0 also uses much less memory thanks to the compact data structures and the highly-refactored codebase of Zend Engine 3.0. Memory consumption gains between 30% and 50% are commonly realized, allowing you to serve more concurrent users without adding additional server hardware.

If light-speed PHP isnt enough, youll be happy to know that PHP 7.0 comes with many new features, including Return Type Declarations, Scalar Type Hints, Anonymous Classes, and even a SpaceShip Operator. Check out our PHP 7 Resources page. Further details are available here.


For those who don't know, with the release of PHP 7 the old mysql extension is no longer supported, which is why we tell people posting code that uses that extension that they need to update their code. Alternatives include the mysqli extension and PDO.

Is This A Good Question/Topic? 3
  • +

Replies To: PHP 7 Is Available

#2 astonecipher  Icon User is offline

  • Too busy for this
  • member icon

Reputation: 2343
  • View blog
  • Posts: 9,400
  • Joined: 03-December 12

Re: PHP 7 Is Available

Posted 03 December 2015 - 08:01 PM

Got the email today as well. Wondering how long it will take public servers to start offering it.
Was This Post Helpful? 0
  • +
  • -

#3 Slice  Icon User is offline

  • sudo pacman -S moneyz


Reputation: 253
  • View blog
  • Posts: 761
  • Joined: 24-November 08

Re: PHP 7 Is Available

Posted 04 December 2015 - 06:26 AM

I've been looking forward to this release for a while. The benchmark tests definitley look interesting.

Zend posted this infograph with requests per second on popular php applications.

Original page here

Posted Image
Was This Post Helpful? 0
  • +
  • -

#4 O'Niel  Icon User is offline

  • D.I.C Regular

Reputation: 14
  • View blog
  • Posts: 389
  • Joined: 13-September 15

Re: PHP 7 Is Available

Posted 04 December 2015 - 12:08 PM

Waaaw!
I've looked to the new features and it's actually very impressive.
Also that it's said to be more as 50% as fast then PHP 5.6.

Yet, I'd like to see a benchmark of PHP 7 vs ASP.NET on performance.

The only thing I find confusing, is that they have improved the security by removing outdated functions, yet people say that PHP 7 is even more insecure because it had one (yeah, one) CVE report.

This post has been edited by O'Niel: 04 December 2015 - 12:18 PM

Was This Post Helpful? 0
  • +
  • -

#5 CTphpnwb  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 3717
  • View blog
  • Posts: 13,493
  • Joined: 08-August 08

Re: PHP 7 Is Available

Posted 04 December 2015 - 01:05 PM

View PostO, on 04 December 2015 - 02:08 PM, said:

The only thing I find confusing, is that they have improved the security by removing outdated functions, yet people say that PHP 7 is even more insecure because it had one (yeah, one) CVE report.

Are you referring to this? It seems to me they're using old code that likely will not run on PHP 7 to disparage the new version.
Was This Post Helpful? 0
  • +
  • -

#6 ArtificialSoldier  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 1842
  • View blog
  • Posts: 5,793
  • Joined: 15-January 14

Re: PHP 7 Is Available

Posted 07 December 2015 - 11:08 AM

Quote

Also that it's said to be more as 50% as fast then PHP 5.6.

What's even more impressive is that the entire 5.x line was a series of performance improvements. Since there are still a lot of old servers out there running, I'd also like to see benchmarks for PHP 5.3 versus 7. I wouldn't be surprised if there are applications that are 2x or 3x faster in PHP 7.

Quote

So my question is that in the coming year more people are going towards the real time applications and tools like NODE.js so is it better to go with Node.js or be with PHP 7.

If you're setting up your own server then I would definitely take a long look at PHP 7. It may be a while before we can upgrade all of our servers but it's definitely on the list.
Was This Post Helpful? 0
  • +
  • -

#7 [email protected]  Icon User is offline

  • 僕は馬鹿ですね?
  • member icon

Reputation: 36
  • View blog
  • Posts: 1,018
  • Joined: 20-February 09

Re: PHP 7 Is Available

Posted 09 December 2015 - 08:59 PM

What got me is they mentioned finally adding an Abstract Syntax Tree to the new Zend Engine, but other than that from what I can see, this is a massive improvement over PHP 5, (RIP 6). I wonder how fast migration will take place, I didn't notice anything that was used often to be deprecated or have a behaviour change, so upgrading can't be -that- much of an ordeal.
Was This Post Helpful? 0
  • +
  • -

#8 ArtificialSoldier  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 1842
  • View blog
  • Posts: 5,793
  • Joined: 15-January 14

Re: PHP 7 Is Available

Posted 10 December 2015 - 10:00 AM

The lack of support for the mysql extension will cause several hosts to delay, or offer both 5.x and 7 until most of the major projects drop their dependencies on the mysql extension. The list of backwards-incompatible changes is here:

http://php.net/manua...ncompatible.php

The one about global only accepting simple variables may be an issue, but I'm only saying that because I once used variable variables with global a while ago. The one about new objects not being allowed to be assigned by reference will affect libraries that support PHP 4, I see a lot of that in older Pear libraries.
Was This Post Helpful? 0
  • +
  • -

#9 CTphpnwb  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 3717
  • View blog
  • Posts: 13,493
  • Joined: 08-August 08

Re: PHP 7 Is Available

Posted 14 December 2015 - 05:36 AM

View Post[email protected], on 09 December 2015 - 10:59 PM, said:

I didn't notice anything that was used often to be deprecated or have a behaviour change, so upgrading can't be -that- much of an ordeal.

Just noticed this. I think that the old MySQL functions are used far more than they should be, and many seem intent on sticking with them, despite the security nightmare they cause. Those people won't want to upgrade.
Was This Post Helpful? 0
  • +
  • -

#10 Slice  Icon User is offline

  • sudo pacman -S moneyz


Reputation: 253
  • View blog
  • Posts: 761
  • Joined: 24-November 08

Re: PHP 7 Is Available

Posted 22 December 2015 - 01:46 PM

View Post[email protected], on 10 December 2015 - 03:59 AM, said:

I wonder how fast migration will take place, I didn't notice anything that was used often to be deprecated or have a behaviour change, so upgrading can't be -that- much of an ordeal.


My office set up a test server today with php 7 and nginx to see if we could notice any speed improvements on our current projects.

All 3 projects worked without changes, straight from the git clone. The only issue we had was a plugin (mpdf) which used two default cases in a switch statement.

Even with a connection to a remote mysql server, the performance difference on our biggest project was very notable in terms of page load times. That one was written in Zend Framework 2. A smaller project which uses the Laravel 5 framework didn't see much of an improvement - however it also ran very quickly on php 5.6

This post has been edited by Slice: 22 December 2015 - 01:47 PM

Was This Post Helpful? 0
  • +
  • -

Page 1 of 1