Re: [PHP-DEV] Undefined variables undefined order

2015-05-11 Thread Matt Wilmas
Hi! - Original Message - From: "Stanislav Malyshev" Sent: Monday, May 11, 2015 Hi! argument. I'd like to propose making the order of evaluation defined by splitting this into separate statements: What is the purpose of this? I.e. why is it important that these notices would be prod

Re: [PHP-DEV] Array dereferencing of scalars

2015-06-09 Thread Matt Wilmas
Hi all, - Original Message - From: "Yasuo Ohgaki" Sent: Tuesday, June 09, 2015 Hi all, On Tue, Jun 9, 2015 at 6:21 AM, Stanislav Malyshev wrote: > Would throwing a notice or a warning on array deferencing scalars > be acceptable for PHP 7.0, or does this need an RFC? I think this d

Re: [PHP-DEV] Array dereferencing of scalars

2015-06-09 Thread Matt Wilmas
Hi all, - Original Message - From: "Christoph Becker" Sent: Tuesday, June 09, 2015 Yasuo Ohgaki wrote: I fully agree that current behavior could be used meaningful ways. However, NULL $v = NULL; $v[0][1][2][3][4][5][6][7][8][9]; // NULL this code is semantically wrong and I wou

Re: [PHP-DEV] Undefined variables undefined order

2015-06-09 Thread Matt Wilmas
Hi all, - Original Message - From: "Sara Golemon" Sent: Monday, May 11, 2015 On Mon, May 11, 2015 at 5:12 PM, Matt Wilmas wrote: - Original Message - From: "Stanislav Malyshev" Sent: Monday, May 11, 2015 argument. I'd like to propose making the or

Re: [PHP-DEV] Undefined variables undefined order

2015-06-10 Thread Matt Wilmas
Hi Sara, - Original Message - From: "Sara Golemon" Sent: Wednesday, June 10, 2015 On Tue, Jun 9, 2015 at 6:05 AM, Matt Wilmas wrote: Hah, looks like this just changed last week after barely 3 weeks. :-P I didn't verify, just noticed the code change: http://git.php.net

Re: [PHP-DEV] Undefined variables undefined order

2015-06-10 Thread Matt Wilmas
Hi Dmitry, - Original Message - From: "Dmitry Stogov" Sent: Wednesday, June 10, 2015 Hi Sara, https://gist.github.com/dstogov/6a90601872b538d2ddd6 I see no problems committing this (running tests now). Cool. :-) Just FYI, I noticed you didn't update ZEND_BOOL_XOR, at least... Tha

[PHP-DEV] Re: [PHP-CVS] com php-src: Make CALL VM with FP and IP in global registers not to return anything from opcode handlers. Set OPLINE to NULL to terminate VM loop instead. This saves 1 CPU inst

2015-06-16 Thread Matt Wilmas
Hi Dmitry, - Original Message - From: "Dmitry Stogov" Sent: Tuesday, June 16, 2015 Commit:48ed660cdf6fe94ac2cd8eac217ea97340766e75 Author:Dmitry Stogov Tue, 16 Jun 2015 14:11:16 +0300 Parents: 3180b8e100285e5bd9088e9981608dfd14f6ff27 Branches: master Link: http://

Re: [PHP-DEV] Move to Fast ZPP?

2015-06-24 Thread Matt Wilmas
Hi Dmitry, all, - Original Message - From: "Dmitry Stogov" Sent: Wednesday, June 24, 2015 We should NOT use it everywhere. It'll lead to code bloat. Thanks. Dmitry. On Wed, Jun 24, 2015 at 12:21 PM, Ferenc Kovacs wrote: On Wed, Jun 24, 2015 at 3:42 AM, Yasuo Ohgaki wrote: > Hi all

Re: [PHP-DEV] Move to Fast ZPP?

2015-06-26 Thread Matt Wilmas
Hi Dmitry, all, - Original Message - From: "Dmitry Stogov" Sent: Thursday, June 25, 2015 On Wed, Jun 24, 2015 at 1:35 PM, Matt Wilmas wrote: Hi Dmitry, all, - Original Message - From: "Dmitry Stogov" Sent: Wednesday, June 24, 2015 We should NOT use

Re: [PHP-DEV] Move to Fast ZPP?

2015-06-26 Thread Matt Wilmas
Hi Levi, - Original Message - From: "Levi Morrison" Sent: Wednesday, June 24, 2015 On Wed, Jun 24, 2015 at 3:21 AM, Ferenc Kovacs wrote: On Wed, Jun 24, 2015 at 3:42 AM, Yasuo Ohgaki wrote: Hi all, I'm wondering the state of Fast ZPP. https://wiki.php.net/rfc/fast_zpp Last year's

Re: [PHP-DEV] Headsup: PHP7 feature freeze

2015-07-06 Thread Matt Wilmas
Hello RMs, all! - Original Message - From: "Kalle Sommer Nielsen" Sent: Thursday, June 25, 2015 Howdy This is a quick heads up that we plan to have the next release of 7.0.0 be Beta 1, this marks a feature freeze and from there on, we will switch focus on to stabilization, regressions

Re: [PHP-DEV] Move to Fast ZPP?

