Zend Optimizer is a free PHP optimization software opened by the PHP core engine "Zend" Creator Zend Technology Company. According to Zend, it is at least more than 30% of performance in some cases of this software! Such a good free dinner is of course used, now let's talk about how to configure this software.
The installation of Zend Opt is a fool, the installation wizard will automatically modify the php.ini according to your choice to help you start this engine. Let's introduce the configuration options for Zend Opt to help you maximize custom reasonable configuration. The following is the configuration file I use, I don't understand, don't worry, I will fully understand this article.
[ZEND] ZEND_OPTIMIZER.OPTIMIZATION_LEVEL = 1023ze_optimizer.encoder_loader = 0ze_extension_ts = "c: / program files / zend / lib / zendoptimizer.dll"
Now let's introduce the meaning of this configuration file: Zend_optimizer.Optimization_LEVEL "== Optimization, how many optimization processes are defined here. Zend_optimizer.Encoder_Loader == Whether it is allowed to process the PHP file encrypted by Zend Encoder. Zend_extension_ts "== The directory where the optimizer is located.
Optimization process Zend_optimizer.optimization_LEVEL explanation
The most important part of this here, look carefully! Zend Opt has a total of 10 optimization processes, the better the more performance that is theoretically. Of course, there is a gap between theory and reality. The more the optimization process is turned on, the greater the performance consumption, and the 10 optimization processes of Zend Opt is not the same, that is, the effect is not average. The highest value (high mode) defined by Zend is 15, here 15 refers to the Open 1-4 optimization process. Of course, many friends are not satisfied, after all, the highest opens only half of the optimization process even half of the total number. The corresponding digital code (value) of each optimization process is as follows:
Do not use 0 <= If this is not as good, save point memory! Optimization Process 1 (Pass1) 1 Optimization Process 2 (Pass2) 2 Optimization Process 3 (Pass3) Optimization Process 4 (PASS4) 8 Optimization Process 6 (PASS6) 32 Optimization Process 7 (PASS7) 64 Optimization Process 8 (Pass8) 128 Optimization Process 9 (Pass9) 256 Optimization Process 10 (Pass10) 512
What is the way to turn on an optimization process is controlled by these digital code (value) and as the parameter value of this parameter. As in my profile, Zend_Optimizer.Optimization_Level = 1023, the 1023 here is an optimization process 1 to the optimization process 10 all digital code (value) added and indicates that all 10 optimization processes are turned on. The HIGH mode value defined by Zend Company mentioned is 15, 15 indicates that the optimization process is simultaneously turned on.
Encryption code support Zend_Optimizer.Encoder_Loader explanation
For this parameter, I think most of the friends who have never seen Zend Opt FAQ documents don't know. This parameter is used to tell Zend Opt to support code encrypted by Zend Encoder. By default, Zend Opt will support the encrypted code. If you don't use the encrypted code, I recommend you to close this option. This feature involves the process of unpacking the inverse code, which causes the system load to increase the weight. My friend has developed the corresponding anti-compilation tool, which is expected to be launched after the Spring Festival.
This parameter is only two 0 off, 1 is turned on. Default is 1, the recommended is set to 0.
Module Location Zend_extension_TS No need to explain this is the easiest place, the parameter is the installation path of the Zend Opt module on the hard disk.