zoukankan      html  css  js  c++  java
  • PHP版本VC6和VC9、Non Thread Safe和Thread Safe的区别

    链接:http://www.cnblogs.com/neve/articles/1863853.html

    想更新个PHP的版本,PHP的windows版本已经分离出来了,见http://windows.php.net/download/,但是上面有很多不同的版本,包括VC9, VC6,  x86 Non Thread Safe, x86 Thread Safe, 好像没有x64版本的,(现在特别喜欢用64位的软件),版本有点多,主要的区别和如何选择不同的版本如下:

    If you are using PHP with Apache 1 or Apache2 from apache.org you need to use the VC6 versions of PHP

    If you are using PHP with IIS you should use the VC9 versions of PHP

    VC6 Versions are compiled with the legacy Visual Studio 6 compiler

    VC9 Versions are compiled with the Visual Studio 2008 compiler and have improvements in performance and stability. The VC9 versions require you to have the Microsoft 2008 C++ Runtime (x86) or the Microsoft 2008 C++ Runtime (x64) installed

    Do NOT use VC9 version with apache.org binaries

    VC6 版本是使用 Visual Studio 6 编译器编译的,如果你是在windows下使用Apache+PHP的,请选择VC6版本。

    VC9 版本是使用 Visual Studio 2008 编译器编译的,如果你是在windows下使用IIS+PHP的,请选择VC9版本。

    Non Thread Safe就是非线程安全,在执行时不进行线程(Thread)安全检查;
    Non Thread Safe 是线程安全,执行时会进行线程(Thread)安全检查,以防止有新要求就启动新线程的 CGI 执行方式而耗尽系统资源;

    Windows下的PHP 主要有两种执行方式:ISAPI 和 FastCGI。

          ISAPI 执行方式是以 DLL 动态库的形式使用,可以在被用户请求后执行,在处理完一个用户请求后不会马上消失,所以需要进行线程安全检查,这样来提高程序的执行效率,所以如果是以 ISAPI 来执行 PHP,建议选择 Thread Safe 版本;

          FastCGI 执行方式是以单一线程来执行操作,所以不需要进行线程的安全检查,除去线程安全检查的防护反而可以提高执行效率,所以,如果是以 FastCGI 来执行 PHP,建议选择 Non Thread Safe 版本。

          官方并不建议你将Non Thread Safe 应用于生产环境。

    下载地址:http://windows.php.net/download

  • 相关阅读:
    MySQL Explain优化
    mysql联合索引
    MySQL索引类型
    php常用的排序算法与二分法查找
    mysql 主从复制(mysql双机热备的实现)
    mysql 主从复制 (2)
    Linux 查看进程之PS命令
    PHP isset 和 array_key_exists 对比
    Linux md5sum 的用法
    Linux Sphinx 安装与使用
  • 原文地址:https://www.cnblogs.com/xcsn/p/3394039.html
Copyright © 2011-2022 走看看