2015-07-07 Thread Matt Wilmas
Hi again Dmitry, all, - Original Message - From: "Dmitry Stogov" Sent: Monday, June 29, 2015 On Sat, Jun 27, 2015 at 12:36 AM, Matt Wilmas wrote: Hi Dmitry, all, [...] Yeah, I knew how the traditional ZPP worked, just wondered about any certain "problem area.&quo

Re: [PHP-DEV] Headsup: PHP7 feature freeze

2015-07-07 Thread Matt Wilmas
Hi Anatol, - Original Message - From: "Anatol Belski" Sent: Monday, July 07, 2015 Hi Matt, -Original Message----- From: Matt Wilmas [mailto:[email protected]] Sent: Tuesday, July 7, 2015 4:10 AM To: Internals; Kalle Sommer Nielsen Cc: Anatoliy Belsky; Dmitry Stog

Re: [PHP-DEV] Thoughts on C version supported for PHP-Next

2015-07-08 Thread Matt Wilmas
Hi all, - Original Message - From: "Levi Morrison" Sent: Sunday, May 10, 2015 Again, this is a C11 feature. It is supported by clang, gcc and MSVC. To clarify this a bit: they permit anonymous unions in C89 and C99 code (meaning you do not need to pass flags like -std=c11 to enable it

Re: [PHP-DEV] Thoughts on C version supported for PHP-Next

2015-07-08 Thread Matt Wilmas
Hi Kalle, - Original Message - From: "Kalle Sommer Nielsen" Sent: Wednesday, July 08, 2015 Hi Matt 2015-07-08 17:00 GMT+02:00 Matt Wilmas : Hi all, - Original Message - From: "Levi Morrison" Sent: Sunday, May 10, 2015 Again, this is a C11 feature. It i

Re: [PHP-DEV] Move to Fast ZPP?

2015-07-22 Thread Matt Wilmas
Hi again Dmitry, all, Hopefully the final update on this, before all is revealed... :-) - Original Message - From: "Matt Wilmas" Sent: Tuesday, July 07, 2015 Hi again Dmitry, all, [...] Just an update... I didn't abandon this; quite the opposite! I thought I

Re: [PHP-DEV] Introduction and some opcache SSE related stuff

2015-07-30 Thread Matt Wilmas
Hi Dmitry, Bogdan, - Original Message - From: "Dmitry Stogov" Sent: Thursday, July 30, 2015 Hi Bogdan, On Wed, Jul 29, 2015 at 5:22 PM, Andone, Bogdan wrote: Hi Guys, My name is Bogdan Andone and I work for Intel in the area of SW performance analysis and optimizations. We would li

[PHP-DEV] Re: [PHP-CVS] com php-src: avoid unnecessary scoping: main/php_variables.c

2015-08-02 Thread Matt Wilmas
Hi Anatol, - Original Message - From: "Anatol Belski" Sent: Friday, July 31, 2015 Commit:3a66a23679487f4feda699ada109ab2b675e9474 Author:Anatol Belski Fri, 31 Jul 2015 14:02:03 +0200 Parents: 7be9e69eafdb1828d09daecde5cd39112db3f581 Branches: master Link: http://g

Re: [PHP-DEV] Thoughts on C version supported for PHP-Next

2015-08-02 Thread Matt Wilmas
Hi all, - Original Message - From: "Matt Wilmas" Sent: Wednesday, July 08, 2015 Hi Kalle, - Original Message - From: "Kalle Sommer Nielsen" Sent: Wednesday, July 08, 2015 Hi Matt 2015-07-08 17:00 GMT+02:00 Matt Wilmas : Hi all, - Original Messa

Re: [PHP-DEV] Move to Fast ZPP?

2015-08-05 Thread Matt Wilmas
Hi Dmitry, - Original Message - From: "Dmitry Stogov" Sent: Monday, August 03, 2015 Hi Matt, On Wed, Jul 22, 2015 at 11:16 PM, Matt Wilmas wrote: Hi again Dmitry, all, Hopefully the final update on this, before all is revealed... :-) [...] I tried to rush and finish

Re: [PHP-DEV] Move to Fast ZPP?

2015-08-05 Thread Matt Wilmas
Hi Levi, - Original Message - From: "Levi Morrison" Sent: Thursday, August 06, 2015 Don't know about Windows now... Visual Studio 2008 and 2012 (not much difference) are NOT optimizing away the code (other times it was GCC with issues). :-/ Not sure why. Of course they don't support

Re: [PHP-DEV] Move to Fast ZPP?

2015-08-06 Thread Matt Wilmas
Hi Pierre, - Original Message - From: "Pierre Joye" Sent: Thursday, August 06, 2015 On Aug 6, 2015 1:49 PM, "Matt Wilmas" wrote: Hi Levi, - Original Message - From: "Levi Morrison" Sent: Thursday, August 06, 2015 Don't know about Win

[PHP-DEV] Parameter parsing for zval type?

2015-08-11 Thread Matt Wilmas
Hi Dmitry, all, Help me understand this. :-) It's been more puzzling to me recently since just coming to the part of optimizing traditional ZPP (sharing part with FAST_ZPP...). With the FAST_ZPP inline macros, why is there a Z_PARAM_ZVAL and Z_PARAM_ZVAL_DEREF? It seems the zpp 'z' specifi

