Changeset 1535 in svn


Ignore:
Timestamp:
2014-09-12T05:09:58Z (3 years ago)
Author:
Xuefer
Message:

MFT: closes #337: adds warning about Zend OPcache optimization level incompatiblity

Location:
branches/3.2
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/3.2

  • branches/3.2/ChangeLog

    r1515 r1535  
    55   * PHP_5_6 support
    66   * fixed #333: reduce memory usage for small or empty files
     7   * closes #337: adds warning about Zend OPcache optimization level incompatiblity
    78
    893.1.1 2014-09-02
  • branches/3.2/NEWS

    r1515 r1535  
    33 * PHP_5_6 support
    44 * reduce memory usage for small or empty files
     5 * aware of Zend OPcache
    56
    673.1.1 2014-09-02
  • branches/3.2/mod_cacher/xc_cacher.c

    r1483 r1535  
    36943694    ext = zend_get_extension("Zend Optimizer");
    36953695    if (ext) {
    3696         /* zend_optimizer.optimization_level>0 is not compatible with other cacher, disabling */
     3696        char *value;
     3697        if (cfg_get_string("zend_optimizer.optimization_level", &value) == SUCCESS && zend_atol(value, strlen(value)) > 0) {
     3698            zend_error(E_NOTICE, "Zend Optimizer with zend_optimizer.optimization_level>0 is not compatible with other cacher, disabling");
     3699        }
    36973700        ext->op_array_handler = NULL;
    36983701    }
     3702
     3703    ext = zend_get_extension("Zend OPcache");
     3704    if (ext) {
     3705        char *value;
     3706        if (cfg_get_string("opcache.optimization_level", &value) == SUCCESS && zend_atol(value, strlen(value)) > 0) {
     3707            zend_error(E_WARNING, "Constant folding feature in Zend OPcache is not compatible with XCache's __DIR__ handling, please set opcache.optimization_level=0 or disable Zend OPcache");
     3708        }
     3709    }
     3710
    36993711    /* cache if there's an op_array_ctor */
    37003712    for (ext = zend_llist_get_first_ex(&zend_extensions, &lpos);
Note: See TracChangeset for help on using the changeset viewer.