diff options
author | Nikita Popov <nikita.ppv@gmail.com> | 2018-11-28 20:10:32 +0100 |
---|---|---|
committer | Nikita Popov <nikita.ppv@gmail.com> | 2018-11-28 20:10:32 +0100 |
commit | 745e250a219c3bf7852b8e449160afe362592666 (patch) | |
tree | 96db6cc859ef2b8eb449b11e4ddfc21210e6351c /ext | |
parent | 80e387cf6c0d64b3f253854161d8dc3438eda25b (diff) | |
parent | f4eec70260e31de100c3b679d7304425990af028 (diff) | |
download | php-git-745e250a219c3bf7852b8e449160afe362592666.tar.gz |
Merge branch 'PHP-7.3'
Diffstat (limited to 'ext')
-rw-r--r-- | ext/opcache/Optimizer/zend_cfg.c | 1 | ||||
-rw-r--r-- | ext/opcache/tests/bug77215.phpt | 22 |
2 files changed, 22 insertions, 1 deletions
diff --git a/ext/opcache/Optimizer/zend_cfg.c b/ext/opcache/Optimizer/zend_cfg.c index ef7df61c2d..759e5a4220 100644 --- a/ext/opcache/Optimizer/zend_cfg.c +++ b/ext/opcache/Optimizer/zend_cfg.c @@ -153,7 +153,6 @@ static void zend_mark_reachable_blocks(const zend_op_array *op_array, zend_cfg * changed = 1; zend_mark_reachable(op_array->opcodes, cfg, b); } else { - ZEND_ASSERT(b->start == live_range->end); b->flags |= ZEND_BB_UNREACHABLE_FREE; } } diff --git a/ext/opcache/tests/bug77215.phpt b/ext/opcache/tests/bug77215.phpt new file mode 100644 index 0000000000..b883c88a55 --- /dev/null +++ b/ext/opcache/tests/bug77215.phpt @@ -0,0 +1,22 @@ +--TEST-- +Bug #77215: CFG assertion failure on multiple finalizing switch frees in one block +--INI-- +opcache.enable_cli=1 +opcache.optimization_level=-1 +--FILE-- +<?php + +function _crash($eValeur) { + switch ($eValeur["a"]) { + default: + switch($eValeur["a"]) { + default: + return 2; + } + } +} + +var_dump(_crash(["a" => "b"])); +?> +--EXPECT-- +int(2) |