Marketing of D - article topic ideas?
Eric Poggel
dnewsgroup at yage3d.net
Fri Jun 4 07:54:36 PDT 2010
On 6/3/2010 9:34 PM, Adam Ruppe wrote:
> I recently rewrote a huge PHP application in D2. It isn't a completely
> fair comparison, since the PHP was written by, well to be polite, PHP
> "programmers", but the results were pretty astounding.
>
> 90% reduction in lines of code [!], 200% improvement in speed under
> heavy load (only 50% improvement under light load, still good, but not
> as good), and the code is actually maintainable! Also, the original
> took about a year for the first team to write. My D rewrite took 6
> weeks. Oh yeah, and the PHP is riddled with security holes. Not so
> much with the D.
>
> The best part about the speed is that it is just running as plain old
> CGI and my code does a lot of inefficient looping through XML. I could
> probably double the speed again by improving that.
>
>
> I might be able to write this into an article, but what I've done so
> far is just showed it off to other coders in some private messages on
> forums. A complication in publically showing it off is it is closed
> source though. The speed advantage isn't apparent until the code
> actually does something; PHP is much faster for hello world, but gets
> spanked when it comes to the actual work.
I've spent years in both D and PHP, and most of my php code is a little
shorter than what the equivalent would be in D, mostly due to an
enormous standard library. Now D is much better designed and much
faster, but most php programs are trash because the language attracts so
many noobs. I've spent a lot of time rewriting PHP apps in PHP that
ended up being 10% of the length of the original.
I prefer D to PHP, but writing a web app in D would take me much longer
due to the lack of web-oriented libraries. However, the speedup you got
with D is a good angle to push.
More information about the Digitalmars-d
mailing list