Tracing JIT: Assertion in _get_zval_ptr_tmp: TMP holds a reference after by-ref named-argument call (incomplete fix of GH-21972)

未关闭
#25,359 0 条评论 0 个 reaction 已指派 1 人 在 GitHub 查看

维护者通常 1 天内回复

@devnexen 已经在做这个了。

开始于 2026年11月10日。

  • #25377 来自 @devnexen —— 未关闭

评估

这个 Issue 还没有评估数据。

描述

Bug Extension: opcache Status: Verified
Description

The following code:

<?php
namespace test;
try { throw new \Exception; } catch (\Exception $e) {}
function f(&$a = null, &$b = null) {}
function g($s) {
	f(b: $s);
	return $s;
}
g("x");
var_dump(strtolower(g("FALSE")));

Resulted in this output:

php: Zend/zend_execute.c:275: zval *_get_zval_ptr_tmp(uint32_t, zend_execute_data *): Assertion `zval_get_type(&(*(ret))) != 10' failed.
Aborted (core dumped)

To reproduce: ./sapi/cli/php -d opcache.enable_cli=1 -d opcache.jit=tracing -d opcache.jit_hot_func=1 test.php

Commit:

19d3b9303017d02501f0fe59ba4438b25ee28477

Configurations:

CC="clang-12" CXX="clang++-12" CFLAGS="-DZEND_VERIFY_TYPE_INFERENCE" CXXFLAGS="-DZEND_VERIFY_TYPE_INFERENCE" ./configure --enable-debug --enable-address-sanitizer --enable-undefined-sanitizer --enable-re2c-cgoto --enable-zts --enable-bcmath --enable-calendar --enable-dba --enable-dl-test --enable-exif --enable-ftp --enable-gd --enable-gd-jis-conv --enable-mbstring --enable-pcntl --enable-shmop --enable-soap --enable-sockets --enable-sysvmsg --enable-zend-test --with-zlib --with-bz2 --with-curl --with-enchant --with-gettext --with-gmp --with-mhash --with-ldap --with-libedit --with-readline --with-snmp --with-sodium --with-xsl --with-zip --with-mysqli --with-pdo-mysql --with-pdo-pgsql --with-pgsql --with-sqlite3 --with-pdo-sqlite --with-webp --with-jpeg --with-freetype --enable-sigchild --with-pcre-jit --with-iconv

Operating System:

Ubuntu 20.04 Host, Docker 0599jiangyc/flowfusion:latest

This report is automatically generated by FlowFusion

PHP Version
nightly
Operating System

No response

主要语言
C
星标
41.8k
派生
8.5k
平均合并
2 天 13 小时
30 天内合并 PR
145

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

php/php-src 的其他 Issue

查看 php/php-src 的全部 Issue

相似的 Issue

更多 C Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。