John did more work on his PHP extensions. I find research into performance tuning and benchmarking fascinating. By using the C version of one of his PHP functions John gained a 75% increase in speed! Excellent!
John, can you try both PHP code and C code with PHP Accelerator or some other opcode caching tool? I guess the accelerator won’t affect performance of the C extension, but it may work well on your PHP loops. (but I doubt anywhere near the 75% you experienced with C!)
John benchmarked a C PHP extension versus native PHP code and discovered the speed-up wasn’t that great and I have to agree, not worth the restrictions not coding in PHP provides.
At work, we’ve thought of moving code into a C extension lots of times but this proves it’s not worth it. If you use a PHP Accelerator/cache then it’ll make even less sense!
This is one weblog entry I’m posting around the office for general consumption.
I really have to actively look for more PHP development websites. Here’s another: PHP Developer
Here’s a review of the upcoming PHP5. *Loads* of new stuff and it’s going to practically be a whole new language to learn. I can’t wait to start working with the new OO features it’ll have. It should make implementing patterns much easier. I wonder what effect it will have on the “home grown” self-taught PHP industry that’s out there? Those that will learn, will stick with it. The others? They’ll spend their time maintaining their PHP4 applications!
revjim.net: feedParser – An RSS parser in PHP.
feedParser was created due to the lack of a good, flexable, classed based RSS feed parser for PHP. It has been built as a class and currently handles RSS 0.91, RSS 0.92, RSS 0.93, RSS 1.0, and RSS 2.0 feeds. For channels it grabs the title, description, link, and creator. For items it grabs the title, description, link, and date. It also provides a form of the date converted into the local timezone to facilitate cronological sorting of items. The dates are provided in UNIX timestamp format for easy manipulation by other PHP functions.