Re: [PHP-DEV] Parameter parsing for zval type?

2015-08-11 Thread Matt Wilmas
Hi again, - Original Message - From: "Matt Wilmas" Sent: Tuesday, August 11, 2015 Hi Dmitry, all, Help me understand this. :-) It's been more puzzling to me recently since just coming to the part of optimizing traditional ZPP (sharing part with FAST_ZPP...). Wi

Re: [PHP-DEV] Parameter parsing for zval type?

2015-08-11 Thread Matt Wilmas
Hi Dmitry, - Original Message - From: "Dmitry Stogov" Sent: Tuesday, August 11, 2015 Hi Matt, On Tue, Aug 11, 2015 at 9:00 PM, Matt Wilmas wrote: Hi again, - Original Message ----- From: "Matt Wilmas" Sent: Tuesday, August 11, 2015 Hi Dmitry, all, Hel

Re: [PHP-DEV] Parameter parsing for zval type?

2015-08-12 Thread Matt Wilmas
Hi Nikita, - Original Message - From: "Nikita Popov" Sent: Tuesday, August 11, 2015 On Tue, Aug 11, 2015 at 10:10 PM, Matt Wilmas wrote: [...] Look at e.g. is_numeric() or strpos() (needle). Plain zval param parsing, so NO ZVAL_DEREF() occurs (FAST_ZPP or traditional)

Re: [PHP-DEV] Parameter parsing for zval type?

2015-08-12 Thread Matt Wilmas
H Dmitry, - Original Message - From: "Dmitry Stogov" Sent: Tuesday, August 11, 2015 On Tue, Aug 11, 2015 at 11:10 PM, Matt Wilmas wrote: [...] Look at e.g. is_numeric() or strpos() (needle). Plain zval param parsing, so NO ZVAL_DEREF() occurs (FAST_ZPP or traditional)

[PHP-DEV] Marking error, etc. functions as cold?

2015-08-17 Thread Matt Wilmas
Hi Dmitry, all, Has it been considered to use __attribute__((cold)) on, for example, error-type functions? I happened to notice this part about it in the GCC docs [1] a couple days ago: "The paths leading to calls of cold functions within code are marked as unlikely by the branch prediction m

[PHP-DEV] Re: [PHP-CVS] com php-src: Fix possible overflow in openssl_pbkdf2: ext/openssl/openssl.c

2015-08-18 Thread Matt Wilmas
Hi Anatol, Jakub, - Original Message - From: "Jakub Zelenka" Sent: Tuesday, August 18, 2015 On Tue, Aug 18, 2015 at 8:23 PM, Anatol Belski wrote: Hi Jakub, > -Original Message- > From: Jakub Zelenka [mailto:[email protected]] > Sent: Tuesday, August 18, 2015 8:47 PM > To: php-..

[PHP-DEV] Re: [PHP-CVS] com php-src: Fix possible overflow in openssl_pbkdf2: ext/openssl/openssl.c

2015-08-18 Thread Matt Wilmas
Hi Jakub, - Original Message - From: "Jakub Zelenka" Sent: Tuesday, August 18, 2015 On Tue, Aug 18, 2015 at 9:48 PM, Matt Wilmas wrote: Hi Anatol, Jakub, [...] The checks with zend_long vars like key_length and iterations are impossible when ZEND_LONG_MAX == INT_MAX (m

[PHP-DEV] Re: [PHP-CVS] com php-src: Fix possible overflow in openssl_pbkdf2: ext/openssl/openssl.c

2015-08-18 Thread Matt Wilmas
Hi Anatol, - Original Message - From: "Anatol Belski" Sent: Tuesday, August 18, 2015 Hi Matt, > [...] > > The checks with zend_long vars like key_length and iterations are > impossible > when ZEND_LONG_MAX == INT_MAX (most if not all 32-bit, I guess). So > those > checks should alr

Re: [PHP-DEV] Re: [PHP-CVS] com php-src: Fix possible overflow in openssl_pbkdf2: ext/openssl/openssl.c

2015-08-18 Thread Matt Wilmas
Hi Anatol, - Original Message - From: "Anatol Belski" Sent: Tuesday, August 18, 2015 Ok, got the idea now. But sizeof(size_t) is always > sizeof(zend_long). And for signed, still it is simpler and safer to just use an #ifdef around. No, == like I said. :-) OK, just saw your correcti

Re: [PHP-DEV] Re: Marking error, etc. functions as cold?

2015-08-19 Thread Matt Wilmas
D_NORETRUN_ALIAS" instead of NORETURN. [1] https://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html Thanks. Dmitry. Thanks, Matt On Mon, Aug 17, 2015 at 1:26 PM, Matt Wilmas wrote: Hi Dmitry, all, Has it been considered to use __attribute__((cold)) on, for example, error-type functions?

Re: [PHP-DEV] Move to Fast ZPP?

2015-08-21 Thread Matt Wilmas
ith the fastest/smallest parameter parsing we could imagine, across all of PHP! I guess that means start looking for it next week...? :-) I may just send a patch sooner without even writing up an explanation about parts first like I planned. More below... - Original Message ----- Fro

