Skip to content

[JIT] Community Symfony HttpFoundation failure #21264

@iluuu1994

Description

@iluuu1994

Description

The following code:

--TEST--
Missing reference unwrap for FE_FETCH_R in JIT
--INI--
opcache.enable=1
opcache.enable_cli=1
opcache.jit=function
--FILE--
<?php

class C {
    public array $array;

    public static function identity($x) {
        return $x;
    }

    public function test() {
        array_map(self::identity(...), $this->array);
    }
}

function test() {
    $c = new C;
    $element = 'qux';
    $c->array = [&$element, &$element];
    var_dump($c->test());
}

test();
test();

?>
--EXPECT--

Resulted in this output:

php: /home/ilutov/Developer/php-src/Zend/zend_execute.c:256: _get_zval_ptr_tmp: Assertion `zval_get_type(&(*(ret))) != 10' failed.

Termsig=6

But I expected this output instead:

zend_jit_fe_fetch() is likely missing the changes from GH-20628.

For context: https://github.com/php/php-src/actions/runs/22207820708/job/64235745034

PHP Version

master

Operating System

No response

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions