Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:74361 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 73039 invoked from network); 19 May 2014 13:31:20 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 May 2014 13:31:20 -0000 Authentication-Results: pb1.pair.com header.from=dmitry@zend.com; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=dmitry@zend.com; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain zend.com from 209.85.220.174 cause and error) X-PHP-List-Original-Sender: dmitry@zend.com X-Host-Fingerprint: 209.85.220.174 mail-vc0-f174.google.com Received: from [209.85.220.174] ([209.85.220.174:42607] helo=mail-vc0-f174.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id F4/12-55232-6A70A735 for ; Mon, 19 May 2014 09:31:19 -0400 Received: by mail-vc0-f174.google.com with SMTP id lh14so9445015vcb.19 for ; Mon, 19 May 2014 06:31:15 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=tYP7EtnKHqeZgb1AX1otewkXGOTcjhFK3CDYXzOs/qs=; b=do7Tclv1l1AvHpskdIK67Eqfsf9u9NIh0ETVs59XlEHJZ1+L2cjPNLKzWYyxn3SYYG cYqwY1grmtEb/WFidNGbDLJFKsBFZj0OzrHceipYJSo8DfgvINlWt9QZ7OD6Ew9VzBt/ YSvyThF+AqNwyrcn14WA0oXqG/6aJ71pcFMBtUrJvcM+5DaivMe5hUTvlqd41+UUnEzI PSZWTi4XT4vyInimyVOceKAeqYA1tCk8A1uZ0j4oYdzq8oJMn+77EAmj0g7/6VbzRFci fSLo1b88EvDuKqLVrcJ+etpvC/5peN+3dNXHmuOjmfLlF6S+rNEY9/Ti1MMU5DKAiHSn LV5g== X-Gm-Message-State: ALoCoQnUVr6Yei/Sh2f7uEuegng1Pvpb7cvYtKJscQZN2n9MbOUPfACuN7KX7Pu3P6d1JEeWTpxT9Sv5sJ+eQzhQ19jiNEP+CxM+y5oh92scCnGJp/WItT/HuF6CB6YoPgrQiqOTHlf6 MIME-Version: 1.0 X-Received: by 10.52.185.72 with SMTP id fa8mr12392160vdc.12.1400506275735; Mon, 19 May 2014 06:31:15 -0700 (PDT) Received: by 10.52.111.71 with HTTP; Mon, 19 May 2014 06:31:15 -0700 (PDT) In-Reply-To: <1400502071.2870.68.camel@guybrush> References: <4ED7146272E04A47B986ED49E771E347BBDA6AAA06@Ikarus.ameusgmbh.intern> <537333BF.7070106@lsces.co.uk> <5373C674.9030402@lsces.co.uk> <9fb17c9f5735c8323ff4940b452e2631.squirrel@webmail.klapt.com> <7478565334450718793@unknownmsgid> <1400502071.2870.68.camel@guybrush> Date: Mon, 19 May 2014 17:31:15 +0400 Message-ID: To: Pierre Joye , PHP internals Cc: Zeev Suraski , Nikita Popov , Stas Malyshev Content-Type: multipart/alternative; boundary=bcaec548a66d12428804f9c0c7f7 Subject: Re: [PHP-DEV] [VOTE] [RFC] 64 bit platform improvements for string length and integer From: dmitry@zend.com (Dmitry Stogov) --bcaec548a66d12428804f9c0c7f7 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable We had a long discussion with Pierre on IRC and probably come to some agreement. However, we always talk as a blind with a deaf, so I can't be completely sure :) We agreed to make 64-bit IS_LONG and 64-bit string length on all 64-bit systems, but don't change other core data structures (as Nikita suggested). The main idea of the changes on top of phpng may be seen at https://gist.github.com/dstogov/07fcbb60b1b585bcd290 I checked the patch on 64-bit Linux. The memory consumption grows, but no so dramatic. On wordpress home page without opcache the peak_memory_usage() showed 11043920 bytes insead of 10959456, that mean ~0.8% that we probably can afford. Note that the original patch on the same test showed ~8% memory consumption increase on master. To integrate the patch into phpng we have to re-check and re-change every place where zend_long, zend_ulong and string length are involved. Pierre, if you agree with this proposal just change RFC accordingly, and most people won't object. I'm not sure if we need zend_ulong -> zend_int_t, IS_LONG -> IS_INT, size_t -> zend_size_t renaming in thousand places. In my opinion this work is useless but I won't object against patch just because of names. I would suggest just 3 option for voting - "no", "yes with old names", "yes with new names". Thanks. Dmitry. =E2=80=8B --bcaec548a66d12428804f9c0c7f7--