Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:121067 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 57162 invoked from network); 15 Sep 2023 14:35:12 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 15 Sep 2023 14:35:12 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id AD624180089 for ; Fri, 15 Sep 2023 07:35:10 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00,SPF_HELO_PASS, SPF_NEUTRAL,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS30827 82.113.144.0/20 X-Spam-Virus: No X-Envelope-From: Received: from xdebug.org (xdebug.org [82.113.146.227]) by php-smtp4.php.net (Postfix) with ESMTP for ; Fri, 15 Sep 2023 07:35:10 -0700 (PDT) Received: from localhost (localhost [IPv6:::1]) by xdebug.org (Postfix) with ESMTPS id 48A5A10C3CF; Fri, 15 Sep 2023 15:35:09 +0100 (BST) Date: Fri, 15 Sep 2023 15:35:09 +0100 (BST) To: Dmitry Stogov cc: PHP Internals In-Reply-To: Message-ID: <8b9a1aae-5aec-91a8-5377-27f6f53581cd@php.net> References: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Subject: Re: [PHP-DEV] A new JIT engine for PHP-8.4/9 From: derick@php.net (Derick Rethans) Hi Dmitry, On Fri, 15 Sep 2023, Dmitry Stogov wrote: > After the code-review feedback, one of the most questionable decisions > was changed. > > Instead of including IR Framework as a git submodule, now its part is > embedded into php-src. > > This will complicate the IR/JIT development a bit, but will simplify > things for everyone else. > > I'm going to merge https://github.com/php/php-src/pull/12079 into > master next week. I think this is great work. It looks like the new JIT-IR approach is more suitable. I have however concerns with a few things here. This is a lot of new code, that very few other people understand in great detail. I think it is unwise if we have another large part of the engine that does not have enough people understanding enough of it, to be able to debug issues, and contribute to its continued development. As such, I don't think this should just be merged, without a comprehensive document explaining what it is, how it works, what pitfalls there are, etc. The natural process that we have for PHP would be to create an RFC. An RFC should also include a user-facing API on how to configure, and enable, the JIT and its optimisations, as our current implementation it is not the most convenient for users. I understand that working on an RFC for such a complex issue is going to take time, but that also gives to opportunity to pair with somebody, who, while writing it, will also learn how it works. That would also ready improve the debugging/contributing issues. Separately, I am not sure why your PR couldn't just replace the JIT that we already have? It would IMO not make sense to have two different ones at the same time. Furthermore, I am curious as if you have already done some benchmarks. I am curious to learn how well it makes non-benchmark code run faster. cheers, Derick -- https://derickrethans.nl | https://xdebug.org | https://dram.io Author of Xdebug. Like it? Consider supporting me: https://xdebug.org/support Host of PHP Internals News: https://phpinternals.news mastodon: @derickr@phpc.social @xdebug@phpc.social twitter: @derickr and @xdebug