Re: [PHP-DEV] Re: Bug #44654: wired syntax error for #

2008-04-07 Thread Matt Wilmas
Hi Xuefer, all, Yeah, the re2c patch did change (or add?) a bit for handling the "#" character (though I haven't investigated your example...). However, I wanted to report that I just started playing with some changes to the scanner (re2c), and am seeing weird (or "wired" re: subject :-P) stuff t

[PHP-DEV] [PATCH] Scanner fixes and tweaks

2008-04-08 Thread Matt Wilmas
Hi all, First, I just realized while going through the scanner code after the re2c changes that there's a bug with heredoc handling (from my code changes last year, oops) on something like: <

Re: [PHP-DEV] [PATCH] Scanner fixes and tweaks

2008-04-10 Thread Matt Wilmas
Hi Scott, I noticed that Nuno changed yyless() to be like flex after your commit (not in HEAD? I considered that, but figured you guys wanted it different :-)), but now the heredoc end part is wrong again (hehe), and I see Tony reported the broken tests... Attached patch puts it back to pre-re2c

[PHP-DEV] CVS Account Request: mattwil

2008-04-11 Thread Matt Wilmas
Contributing miscellaneous patches like I've been sending to the internals list in the past. :-) -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DEV] CVS Account Request: mattwil

2008-04-11 Thread Matt Wilmas
Hi Marcus, Thanks! Well, I don't have a specific extension to work on, just been random stuff that I found to change in core PHP (so ZendEngine2/ and different areas of php-src/), as anyone who's seen my different patches could probably see. :-) So I don't know... I figured things wouldn't be a

[PHP-DEV] DVAL_TO_LVAL() change, different behavior

2008-04-12 Thread Matt Wilmas
Hi all, I have some code where I need to grab the last 1-3 bytes from numbers (bitwise AND), and a few weeks ago I was looking to see how I'd handle the possible, though unlikely, scenario of numbers > LONG_MAX (still only care about those last bytes). But I realized it worked just fine with the

Re: [PHP-DEV] [PATCH] Scanner fixes and tweaks

2008-04-17 Thread Matt Wilmas
Hello guys, - Original Message - From: "Philip Olson" Sent: Thursday, April 10, 2008 > On 10 Apr 2008, at 09:48, Marcus Boerger wrote: > > Hello Matt, > > > > Thursday, April 10, 2008, 3:50:41 PM, you wrote: > > > >> Hi Scott, > >> [...] > >> BTW, maybe you could change the name in that 5

Re: [PHP-DEV] [PATCH] Scanner fixes and tweaks

2008-04-17 Thread Matt Wilmas
Thanks Tony! - Original Message - From: "Antony Dovgal" Sent: Thursday, April 17, 2008 > On 17.04.2008 14:54, Matt Wilmas wrote: > > Well, now that I have a php.net account, and 5.2.6 will be released, can > > someone change my name? :-) Unless I'm

[PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-04-18 Thread Matt Wilmas
Hi all, I changed things so that the many "built-in" constants (CONST_PERSISTENT ones) will be replaced at compile-time, saving the FETCH_CONSTANT opcode, if these changes are usable. This was added for TRUE/FALSE/NULL 2 years ago, but seems like it can be done for "lots" of others too. Since th

[PHP-DEV] [PATCH] More array filling optimizations

2008-04-25 Thread Matt Wilmas
Hi all, Expanding on the idea of passing a size other than 0 to zend_hash_init(), when possible, which was done awhile ago in a few areas (to save resize/rehash operations), I finally added an "array_init_size()" that can be used instead of array_init(), likewise, when a size is known. As an exam

Re: [PHP-DEV] [PATCH] More array filling optimizations

2008-04-25 Thread Matt Wilmas
Hi Andrey, - Original Message - From: "Andrey Hristov" Sent: Friday, April 25, 2008 > Hi, > [...] > heh, this optimisitations was one of the pluses mysqlnd had over > mysqli/libmysql. I am using the following macro: > > #if PHP_MAJOR_VERSION < 6 > #define mysqlnd_array_init(arg, field_c

Re: [PHP-DEV] Failed Win32 builds log file.

2008-04-28 Thread Matt Wilmas
Hi Richard, all, Yeah, was thinking the same thing about the logs. :-) Don't know if you tried to compile yourself, but the failure is from Derick's date additions Friday (http://news.php.net/php.cvs/49738): php_date.obj : error LNK2019: unresolved external symbol _timelib_diff referenced in fun

Re: [PHP-DEV] Failed Win32 builds log file.

2008-04-28 Thread Matt Wilmas
Hi Derick, - Original Message - From: "Derick Rethans" Sent: Monday, April 28, 2008 > On Mon, 28 Apr 2008, Matt Wilmas wrote: > > > Yeah, was thinking the same thing about the logs. :-) Don't know if you > > tried to compile yourself, but the failur

Re: [PHP-DEV] [PATCH] More array filling optimizations

