Troubleshooting PHP7 prompts for missing VCRUNTIME140.DLL under Windows

Source: Internet
Author: User
Tags php website

The day before yesterday PHP7.0.0 official version released, there are some better improvements, the official said speed than php5.6 twice times faster, performance has a great improvement, and also released from php5.x to PHP7 migration problem, so in the future after the migration of PHP website can greatly improve the performance of the website, so for the early adopters I also go to the PHP official website to download 7.0 version, through the command line for independent testing, download the ZIP package extracted, downloaded into the directory, the php.ini-development changed to php.ini the rest of the parameters are not modified, and then in the current directory to create a new test.php, enter a simple code:

1 <? PHP 2 Echo "Hello php7!" ; 3 ?>

Then run cmd into the directory, execute PHP test.php results popup prompt: Cannot start this program because the computer is missing VCRUNTIME140.dll. Try reinstalling the program to resolve this issue.

Originally running PHP7 under Windows requires Visual C++redistributable 2015 and previous versions do not need to be that high, the latest version of Apache may also need this component, which is created by running Visual Studio 2015 c+ + The necessary components of the application, install once can solve the environmental problems, then go to the Microsoft Official website to download the installation program, install it again. There are 64-bit and 32-bit editions, according to the computer configuration to download, the following is the download link:

64-bit version: http://download.microsoft.com/download/9/E/1/9E1FA77A-9E95-4F3D-8BE1-4D2D0C947BA2/enu_INREL/ Vcredistd14x64/vc_redist.x64.exe

32-bit version: http://download.microsoft.com/download/9/E/1/9E1FA77A-9E95-4F3D-8BE1-4D2D0C947BA2/enu_INREL/ Vcredistd14x86/vc_redist.x86.exe

After the download run, according to the prompt installation, after the installation is effective immediately, run again test.php is normal,

  

Also, simply test the speed of the PHP7, take a look at the gap with php5.6, build a simple time_test.php, perform 1 million random and floating-point operations, and look at the approximate time:

1<?PHP2 $time 1=Microtime();3  for($i= 0;$i<= 1000000;$i++) {4     $j= (Rand(1,1000) +$i)/1.53 +$i;5 }6 $time 2=Microtime();7 Echo $time 2-$time 1;8?>

Results of running with PHP7:

  

The result of php5.6 is basically 0.14-0.18ms and then accessed through the browser:

  

Basically is stable in 0.25-0.27ms this area, so PHP7 is roughly 1.6 times times faster than php5.6, of course, this test is very humble, and too unprofessional, but at least can prove that PHP7 performance relative to the php5.6 has a great upgrade, quickly experience it!

Troubleshooting PHP7 prompts for missing VCRUNTIME140.DLL under Windows

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.