Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:88207 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 13092 invoked from network); 15 Sep 2015 08:24:32 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 15 Sep 2015 08:24:32 -0000 Authentication-Results: pb1.pair.com header.from=rasmus@lerdorf.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=rasmus@lerdorf.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain lerdorf.com designates 209.85.220.45 as permitted sender) X-PHP-List-Original-Sender: rasmus@lerdorf.com X-Host-Fingerprint: 209.85.220.45 mail-pa0-f45.google.com Received: from [209.85.220.45] ([209.85.220.45:32799] helo=mail-pa0-f45.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 96/42-28087-FB5D7F55 for ; Tue, 15 Sep 2015 04:24:32 -0400 Received: by pacex6 with SMTP id ex6so170485249pac.0 for ; Tue, 15 Sep 2015 01:24:28 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:cc:from:message-id:date :user-agent:mime-version:in-reply-to:content-type; bh=+VBDI8ZCIdci8oFjYz6TBEGunOktu0wp0KhPELl8EY8=; b=gGChDDj8Bp/ks/Gh3qTcpPGJzOVNgWvxD9MgsU253WW8OHKYCMe9Tyz/CIDF01u8K3 5vQQQLDqAdDrGr1ZABh1EUTcnD4BxxzZYq14uRaaN2PrqH1kblHDkPwO+yHmlvp/ccyl 7AwG7OAm1qK8W3Df8PKwz3ZPd+LV6p/O8irDOG5zFqv7rEXSb+I9VO3cdzPXJ7alsSIS tagNZod1Vl4suu/DKT/OpbbVV3ooUb7QyRijkvuEXKUMMZnqvyBlsYv2kzUR/zTGKqL/ NXhHithQAn5vJz8S4eiJfQ5CwNdt7bqxJGT7PoDUHqj+8sQTT0azd6CkUSD/tSusDIz0 J5hg== X-Gm-Message-State: ALoCoQlyNPwSaop4wUUHW+HO0Smz3hnF0m2cpUSx4+sAjBHEilMgVxuipkQbN8yq2BI8hlgYcY8A X-Received: by 10.68.194.73 with SMTP id hu9mr45818342pbc.146.1442305468256; Tue, 15 Sep 2015 01:24:28 -0700 (PDT) Received: from ?IPv6:2601:647:4801:b314:ed44:c255:f14:72f9? ([2601:647:4801:b314:ed44:c255:f14:72f9]) by smtp.googlemail.com with ESMTPSA id td5sm20454299pbc.67.2015.09.15.01.24.25 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 15 Sep 2015 01:24:26 -0700 (PDT) To: Dmitry Stogov References: <031201d0ef28$abcec710$036c5530$@belski.net> <035401d0ef32$440361e0$cc0a25a0$@belski.net> <55F774F1.3040502@lerdorf.com> Cc: Anatol Belski , Anatol Belski , Kalle Sommer Nielsen , Xinchen Hui , Nikita Popov , Zeev Suraski , Andi Gutmans , PHP Internals X-Enigmail-Draft-Status: N1110 Message-ID: <55F7D5B6.8070407@lerdorf.com> Date: Tue, 15 Sep 2015 01:24:22 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="cumaipQt2K0IFRedawCvaGSuPXSCU0cPU" Subject: Re: [PHP-DEV] Re: [PHP-CVS] com php-src: Added an experemental ability to move PHP code pages (PHP TEXT segment) into HUGE pages. PHP should be configured and built with --enable-huge-code-pages, OS should be configured to provide huge pages. It's possibl From: rasmus@lerdorf.com (Rasmus Lerdorf) --cumaipQt2K0IFRedawCvaGSuPXSCU0cPU Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 09/14/2015 11:58 PM, Dmitry Stogov wrote: > On Tue, Sep 15, 2015 at 4:31 AM, Rasmus Lerdorf > wrote: > Redhat enables THP by default and has for a while, but I know lots = of > admins that disable this feature right away on production machines.= I > don't think it is default on Ubuntu, but at least they have hugepag= e > tools to make it easy to configure. And from a quick look at Debnia= n > (jessie) it wasn't obvious how to get hugepages working. I don't se= e a > package for hugeadm offhand. The kernel supports it, obviously, but= you > need to take some steps to configure them. >=20 >=20 > PHP prefers using regular Huge Pages and may fail back to THP > (Transparent Huge Pages). > So THP don't have to be enabled. > =20 >=20 >=20 > Which means we also need to spend a bit of time documenting how to > enable hugepages at the OS level for the various operating systems = to go > along with this feature. >=20 >=20 > Right. Manual OS configuration is required. See > https://wiki.debian.org/Hugepages#Enabling_HugeTlbPage > Steps (3) and (4) are optional. Yup. I did get it working here. Perhaps it would be a good idea to add a row to the phpinfo() OpCache section indicating whether huge pages are currently being used. It would make it easier to debug. I know you can check /proc/meminfo directly, but it isn't obvious what exactly is using the hugepages from that. -Rasmus --cumaipQt2K0IFRedawCvaGSuPXSCU0cPU Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iEYEARECAAYFAlX31bkACgkQlxayKTuqOuC0QgCfZTeuLk90DzfDtaHKJ29wILyJ Cc4An3H+fZvN96/rUwk+FCcZ3qpfDLC8 =LMoP -----END PGP SIGNATURE----- --cumaipQt2K0IFRedawCvaGSuPXSCU0cPU--