2008-04-30 Thread Matt Wilmas
Hi again Dmitry, Hmm, if a -1 size was passed, I thought it would just make a huge array size (bad, obviously), but the tests would still work. (Or I guess it might exhaust memory_limit.) Anyway, the code for checking the size (length variable) in array_splice() is copied from php_splice(), so m

Re: [PHP-DEV] [PATCH] More array filling optimizations

2008-04-30 Thread Matt Wilmas
tself) and showed small > slowdown on bench.php (the slowdown may be not the result of the patch > but result of worse code-locality caused by the patch). > > I think we shouldn't make PHP more complicated without significant > result, so I suggest not to apply array_init_size_

[PHP-DEV] [PATCH] Some string changes/optimizations

2008-05-05 Thread Matt Wilmas
Hi all, This patch... Saves one opcode per interpolated string by moving what was the first ADD_STRING/ADD_VAR op into INIT_STRING; changes the ADD_[CHAR|STRING|VAR] op types from (TMP, ) to (, UNUSED), since that seems to make more sense (see ADD_ARRAY_ELEMENT) and simplifies things a bit, and s

Re: [PHP-DEV] [PATCH] Some string changes/optimizations

2008-05-06 Thread Matt Wilmas
Hi Rasmus, Sorry about the patch format. :-/ It's been updated to correct that, as well as fix a test failure that Felipe mentioned. And as Felipe said, the invalid opcode is because the patch doesn't include the zend_vm_execute.h changes, and zend_vm_gen.php needs to be run first. I also shoul

Re: [PHP-DEV] [PATCH] Some string changes/optimizations

2008-05-06 Thread Matt Wilmas
Hi Felipe, all, The patches have been updated to fix the failing nowdoc_015.phpt test. http://realplain.com/php/string_optimizations.diff http://realplain.com/php/string_optimizations_5_3.diff The problem was that after removing the ST_START_NOWDOC stuff, the NOWDOC_CHARS pattern wasn't matching

Re: [PHP-DEV] [PATCH] Some string changes/optimizations

2008-05-07 Thread Matt Wilmas
Hi Felipe, I don't know. :-/ That's a pretty big discrepancy... (Did you do a complete recompile before and after the patch?) With your test, timed with microtime() on my old Win2k system (release/non-debug), I get 1.56s before and 1.54s after -- about what I'd expect after doing my own random

[PHP-DEV] Couple Windows build fixes

2008-05-07 Thread Matt Wilmas
Hi, One patch for 5.3 and one for HEAD, where they're not synched with the other. 5.3's math changes the other day missed one change to the php_* function (snaps are failing). And HEAD's Win Makefile still contains references to flex.skl after the re2c change, which causes an error for me, thoug

Re: [PHP-DEV] Couple Windows build fixes

2008-05-08 Thread Matt Wilmas
x27;ve been given access to everything from > >> Day One, we all know he's brilliant :) > >> > >> - Steph > >> > >> - Original Message - From: "Hannes Magnusson" > >> <[EMAIL PROTECTED]> > >> To: "Matt

Re: [PHP-DEV] Couple Windows build fixes

2008-05-08 Thread Matt Wilmas
Hi Rasmus, - Original Message - From: "Rasmus Lerdorf" Sent: Thursday, May 08, 2008 > Matt Wilmas wrote: > > BTW, if I had karma for Zend stuff, I guess > > I could fix Bugs #44681 and #44830 > > You already have Zend karma. I was going by your CVSROOT

Re: [PHP-DEV] Re: PHP6 Win32 Build Issues

2008-06-01 Thread Matt Wilmas
Hi Marco, - Original Message - From: "Marco" Sent: Sunday, June 01, 2008 > I've done some quick checks and I think part of the problem is in the > following commit > > http://cvs.php.net/viewvc.cgi/php-src/sapi/apache2handler/config.w32?r1=1.4&r2=1.5 > > AFAICS mod_php5.c has been renamed

[PHP-DEV] re2c issues? (Was Re: [ZEND-ENGINE-CVS] cvs: ZendEngine2(PHP_5_3) / zend_language_scanner.l)

2008-07-08 Thread Matt Wilmas
Hi Nuno, all, I didn't test it, but yeah that should fix the # problem. :-) BTW, I also had other ideas about checking for , etc. tags in the inline HTML scanning part, so the largest chunk of HTML is always grabbed (I'll send the patch in the future; didn't modify anything yet, and it's not rela

[PHP-DEV] Closures - Windows build failure

2008-07-09 Thread Matt Wilmas
Hi all, Noticed that PHP 6 snapshots aren't working and got these errors when trying to build: zend_API.obj : error LNK2019: unresolved external symbol _zend_get_closure referenced in function _zend_is_callable_ex zend_execute.obj : error LNK2001: unresolved external symbol _zend_get_closure zend

Re: [PHP-DEV] Closures - Windows build failure

2008-07-09 Thread Matt Wilmas
Hi Scott, Ah thanks, so simple! :-O I should've investigated first since I figured it was probably a Windows-specific file, and not a missing #include, etc. - Original Message - From: "Scott MacVicar" Sent: Wednesday, July 09, 2008 > Sorted now, the new file was missing from the build

