Lines Matching refs:cfg

143 static int get_const_switch_target(zend_cfg *cfg, zend_op_array *op_array, zend_basic_block *block,…  in get_const_switch_target()  argument
161 return cfg->map[ZEND_OFFSET_TO_OPLINE_NUM(op_array, opline, Z_LVAL_P(zv))]; in get_const_switch_target()
164 …asic_block *block, zend_op_array *op_array, zend_bitset used_ext, zend_cfg *cfg, zend_op **Tsource) in zend_optimize_block() argument
428 int target = get_const_switch_target(cfg, op_array, block, opline, &ZEND_OP1_LITERAL(opline)); in zend_optimize_block()
876 static void assemble_code_blocks(zend_cfg *cfg, zend_op_array *op_array) in assemble_code_blocks() argument
878 zend_basic_block *blocks = cfg->blocks; in assemble_code_blocks()
879 zend_basic_block *end = blocks + cfg->blocks_count; in assemble_code_blocks()
1000 if (blocks[cfg->map[op_array->try_catch_array[i].try_op]].flags & ZEND_BB_REACHABLE) { in assemble_code_blocks()
1002 … op_array->try_catch_array[j].try_op = blocks[cfg->map[op_array->try_catch_array[i].try_op]].start; in assemble_code_blocks()
1004 …op_array->try_catch_array[j].catch_op = blocks[cfg->map[op_array->try_catch_array[i].catch_op]].st… in assemble_code_blocks()
1009 …op_array->try_catch_array[j].finally_op = blocks[cfg->map[op_array->try_catch_array[i].finally_op]… in assemble_code_blocks()
1016 …op_array->try_catch_array[j].finally_end = blocks[cfg->map[op_array->try_catch_array[i].finally_en… in assemble_code_blocks()
1057 if (!(blocks[cfg->map[op_array->live_range[i].start]].flags & ZEND_BB_REACHABLE)) { in assemble_code_blocks()
1058 ZEND_ASSERT(!(blocks[cfg->map[op_array->live_range[i].end]].flags & ZEND_BB_REACHABLE)); in assemble_code_blocks()
1060 uint32_t start_op = blocks[cfg->map[op_array->live_range[i].start]].start; in assemble_code_blocks()
1061 uint32_t end_op = blocks[cfg->map[op_array->live_range[i].end]].start; in assemble_code_blocks()
1115 memset(cfg->map, -1, sizeof(int) * op_array->last); in assemble_code_blocks()
1116 for (n = 0; n < cfg->blocks_count; n++) { in assemble_code_blocks()
1117 if (cfg->blocks[n].flags & ZEND_BB_REACHABLE) { in assemble_code_blocks()
1118 cfg->map[cfg->blocks[n].start] = n; in assemble_code_blocks()
1123 static void zend_jmp_optimization(zend_basic_block *block, zend_op_array *op_array, zend_cfg *cfg, … in zend_jmp_optimization() argument
1126 zend_basic_block *blocks = cfg->blocks; in zend_jmp_optimization()
1141 while (next < cfg->blocks_count && !(blocks[next].flags & ZEND_BB_REACHABLE)) { in zend_jmp_optimization()
1500 while (next < cfg->blocks_count && !(blocks[next].flags & ZEND_BB_REACHABLE)) { in zend_jmp_optimization()
1599 static void zend_t_usage(zend_cfg *cfg, zend_op_array *op_array, zend_bitset used_ext, zend_optimiz… in zend_t_usage() argument
1621 for (n = 1; n < cfg->blocks_count; n++) { in zend_t_usage()
1622 block = cfg->blocks + n; in zend_t_usage()
1701 for (n = cfg->blocks_count; n > 0;) { in zend_t_usage()
1702 block = cfg->blocks + (--n); in zend_t_usage()
1822 static void zend_merge_blocks(zend_op_array *op_array, zend_cfg *cfg) in zend_merge_blocks() argument
1828 for (i = 0; i < cfg->blocks_count; i++) { in zend_merge_blocks()
1829 b = cfg->blocks + i; in zend_merge_blocks()
1883 zend_cfg cfg; in zend_optimize_cfg() local
1894 if (zend_build_cfg(&ctx->arena, op_array, ZEND_CFG_SPLIT_AT_LIVE_RANGES, &cfg, NULL) != SUCCESS) { in zend_optimize_cfg()
1899 if (cfg.blocks_count * (op_array->last_var + op_array->T) > 64 * 1024 * 1024) { in zend_optimize_cfg()
1905 zend_dump_op_array(op_array, ZEND_DUMP_CFG, "before block pass", &cfg); in zend_optimize_cfg()
1919 blocks = cfg.blocks; in zend_optimize_cfg()
1920 end = blocks + cfg.blocks_count; in zend_optimize_cfg()
1924 zend_t_usage(&cfg, op_array, usage, ctx); in zend_optimize_cfg()
1937 zend_optimize_block(b, op_array, usage, &cfg, Tsource); in zend_optimize_cfg()
1950 zend_jmp_optimization(b, op_array, &cfg, same_t); in zend_optimize_cfg()
1955 zend_cfg_remark_reachable_blocks(op_array, &cfg); in zend_optimize_cfg()
1958 zend_merge_blocks(op_array, &cfg); in zend_optimize_cfg()
1962 zend_t_usage(&cfg, op_array, usage, ctx); in zend_optimize_cfg()
1963 assemble_code_blocks(&cfg, op_array); in zend_optimize_cfg()
1966 …zend_dump_op_array(op_array, ZEND_DUMP_CFG | ZEND_DUMP_HIDE_UNREACHABLE, "after block pass", &cfg); in zend_optimize_cfg()