mitry Stogov
Cc: internals@lists.php.net; 'Andrei Zmievski'; 'Andi Gutmans'
Subject: Re: [PHP-DEV] Giving Globals the CV treatment [WAS:
Runtime JIT Proposals]
At first I don't understand why you are trying to
deallocate variable.
+ if (CG(active_op_a
mon [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, January 23, 2007 12:34 PM
> To: Dmitry Stogov
> Cc: internals@lists.php.net; 'Andrei Zmievski'; 'Andi Gutmans'
> Subject: Re: [PHP-DEV] Giving Globals the CV treatment [WAS:
> Runtime JIT Proposals]
>
>
&
At first I don't understand why you are trying to deallocate variable.
+ if (CG(active_op_array)->T == (parent->u.var - 1)) {
+ CG(active_op_array)->T--;
+ }
Isn't the same variable reused as result of ZEND_FETCH_DIM?
Yeah, I hastily recanted th
y 21, 2007 12:57 AM
> To: Dmitry Stogov
> Cc: internals@lists.php.net; 'Andrei Zmievski'; 'Andi Gutmans'
> Subject: Re: [PHP-DEV] Giving Globals the CV treatment [WAS:
> Runtime JIT Proposals]
>
>
> One last thought on global CVs... How's thi
+ /* Give temp var back if it was the most recently assigned only
*/
+ if (CG(active_op_array)->T == (parent->u.var - 1)) {
+ CG(active_op_array)->T--;
+ }
Ergh, ignore that section It doesn't belong there (obviously)...
I pas
Given they way-below margin of error difference I have to wonder if
perhaps the added "parse" times would more then offset any (if any)
benefits gained. Given that most users still do not use opcode caches
this is something to consider for performance tweaks where the
difference is >1%.
One last thought on global CVs... How's this for fixing the loophole of:
ZEND_BEGIN_SILENCE
ZEND_FETCH_R $0 '_POST' (global)
ZEND_FETCH_DIM_R $1 $0 'foo'
ZEND_END_SILENCE
I know it seems like a pretty minor gain, but (A) using @$_GET['foo']
isn't an uncommon practice, and (B) pushing this all
ject: Re: [PHP-DEV] Giving Globals the CV treatment [WAS:
> Runtime JIT Proposals]
>
>
> > Could you also run Zend/bench.php to check that patch
> doesn't slowdown
> > local fetches. I think the patch can be commited into HEAD
> (not into
> > PHP_5_2),
On 18-Jan-07, at 9:12 PM, Sara Golemon wrote:
Or do you mean that they turn:
ZEND_FETCH_R $0 'GLOBALS' (global)
ZEND_FETCH_DIM_R $1 $0 'foo'
Into:
ZEND_FETCH_R $1 'foo' (global)
Yup.
And:
ZEND_BEGIN_SILENCE
ZEND_FETCH_R $0 'foo' (local)
ZEND_FETCH_DIM_R $1 $0 'bar'
ZEND_END_SILENCE
Into:
Z
[EMAIL PROTECTED] wrote:
The optimizer already does most of those things, so I think things like
that are best left there rather then being done in the core.
How exactly does the (by "the" I presume you mean "your") optimizer
manage to turn $_POST['foo'] into a single CV based DIM fetch? The
The optimizer already does most of those things, so I think things
like that are best left there rather then being done in the core.
On 18-Jan-07, at 4:34 PM, Sara Golemon wrote:
Could you also run Zend/bench.php to check that patch doesn't
slowdown local
fetches.
I think the patch can be
Could you also run Zend/bench.php to check that patch doesn't slowdown local
fetches.
I think the patch can be commited into HEAD (not into PHP_5_2), but I would
prefer collect all performance patches and commit them into PHP_5_3 and HEAD
together.
without with
simple
Hi Sara,
> -Original Message-
> From: Sara Golemon [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, January 17, 2007 11:36 PM
> To: Dmitry Stogov
> Cc: internals@lists.php.net; Andrei Zmievski; Andi Gutmans
> Subject: Re: [PHP-DEV] Giving Globals the CV treatment [W
It is interesting and very clear patch.
Probably you idea can be extended to support regular globals too. I mean
$GLOBALS["name"].
>
GLOBALS is itself in the auto global registry, so these would
automatically get picked up too. Oh, no, you probably mean have that
entire expression boil down t
e-
> From: Sara Golemon [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, January 16, 2007 1:58 AM
> To: Sara Golemon
> Cc: internals@lists.php.net
> Subject: [PHP-DEV] Giving Globals the CV treatment [WAS:
> Runtime JIT Proposals]
>
>
> > The solution I'm tempted
The solution I'm tempted to pursue for this is to back up yet another
step and make autoglobals be CVs by extending the zend_compiled_variable
struct to contain a flag indicating how the var should be fetched (the
determination for which happens during fetch_simple_var during the
compilation.
16 matches
Mail list logo