Re: [PHP-DEV] [PATCH] Some string changes/optimizations

2008-07-10 Thread Matt Wilmas
m/php/string_optimizations_5_3.diff Remember to regenerate the scanner/parser with re2c/bison and run zend_vm_gen.php! I also included possible NEWS updates in the 5.3 patch this time. :-P Thanks for any feedback, Matt - Original Message - From: "Matt Wilmas" Sent: Monday

Re: [PHP-DEV] Optimization for ..._MULTIPLY_LONG on more systems

2008-07-17 Thread Matt Wilmas
ndows assembly version of these 2 things, where I left the comments? There is for zend_mm_[high|low]_bit(), but they're very simple... http://realplain.com/php/multiply_long.diff http://realplain.com/php/multiply_long_5_3.diff - Matt ----- Original Message - From: "Matt Wilmas"

[PHP-DEV] [PATCH] New functions: array_replace[_recursive]

2008-07-22 Thread Matt Wilmas
Hi all, Adding these two array functions has been on the TODO for a while, and my original patch has been collecting dust for almost 2 years. :-) I just updated the patches now after some small changes (the original version for 5.2 is currently linked on the wiki). A brief description, if I reme

Re: [PHP-DEV] Re: [PATCH] New functions: array_replace[_recursive]

2008-07-23 Thread Matt Wilmas
Hi Christian, - Original Message - From: "Christian Schneider" Sent: Wednesday, July 23, 2008 > Matt Wilmas wrote: > > array_replace() is like the + operator applied to arrays, except that it > > WILL overwrite ("replace") existing entries. >

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-07-23 Thread Matt Wilmas
m/php/const_ct_optimization.diff http://realplain.com/php/const_ct_optimization_5_3.diff Thanks, Matt - Original Message - From: "Matt Wilmas" Sent: Friday, April 18, 2008 > Hi all, > > I changed things so that the many "built-in" constants (CONST_PERSISTENT &

Re: [PHP-DEV] 5.3 feature freeze rapidly approaching

2008-07-23 Thread Matt Wilmas
Hi Lukas, all, Don't know if my two Zend-related patches can be used, or how much time there is to add them (after alpha 1...?). Waiting to hear about "No runtime fetching of built-in global constants." And the second, "Some string changes/optimizations," I'm sure it's fine to update the syntax

Re: [PHP-DEV] DVAL_TO_LVAL() change, different behavior

