-
Notifications
You must be signed in to change notification settings - Fork 7.9k
_ir_RSTORE: Assertion `ctx->control' failed #15101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Could you please reproduce this with |
These are the code locations mentioned in the trace. https://github.com/TRowbotham/PHPDOM/blob/dev/src/Parser/Collection/ObjectStack.php#L55 I hit this assertion when running I will also note that this code is using the new property hooks feature, so it may be related to that. Please let me know if I can provide any additional information. |
Thanks! <?php
class A {
function test($context, $token) {
if ($token instanceof DoctypeToken) {
$this->processDoctypeToken($context, $token);
}
}
private function processDoctypeToken(TreeBuilderContext $context, DoctypeToken $token): void
{
$publicId = $token->publicIdentifier;
$systemId = $token->systemIdentifier;
$name = $token->name;
if ($name !== 'html'
|| $publicId !== null
|| ($systemId !== null && $systemId !== 'about:legacy-compat')) {
}
$doctype = new DocumentType($context->document, $name ?? '', $publicId ?? '', $systemId ?? '');
}
}
class Document {
}
final class TreeBuilderContext {
public $document;
public function __construct() {
$this->document = new Document;
}
}
abstract class Node {
public const DOCUMENT_TYPE_NODE = 10;
protected function __construct(Document $document, int $nodeType)
{
}
}
class DocumentType extends Node {
public readonly string $name;
public readonly string $publicId;
public readonly string $systemId;
public function __construct(
Document $document,
string $name,
string $publicId = '',
string $systemId = '') {
parent::__construct($document, self::DOCUMENT_TYPE_NODE);
}
}
class DoctypeToken {
public $publicIdentifier;
public $name;
public $systemIdentifier;
}
$a = new A;
$doc = new TreeBuilderContext();
$t = new DoctypeToken();
$t->name = "html";
foreach ([$doc, $t] as $token) {
$a->test($doc, $token);
}
?> |
Description
I am hitting an assertion failure in the JIT using PHP 8.4.0alpha2 in a particular project. I have not yet been able to create a small reproducer, so hopefully the following stack trace is useful.
Relevant changed ini settings:
opcache.enable_cli=1
opcache.memory_consumption=256
opcache.max_accelerated_files=20000
opcache.jit=1255
opcache.jit_buffer_size=256M
PHP Version
PHP 8.4.0alpha2
Operating System
Ubuntu 22.04
The text was updated successfully, but these errors were encountered: