Performance comparison again...

See here: http://blog.curiasolutions.com/the-great-web-framework-shootout/#php

Yii is not that fast as it announced anymore. What do you think?

I don’t care what other bloggers say. Everybody can be a blogger nowadays and say what s/he wants. Do your own tests and see for yourself. I am more than happy with Yii and won’t switch to kohana even if it loads my page 50ms faster :lol:

I think speed is important but it is only one small consideration of many. Things like security, development speed (RAD), structure/flexibility, upgrade ability, platform versions, support, community and a lot more also play a role.

If a framework I was using was consistently shown to be much, much slower than any other framework I would investigate but other than that, reasonable performance and ticks all the other boxes I will use it.

Although I agree that speed is not the most important variable when deciding what framework to use, I think it would be a good idea to update the "performance of yii" section with benchmarks using the latest version of the framework, since the information there is kinda outdated.

Quoting the top of the page:

I agree with NaX, speed of the framework is not the only variable to consider.

I’ve developed in several frameworks and I have to conclude that each framework has it pros and cons,… e.g. CI is very fast, but it is like having anything, you have to do almost everything manually, so your development time increases dramatically, conclusion, it is not a good idea for serious (large) developments. Kohana solves much of CI issues, but still misses some Yii cool features… and so on…

Depending on your priority you choose one or another framework. I think Yii is one of the most “well-balanced” frameworks… I accept that it is not perfect, but we are on the way :)

Nevertheless, Yii is still VERY fast compared to most of the "other" frameworks.

When I think about it the type of benchmarks I would like to see are Yii version comparisons. Showing how Yii’s performance changes between releases.

EG:

Benchmark of PHP Branches 3.0 through 5.3-CVS

http://sebastian-bergmann.de/archives/745-Benchmark-of-PHP-Branches-3.0-through-5.3-CVS.html

Benchmarking PHP performance 5.0 to 5.3

http://www.synet.sk/php/en/220-php-performance-benchmark

Now I know with a framework like Yii things are different compared to something like PHP. As more feature or abstraction are added the slower it could become, but if we had a version comparison benchmark at least we would know where to look. I think the demo’s would be good test cases.

We should always keep an eye on the competition but focus on competing with ourselves more.

Just my 2 cents.

When we chose to work with Yii, the resulting app’s speed has been a welcome plus. But it’s not been our primary metric. We went for Yii because of the pace at which we could develop our apps. But NaX is right: Having an eye on how the speed of the framework develops among different version might be important to detect possible regressions early.

Those benchmarks really need to be updated. I just ran one on the “Hello World”-demo on a virtualized CentOS 6.2 with 2GB RAM. I easily passed 1,100 RPS without any optimizations (i.e. the PHP and Apache configs are largely the same as the package defaults). And that’s with APC disabled.

I sincerely hope that the performance of Yii will be improved in 2.0 - especially AR.

If we look at the benchmarks in the first post, that’s where Yii disappoints.

I chose Yii for performance reasons - because CakePHP was too slow.

That would require some serious profiling to figure out what the bottleneck(s) in the current AR implementation is/are. Does xhprof still work with PHP 5.4?

Hm. I just had a closer look at the test setup. SQLite has been used as RDBMS, so this might actualy be a deficiency in either the PDO::sqlite driver or Yii’s SQLite schema. Hard to tell …