2008-07-23 Thread Matt Wilmas
From: "Matt Wilmas" Sent: Saturday, April 12, 2008 > Hi all, > > I have some code where I need to grab the last 1-3 bytes from numbers > (bitwise AND), and a few weeks ago I was looking to see how I'd handle the > possible, though unlikely, scenario of numbers > LONG_M

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-07-24 Thread Matt Wilmas
r simpler/smaller if you're concerned about the constants patch adding a few rules. ;-D [1] http://marc.info/?l=php-internals&m=121630449331340&w=2 [2] http://marc.info/?l=php-internals&m=121569400218314&w=2 > Thanks. Dmitry. > Thanks, Matt > Matt Wilmas wrote: >

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-07-24 Thread Matt Wilmas
s did you test it? > > I'll try to take a deeper look into string optimization patch today or > tomorrow. > > Thanks. Dmitry. Thanks, Matt > Matt Wilmas wrote: > > Hi Dmitry, > > > > - Original Message - > > From: "Dmitry Stogov" >

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-07-24 Thread Matt Wilmas
s optimization with > ZEND_COMPILE_NO_CONSTANT_SUBSTITUTION > > Any objections? > > Thanks. Dmitry. > > Matt Wilmas wrote: > > Hi Dmitry, > > > > - Original Message - > > From: "Dmitry Stogov" > > Sent: Thursday, July 24, 2008 > > > >

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-07-25 Thread Matt Wilmas
Hi Dmitry, I saw that you commited this patch, with the addition of only replacing persistent constants (just mentioning for others on the list). The attached patches have a few tweaks: The main thing I noticed is that if "something" creates a persistent, case-INsensitive constant (any of those

Re: [PHP-DEV] New optimization idea; was: No runtime fetching of built-in global constants

2008-07-27 Thread Matt Wilmas
k into the problem. In case you find a > simple solution we will able to do it in php-5.3. > > Most PHP hosters and large sites use FastCGI with opcode caches (it is > also the primary way for MS Windows users), so this optimization is > really important. > > [see below] Yes,

[PHP-DEV] [PATCH] Constant expr folding (again), and other things

2008-07-30 Thread Matt Wilmas
Hi Dmitry, all, I was going to send this patch as a companion one to go with the compile-time constant substitution change (Nuno sent a message about this [1] last Sep. with a patch [2]), BUT I also realized that some different, inconsistent behavior is possible because of that change. First, the

[PHP-DEV] Re: [PATCH] Constant expr folding (again), and other things

2008-07-31 Thread Matt Wilmas
ot;signed_expr_tweaks") was for. Actually, I wrote the above right after getting your message, but didn't send it then, because I had only been thinking about the parser, and thought of a more proper fix in zend_compile.c for the behavior difference (and something else). I will send the f

Re: [PHP-DEV] Re: [PATCH] Constant expr folding (again), and other things

2008-07-31 Thread Matt Wilmas
Hi Dmitry, - Original Message - From: "Dmitry Stogov" Sent: Thursday, July 31, 2008 > Hi Matt, > > For now I would like to disable "-CONST" constant expression which > started to work after your patch. Yes, that's what my new fix will do -- it's coming in just a minute, and it also corre

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-07-31 Thread Matt Wilmas
Hi Dmitry, For the behavior change that I mentioned in the other thread, with this code: function foo() { static $a = -PHP_INT_MAX; } Which could work sometimes, and sometimes not (if in a namespace or ZEND_COMPILE_NO_CONSTANT_SUBSTITUTION is set). I changed things so that there is no subst

Re: [PHP-DEV] [PATCH] New functions: array_replace[_recursive]

2008-07-31 Thread Matt Wilmas
Hi Johannes, - Original Message - From: "Johannes Schlüter" Sent: Thursday, July 31, 2008 > Matt, > > On Tue, 2008-07-22 at 10:52 -0500, Matt Wilmas wrote: > > Adding these two array functions has been on the TODO for a while, > > The patch can quite ea

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-07-31 Thread Matt Wilmas
- From: "Dmitry Stogov" Sent: Thursday, July 31, 2008 > Thanks Matt. I committed near the same patch. > It's not so optimal, but little bit more clear. > > Thanks. Dmitry. > > Matt Wilmas wrote: > > Hi Dmitry, > > > > For the behavior change that I

Re: [PHP-DEV] [PATCH] New functions: array_replace[_recursive]

2008-08-28 Thread Matt Wilmas
Hi Johannes, - Original Message - From: "Johannes Schlüter" Sent: Thursday, July 31, 2008 > Matt, > > On Thu, 2008-07-31 at 20:06 +0200, Johannes Schlüter wrote: > > On Thu, 2008-07-31 at 11:48 -0500, Matt Wilmas wrote: > > > Ugh, I hate that referen

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-08-28 Thread Matt Wilmas
lplain.com/php/ct_const_fixes.diff http://realplain.com/php/ct_const_fixes_5_3.diff Thanks, Matt - Original Message - From: "Dmitry Stogov" Sent: Thursday, July 31, 2008 > Hi Matt, > > Now I know. :) > Anyway, I don't think this optimization will work often.

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-08-29 Thread Matt Wilmas
. > Please take a look. > > Thanks. Dmitry. > > Matt Wilmas wrote: > > Hi Dmitry, > > > > Well, it's been awhile since Alpha 1 :-), so I wanted to finally resend this > > before Alpha 2! I agree that the additional optimization probably wouldn't >

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-08-29 Thread Matt Wilmas
x27;t work sometimes, sometimes not. My previous message (first part): http://marc.info/?l=php-internals&m=121750618525882&w=2 > Thanks. Dmitry. > > Matt Wilmas wrote: > > Hi Dmitry, > > > > Yeah, that looks good too, and should work the same way. :

Re: [PHP-DEV] Re: [PATCH] Constant expr folding (again), and other things

2008-08-29 Thread Matt Wilmas
Hi again Dmitry, - Original Message - From: "Dmitry Stogov" Sent: Thursday, July 31, 2008 > Hi Matt, > > For now I would like to disable "-CONST" constant expression which > started to work after your patch. > > Later we are able to implement the complete constant expressions support. On

Re: [PHP-DEV] [PATCH] No runtime fetching of built-in global constants

2008-08-29 Thread Matt Wilmas
Hi Stas, - Original Message - From: "Stanislav Malyshev" Sent: Friday, August 29, 2008 > Hi! > > > Yeah, it's to make sure something like -CONST in ZEND_CT context doesn't > > work sometimes, sometimes not. My previous message (first part): > > http://marc.info/?l=php-internals&m=12175

Re: [PHP-DEV] Re: [PATCH] Constant expr folding (again), and other things

2008-08-31 Thread Matt Wilmas
Hi Stas, Dmitry, I forgot to reply to Stas' message yesterday, sorry... But, there is no change in behavior here either as far as I know. For the code Stas quoted, with static vars (if that's what was being referred to), there's definitely not been a change (though its parser code was tweaked a

[PHP-DEV] Bug #45068: SIZEOF_LONG, etc. when cross compiling

2008-09-01 Thread Matt Wilmas
Hi all, SIZEOF_LONG is getting #define'd as 8 when compiling for 32-bit on 64-bit (is it possible to do the opposite, maybe switched there too?). It also makes MAX_LENGTH_OF_LONG be set wrong, causing the problem in Bug #45068. There are some other places in the code where incorrect code may be u

Re: [PHP-DEV] casting doubles to ints

2009-02-04 Thread Matt Wilmas
Hi Iain, (Yes, this subject has me sending a message to the list again instead of lurking, and I should be back with some internals stuff again soon, hehe. :^)) - Original Message - From: "Iain Lewis" Sent: Wednesday, February 04, 2009 Subject: [PHP-DEV] casting doubles to ints > Hello a

Re: [PHP-DEV] 5.3 todos

