Re: PHP console script vs C/C++/C#

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Apr 18, 2008 at 11:25 AM, Nick Stinemates <nick@xxxxxxxxxxxxxx>
wrote:

> I don't think there was a single place where I said PHP was faster than
> C, nor did I imply it.
>

> > Depends. Shitty algorithms are shitty, regardless of language
> > implementation.

implies that the same algorithm in different languages will not perform
differently.  thats innacurate.  the same algorithm w/o external
dependencies, such as db calls, or calls to remote systems will run faster
in java / c / c++ and others than it will in php.

The point I was making is simple, if you have a shitty algorithm (which
> is the case for our op) expect shitty performance.
>

right, and i agree with that, but its a different point.  if op moved the
same shitty algorithm to c it would be faster.


> There's no doubt you will gain performance moving to C, but, if properly
> designed, you have a performance that is acceptable, then why go to that
> level?


obviously, it makes perfect sense to clean up php code (esp if its written
poorly) prior to porting to a low-level language.  i am in total agreement
with you there.  however, the point i was making was, if the same crap was
ported to a compiled language, it would be faster (barring external calls
that for example go over the network [which even then it would likely still
be a little faster]).

-nathan

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux