Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:110233 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 1475 invoked from network); 21 May 2020 16:08:41 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 21 May 2020 16:08:41 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id A0DA5180508 for ; Thu, 21 May 2020 07:47:31 -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=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS15169 209.85.128.0/17 X-Spam-Virus: No X-Envelope-From: Received: from mail-vs1-f46.google.com (mail-vs1-f46.google.com [209.85.217.46]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Thu, 21 May 2020 07:47:30 -0700 (PDT) Received: by mail-vs1-f46.google.com with SMTP id 1so4129299vsl.9 for ; Thu, 21 May 2020 07:47:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=qNMQZnupUIcTNzVzOFe0ajcALEM34wgmdNFA0rQl5lc=; b=cLMU8uVPQm9DSshdsBLzoluulbjWYNFNztFT98wafgTEItT9XV+dv1xcLIqpQDfvIW WTHVkG109L9wYMUp/qCKoTd1M2BfiV9c8GpOfSSYn11wTv83coSmXf5fYWckaNHUF1u1 0SvOsQkwSVBPHxa4sX3pZjC3rb1y6LmH/3lO+5wkyLLbk/mdxgxJ0fgXuZs0iQSDHuv/ Gw4xVvuEq1EXQ4U4EUGOQTmUonT2rZ/bcIjBa6pB5olPZaJrPryutjS/BjPXslwvVAvi QnfRopE0T7HtjVUtLI3kSjVmLDuyKRjk6U2JShufMCDgkzT3/TlhhM1gysyYRZNDkTRi w4xA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=qNMQZnupUIcTNzVzOFe0ajcALEM34wgmdNFA0rQl5lc=; b=jrO1IOXiMmG1u279iAFHAZLVDX1/6JWNTBZbKwxnRQ2SlnBtOSton27AcFvev1iEeU c0Y6tKGUEIOsTpSer7YrCDd41H10LDvFGT5SOiyxAgFS0AMtCy/+6Y4PaEDdQXXXfaDo R3HU1xc83JcNxn2BexYFbxqF+4rXH0IE2zPMExzFbPEi258QJAAVKvkq3EppTEd/WLVB uQVLWycLmfC/RNhMBiJ1clb2EPIDU2uzs015r5dk7Z39Jdi4VfpERZKVMcu9Xa/kn/wx FOj0qUOJjzWBGXkZVKUuF6lA7y3M/lma1s7N/75wCAIjZFxBRXeIwMQGYBgRDz/dV6zq oavQ== X-Gm-Message-State: AOAM5308A93ptTXduQQ5WJxfVLZ6UxQ/CDZyUzF0weANZvBRAXgy6nVk 1lH+OHGjLOHt18LlMQLamvcT5riL1wqUdOh2zL0= X-Google-Smtp-Source: ABdhPJwnTb1+uXtmHMIC7X5ZedhnWRPBx9dAZYo5cZHUQsOK8EjRT4wM/e2YauNml/Bk3EgAbhQ15NHJZ+D35R/+Gxc= X-Received: by 2002:a05:6102:d5:: with SMTP id u21mr7648146vsp.6.1590072448361; Thu, 21 May 2020 07:47:28 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Thu, 21 May 2020 16:46:51 +0200 Message-ID: To: tyson andre Cc: Derick Rethans , "internals@lists.php.net" Content-Type: multipart/alternative; boundary="00000000000073aa2105a6299707" Subject: Re: [PHP-DEV] [RFC] opcache.no_cache: Opcache optimization without any caching From: albertcasademont@gmail.com (Albert Casademont) --00000000000073aa2105a6299707 Content-Type: text/plain; charset="UTF-8" Hi tyson, Thanks for your RFC. As ReactPHP users this is a very welcome change. Right now we have to enable file_cache only for the optimizations, as there's no real benefit of the full opcache in long-running CLI apps. Having this setting would allow us to even stop using file_cache but get the opcache optimizations. It would be even better if these optimizations moved into PHP Core. Thank you! Albert On Thu, May 21, 2020 at 4:07 PM tyson andre wrote: > Hi internals, > > https://wiki.php.net/rfc/opcache.no_cache has been updated. > Instead of opcache.no_cache=1, opcache.enable_cache=0 is now used to > disable caching. > > In the RFC, I wrote that opcache_get_status() now includes the following > new booleans > > - `optimizations_enabled`, which is true if any optimization passes will > get run. > - `allow_cache`, which will be true if any form of opcode caching is > enabled. > Maybe `cache_opcodes` or `opcode_cache_enabled` would be a better name. > > Any thoughts on whether opcache_get_status() should be changed at all here? > It's probably possible but inconvenient to determine what's being done > with extension_loaded() and multiple calls to ini_get(), > and the intended meaning of existing flags such as `opcache_enabled` was > never documented > in https://www.php.net/opcache_get_status > > Any other thoughts on the RFC? > > > > In my opinion, configuration names should never be "in the negative". > > > Instead of defaulting to opcache.no_cache=0, default to > opcache.cache=1. > > > > ... the setting isn't actually enabling cache, it's allowing cache (i.e. > opposite of disabling), > > so making this "opcache.allow_cache" might be the best. I'll probably go > with that. > > (similar to allow_url_fopen, allow_url_include) > > > > ... `opcache.cache` could be confused with the caching strategy or the > path to the cache, > > or being sufficient on its own to enable caching > > Thanks, > - Tyson > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > --00000000000073aa2105a6299707--