1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

PHP 7: The Next Major Version of PHP

Discussion in 'General Chat' started by hassanahmad1, Sep 5, 2014.

?

Will PHP be ultimately killed by HACK?

  1. Yes.

    0 vote(s)
    0.0%
  2. Not a chance.

    0 vote(s)
    0.0%
  3. Maybe. Time will tell.

    100.0%
  1. #1
    The exact feature-set of version 7 of PHP is not entirely known currently. There are some features that we can talk about since they are being implemented in PHP 7. The rest we can only speculate based on reasonable guesses. Here is an outline of some of its new features:

    1. PHPNG to Become Basis for PHP 7
    PHPNG is an improved PHP codebase which increases the performance gains anywhere between 20% and 110% in real world applications such as Wordpress, Drupal or SugarCRM. It also significantly reduces memory consumption.

    The goal now is to officially accept the new codebase as the basis for the next major version of PHP. Once that happens, we will generally stop referring to phpng as phpng, and will start referring to it only as PHP 7. This upgrade will bring a huge performance improvement to PHP.

    2. JIT Engine
    According to Dmitry Stogov of Zend, the motivation of starting the development of PHPNG was to research the implementation of a JIT engine for the Zend Engine based PHP. Such an engine can dynamically compile Zend opcodes into native machine code with the result that the code will run faster the next time it is run.

    It is certainly likely that a JIT engine will be brought to PHP 7, as according to Zeev Suraski it can "push performance through the roof for an already ultra fast implementation".

    3. AST: Abstract Syntax Tree
    Recently, Nikita Popov proposed the introduction of an Abstract Syntax Tree (AST) as an intermediary structure in PHP compilation process.

    As described in his proposals, the two primary advantages of using AST are:
    1. More maintainable parser and compiler and better code quality
    2. No more syntactical decisions due to technical restrictions
    Nikita already provided a patch to implement AST support on top of the PHPNG branch.

    4. Asynchronous Programming
    Facebook Hack provides a very elegant support for asynchronous programming. PHP core developers are also moving fast towards making asynchronous programming available in PHP sooner rather than later.

    Recently, Julien Pauli, one of the developers of the latest PHP releases, has been commenting about refactoring PHP I/O multiplexing layer.

    This feature would allow future versions of PHP to easily implement support to the execution of parallel tasks within the same request, which will result in pushing performance improvement potential of PHP to the next level. Of course, we won’t get performance improvements automatically just by enabling the support for asynchronous programming. New PHP code needs to be written to take advantage of its potential.

    However, despite the initial effort of Jean Pauli, it is not necessary that asynchronous programming built-in support will be enabled in PHP 7.

    5. Standalone Multi-threading Web Server
    This feature might not make in PHP 7 version, but it is something that would make PHP more scalable. This feature is already present in HHVM which can be run as a standalone multi-threading Web server. This allows Facebook to reduce the numbers of server machines needed to handle the high traffic load.

    Multi-threaded Web servers like ngynx, lighttpd or even Apache in worker mode can be be used to run PHP, however that is not the same as having PHP run on its own multi-threading Web server.

    A multi-threading Web server can handle many simultaneous requests using a single memory pool. It would also allow PHP use a single pool of database connections, thus minimizing the number of simultaneous database connections opened during access peaks.

    When will PHP 7 be released?
    It is too early to predict the release date of PHP 7. Some people say that it will take around 1 to 3 years. A reasonable guess is to expect a final PHP 7 release some time in 2016, although it is possible that we see an early alpha version before that.

    So in conclusion, we will have to wait for at least one year before we can start learning about it.

    Source: http://memoirsofacoder.blogspot.com/2014/08/php-7-what-to-expect-features-and.html
     
    hassanahmad1, Sep 5, 2014 IP