"Bug" with PHP and fasterharderstronger.diff
Brought to you by:
dstogov
Thies Arntzen has written a patch for php 4.3-cvs
that increases interpretation of php-code by
average by 100% !!! (it is NO cache! - it optimizes
Zend Engine 1).
The patch can be downloaded here :
http://www.edwardbear.org/thieso/
After patching php, turck mmcache does no longer
work.
It would be very cool if you could have a look at that.
Maybe it is a job of 5 minutes to update turck
mmcache maybe it is impossible. If have no idea.
But both optimizations would rock php!
Logged In: NO
The same page says it works with APC 2.0 when
one applies this patch:
http://www.edwardbear.org/apc.diff
So it should be realizable for turck mmcache, too!
Logged In: NO
It works now!
You have to remove some case-constants since
the patch changes two constant-types in a way
that they are in fact just one!
encoder.c: line 667: comment out "case FLAG_IS_BC:"
loader.c: line 290: comment out "case FLAG_IS_BC:"
Maybe one has to change some other things, too
to make it more smoothly...
Logged In: NO
Correction:
My "workaround" does only work with *VERY*
simple scripts.
phpma & co. do CRASH!
Logged In: YES
user_id=124551
Very cool patch. Now we have threaded-code PHP emulator!!!
I hope this patch will be accepted by PHP group. I will look
into it.
Logged In: NO
Hi,
I have seen that you commented out
"case FLAG_IS_BC:" in CVS.
Does it work with the patch or was the
fact that you commented-out the "case FLAG_IS_BC:"
just for another issue?
When it works: What else did you change that it
works?
Logged In: YES
user_id=124551
I comented "case FLAG_IS_BC:" for compatibility with this
patch, but I didn't make MMCache compatible. It will break
the compatibility with original PHP. I hope this patch will be
included in hte next PHP release and then I will make
MMCache to be comaptible.
Logged In: NO
Hi,
I found out that :
the patch won't be included in php 4.xx :-(
It will be included in php 5.xx
Derick wrote why:
Because all of those changes are highly experimental.
PHP 4.3. is a stable release, and we do not want to
make it unstable due to these patches.
Derick
Logged In: YES
user_id=124551
It is a good decision.
Logged In: NO
Do you know where the SECRET is of the APC Patch
that APC 2.0 works with the speedup-patch?
The APC-2.0 patch to work with fasterharderstronger.diff
can be found here:
http://www.edwardbear.org/apc.diff
What else has essentially changed beside the
remove of case FLAG_IS_BC: in this patch?
Have you any idea?
Thank you!
Logged In: YES
user_id=124551
Yes I know.
To do MMCache compatible with this patch it is necessury:
1. reimplement zend_hash's buckets handling. Original ZE
allocates key string with the bucket, but patched version
uses fixed size bucket with pointer to key string.
2. disable "reassign registers" optimization. Patched ZE uses
register number for elemenate variable address lookup, so
MMCache can't assign one register for several variables.
3. ??? May be somthing else.
Logged In: NO
Thank you very much!
You seem to be a very amazing programmer!