Ignore:
Timestamp:
2012-03-27T18:07:50+02:00 (3 years ago)
Author:
moo
Message:

more readability cache property. reduce memory footprint for data caching

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/processor/processor.m4

    r846 r851  
    431431#   ifdef ZEND_ENGINE_2_4
    432432    DISABLECHECK(`
    433     IFRESTORE(`dst->info.user.filename = processor->entry_src->filepath;', `PROC_STRING(info.user.filename)')
     433    IFRESTORE(`dst->info.user.filename = processor->entry_php_src->filepath;', `PROC_STRING(info.user.filename)')
    434434    PROCESS(zend_uint, info.user.line_start)
    435435    PROCESS(zend_uint, info.user.line_end)
     
    439439    DONE(info)
    440440#   else
    441     IFRESTORE(`dst->filename = processor->entry_src->filepath;DONE(filename)', `PROC_STRING(filename)')
     441    IFRESTORE(`dst->filename = processor->entry_php_src->filepath;DONE(filename)', `PROC_STRING(filename)')
    442442    PROCESS(zend_uint, line_start)
    443443    PROCESS(zend_uint, line_end)
     
    709709        gc_arg_info = 1;
    710710#endif
    711         dst->filename = processor->entry_src->filepath;
     711        dst->filename = processor->entry_php_src->filepath;
    712712#ifdef ZEND_ENGINE_2_4
    713713        if (src->literals /* || op_array_info->literalsinfo_cnt */) {
     
    886886#endif
    887887
    888     IFRESTORE(`dst->filename = processor->entry_src->filepath;DONE(filename)', `PROC_STRING(filename)')
     888    IFRESTORE(`dst->filename = processor->entry_php_src->filepath;DONE(filename)', `PROC_STRING(filename)')
    889889#ifdef IS_UNICODE
    890890    IFRESTORE(`
     
    914914#endif
    915915    } while (0);
    916     IFRESTORE(`xc_fix_op_array_info(processor->entry_src, processor->php_src, dst, shallow_copy, op_array_info TSRMLS_CC);')
     916    IFRESTORE(`xc_fix_op_array_info(processor->entry_php_src, processor->php_src, dst, shallow_copy, op_array_info TSRMLS_CC);')
    917917
    918918#ifdef ZEND_ENGINE_2
     
    10741074    PROCESS(zend_ulong, refcount)
    10751075
    1076     PROCESS(size_t, sourcesize)
     1076    PROCESS(size_t, file_size)
    10771077    PROCESS(zend_ulong, hits)
    10781078    PROCESS(size_t, size)
     
    11271127dnl }}}
    11281128DEF_STRUCT_P_FUNC(`xc_entry_t', , `dnl {{{
     1129    PROCESS(xc_hash_value_t, hvalue)
     1130    /* skip */
     1131    DONE(next)
     1132    COPY(cache)
    11291133    PROCESS(xc_entry_type_t, type)
    11301134    PROCESS(size_t, size)
    1131 
    1132     PROCESS(xc_hash_value_t, hvalue)
    1133     COPY(cache)
    1134     /* skip */
    1135     DONE(next)
    1136 
    1137     IFSTORE(`dst->refcount = 0; DONE(refcount)', `PROCESS(long, refcount)')
    11381135
    11391136    PROCESS(time_t, ctime)
     
    11761173
    11771174        case XC_TYPE_VAR:
    1178             STRUCT_P(xc_entry_data_var_t, data.var)
     1175            STRUCT(xc_entry_data_var_t, data.var)
    11791176            break;
    11801177
     
    11851182    DONE(data)
    11861183    dnl }}}
    1187     PROCESS(time_t, mtime)
     1184')
     1185dnl }}}
     1186DEF_STRUCT_P_FUNC(`xc_entry_php_t', , `dnl {{{
     1187    STRUCT(xc_entry_t, entry)
     1188
     1189    IFSTORE(`dst->refcount = 0; DONE(refcount)', `PROCESS(long, refcount)')
     1190    PROCESS(time_t, file_mtime)
    11881191#ifdef HAVE_INODE
    1189     PROCESS(int, device)
    1190     PROCESS(int, inode)
    1191 #endif
    1192 
    1193     if (src->type == XC_TYPE_PHP) {
     1192    PROCESS(int, file_device)
     1193    PROCESS(int, file_inode)
     1194#endif
     1195
     1196    if (src->entry.type == XC_TYPE_PHP) {
    11941197        PROCESS(int, filepath_len)
    11951198        IFRESTORE(`COPY(filepath)', `PROC_STRING_L(filepath, filepath_len)')
Note: See TracChangeset for help on using the changeset viewer.