Home >Backend Development >PHP Tutorial >The difference between VC9, VC6, Thread Safe and Non Thread Safe in PHP5.3_PHP Tutorial

The difference between VC9, VC6, Thread Safe and Non Thread Safe in PHP5.3_PHP Tutorial

WBOY
WBOYOriginal
2016-07-20 11:14:59991browse

PHP provides a total of four versions, VC9 x86 Non Thread Safe, VC9 x86 Thread Safe, VC6 x86 Non Thread Safe, VC6 x86 Thread Safe. This gives me a headache as a novice. Fortunately, PHP official website provides downloads There is an English word "choose" on the left side of the place. I understood it. I guessed that it meant how to choose the version, so I started to look it up in the dictionary and on the Internet. I finally understood the specific meaning and used it as a memo.

The VC6 version is compiled using the Visual Studio 6 compiler. If your PHP is built using Apache, then you should choose the VC6 version.

The VC9 version is compiled using the Visual Studio 2008 compiler. If your PHP is set up using IIS, then you should choose the VC9 version.

First understand the literal meaning, Thread Safe is thread safety, and thread (Thread) safety checks will be performed during execution to prevent CGI execution from starting new threads when there are new requirements and exhausting system resources. Non Thread Safe is non-thread safe and does not perform thread (Thread) safety checks during execution.

Let’s look at the two execution methods of PHP: ISAPI and FastCGI.

The ISAPI execution method is used in the form of a DLL dynamic library, which can be executed after being requested by the user. It will not disappear immediately after processing a user request, so a thread safety check is required to improve the execution efficiency of the program. So if you are using ISAPI to execute PHP, it is recommended to choose the Thread Safe version;

FastCGI execution method uses a single thread to perform operations, so there is no need to perform thread safety checks. Removing the protection of thread safety checks can improve execution efficiency, so if FastCGI is used (whether paired with IIS 6 or IIS 7) To execute PHP, it is recommended to download and execute non-thread safe PHP (PHP binary files have two packaging methods: msi and zip, please download the zip package).

The thread safety check is prepared for ISAPI PHP. Because many PHP modules are not thread safe, you need to use Thread Safe PHP.

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/440236.htmlTechArticlePHP provides a total of four versions, VC9 x86 Non Thread Safe, VC9 x86 Thread Safe, VC6 x86 Non Thread Safe , VC6 x86 Thread Safe, this gives me a headache as a novice. Fortunately, the PHP official website provides...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn