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

2008-07-21 Thread Lukas Kahwe Smith
On 17.07.2008, at 16:20, Matt Wilmas wrote: Hi all, Replying to this OLD message about the ZEND_SIGNED_MULTIPLY_LONG() change... It's just a small thing, but it's been on the TODO for a while, so I attempted to correct the issue with my original patch that used "long long" type, which was

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

2008-07-17 Thread Matt Wilmas
Hi all, Replying to this OLD message about the ZEND_SIGNED_MULTIPLY_LONG() change... It's just a small thing, but it's been on the TODO for a while, so I attempted to correct the issue with my original patch that used "long long" type, which wasn't available on the older MSVC versions, etc. I cre

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

2006-11-10 Thread Nuno Lopes
> Did it not work for you as-is on Windows...? It did for me, since it seems > there's already a typedef for __int64 -> long long. I'd wondered the same, I think some VC versions on windows don't know "long long" but do know __int64, but I don't remember from the top of my head which versio

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

2006-11-09 Thread Matt Wilmas
Hi Andi, - Original Message - From: "Andi Gutmans" Sent: Wednesday, November 08, 2006 > Nice patch! Looks good to me... Any other thoughts? Since I don't have a *nix system to test on, I was wondering how my version compares to the assembly one. But I guess the latter is still fastest w

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

2006-11-09 Thread Matt Wilmas
- Original Message - From: "Stanislav Malyshev" Sent: Thursday, November 09, 2006 > > Did it not work for you as-is on Windows...? It did for me, since it seems > > there's already a typedef for __int64 -> long long. I'd wondered the same, > > I think some VC versions on windows don't kn

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

2006-11-09 Thread Stanislav Malyshev
Did it not work for you as-is on Windows...? It did for me, since it seems there's already a typedef for __int64 -> long long. I'd wondered the same, I think some VC versions on windows don't know "long long" but do know __int64, but I don't remember from the top of my head which version, but

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

2006-11-09 Thread Ilia Alshanetsky
Matt, Looks like a good patch to me. On 8-Nov-06, at 11:46 PM, Matt Wilmas wrote: Hi, Here's an additional ZEND_SIGNED_MULTIPLY_LONG() for platforms with 32-bit longs that don't use the assembly version (so all Windows systems at least?). On my Windows system, mul_function() is 40% faste

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

2006-11-09 Thread Nuno Lopes
Great patch! From my quick tests I got about 35% performance increase. Ah, it needs a little tweak to work on windows, as 'long long' is defined as __int64 (probably we could do a typedef once for all, as there are already many #ifdefs in the code because of this). Did it not work for you as-

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

2006-11-09 Thread Edin Kadribasic
Matt Wilmas wrote: > Hi Nuno, > > - Original Message - > From: "Nuno Lopes" > Sent: Thursday, November 09, 2006 > > > >> Great patch! From my quick tests I got about 35% performance increase. >> Ah, it needs a little tweak to work on windows, as 'long long' is defined >> > as > >

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

2006-11-09 Thread Matt Wilmas
Hi Nuno, - Original Message - From: "Nuno Lopes" Sent: Thursday, November 09, 2006 > Great patch! From my quick tests I got about 35% performance increase. > Ah, it needs a little tweak to work on windows, as 'long long' is defined as > __int64 (probably we could do a typedef once for al

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

2006-11-09 Thread Nuno Lopes
- Original Message - Nice patch! Looks good to me... Any other thoughts? -Original Message- From: Matt Wilmas [mailto:[EMAIL PROTECTED] Sent: Wednesday, November 08, 2006 8:47 PM To: internals@lists.php.net Subject: [PHP-DEV] Optimization for ..._MULTIPLY_LONG on more systems Hi,

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

2006-11-08 Thread Andi Gutmans
Nice patch! Looks good to me... Any other thoughts? > -Original Message- > From: Matt Wilmas [mailto:[EMAIL PROTECTED] > Sent: Wednesday, November 08, 2006 8:47 PM > To: internals@lists.php.net > Subject: [PHP-DEV] Optimization for ..._MULTIPLY_LONG on more systems >

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

2006-11-08 Thread Matt Wilmas
Hi, Here's an additional ZEND_SIGNED_MULTIPLY_LONG() for platforms with 32-bit longs that don't use the assembly version (so all Windows systems at least?). On my Windows system, mul_function() is 40% faster with this version (no overflow), which makes PHP's * operator 20% faster; with overflow m