2009-02-13 Thread Matt Wilmas
Hi Lukas! Just wanted to send a quick message about some things I'll try to do. :-) Guess I'm a little late to "return," heh -- and I'm finishing a new system build now and have to migrate stuff over :-/, but I'll get to these PHP things soon as I can, on whatever system... - Original Messag

Re: [PHP-DEV] Re: Bug #46701

2009-02-18 Thread Matt Wilmas
Hi Zoe, all, - Original Message - From: "zoe" Sent: Wednesday, February 18, 2009 > Moriyoshi Koizumi wrote: > > Please don't even think of backporting. This will definitely break a > > lot of things, and this kind of thing must not be done in a minor > > release. > > > > > --snip-- > > >>

Re: [PHP-DEV] 5.3 items

2009-03-09 Thread Matt Wilmas
Hi Brian, - Original Message - From: "shire" Sent: Monday, March 09, 2009 Hey Lukas, Just a heads up that I should have a fix for this soonish, just running some more tests to make sure everything works as expected (I assume nobody else has started work on this): 9. tokenizer mis

Re: [PHP-DEV] 5.3 items

2009-03-09 Thread Matt Wilmas
Hi Brian, - Original Message - From: "shire" Sent: Monday, March 09, 2009 Hey Matt, Matt Wilmas wrote: 9. tokenizer misses last single-line comment (http://bugs.php.net/bug.php?id=46817) I was going to take care of that one, as I mentioned in a previous message, though

[PHP-DEV] [PATCH] double to long conversion change

2009-03-14 Thread Matt Wilmas
Hi all, Since noticing and reporting last year [1] different behavior when casting out-of-range doubles to int after the DVAL_TO_LVAL() macro was updated, I've wondered how to get the behavior I observed, and thought could be relied on (that was wrong to think, since it was un- or implementati

[PHP-DEV] [PATCH] Remove nTableSize from HashTable?

2009-03-15 Thread Matt Wilmas
Hi Dmitry, all, Just a quick one... ;^) Is there much, if any, advantage to removing the HashTable member nTableSize? It's just nTableMask + 1, so it can be derived easily in the couple places that need it... Figured it can't hurt to make things smaller, and it only adds a couple addition o

[PHP-DEV] [PATCH] Extend bitwise and modulus operators on 32-bit platforms

2009-03-16 Thread Matt Wilmas
Hi all, I changed the bitwise and modulus operator functions to [try to] make them more consistent with behavior on 64-bit platforms. By accepting double operands and, if necessary, returning a double, their usable range is greatly extended without running into overflow issues, etc. (Of cour

[PHP-DEV] [PATCH] Bug #45877: LONG_MAX/MIN array key as string/int

2009-03-17 Thread Matt Wilmas
Hi all, Assuming there are no objections, I'll commit this fix in a few hours... Besides the bug report(s), I had also found awhile ago that currently an array key can be LONG_MAX or LONG_MIN as a string and/or integer because of a check in ZEND_HANDLE_NUMERIC() (I assume to avoid a slow errno

[PHP-DEV] Re: [PATCH] Bug #45877: LONG_MAX/MIN array key as string/int

2009-03-18 Thread Matt Wilmas
code is a bit slower for keys that aren't fully numeric, e.g. "123a" [1] http://news.php.net/php.zend-engine.cvs/7465 Dmitry. - Matt Matt Wilmas wrote: Hi all, Assuming there are no objections, I'll commit this fix in a few hours... Besides the bug report(s), I had also

[PHP-DEV] Re: [PATCH] Bug #45877: LONG_MAX/MIN array key as string/int

2009-03-18 Thread Matt Wilmas
this patch -- the behavior would be exactly the same, just better, more optimized code. (I'll do that as soon as I can, but it wouldn't affect you looking into it. I plan to eliminate the big macro I added, FYI.) I'd imagine they could be discussed, etc. past the RC... Than

[PHP-DEV] Re: [PATCH] Bug #45877: LONG_MAX/MIN array key as string/int

2009-03-18 Thread Matt Wilmas
Hi again Dmitry, Just wanted to say that I think I can make your code a bit smaller after looking at it closer. Don't quite have enough time to modify and verify it now, but I'll be back later (around the usual time) to let you know either way. :-) - Matt - Original Message - Fro

[PHP-DEV] Re: [PATCH] Bug #45877: LONG_MAX/MIN array key as string/int

2009-03-19 Thread Matt Wilmas
Hi Dmitry, - Original Message - From: "Dmitry Stogov" Sent: Thursday, March 19, 2009 Hi Matt, Matt Wilmas wrote: Hi again Dmitry, Just wanted to say that I think I can make your code a bit smaller after looking at it closer. It would be great, but keep in mind that perf

Re: [PHP-DEV] Re: [PATCH] Bug #45877: LONG_MAX/MIN array key as string/int

2009-03-19 Thread Matt Wilmas
Hi Rasmus, - Original Message - From: "Rasmus Lerdorf" Sent: Thursday, March 19, 2009 So, what is the final conclusion on this one? Are we at a combination of Matt's and Dmitry's patches here? I think we definitely need to fix this even in the 5.2 branch and get it back to 5.1.x and e

  1   2   3   >