[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Perl, Python, Ruby, PHP, C, C++, Lua, tcl, javascript and Java comparison
- From: Roberto Ierusalimschy <roberto@...>
- Date: Mon, 15 Jul 2013 17:00:34 -0300
> what i found interesting is that Python performed so well, since the
> code is similar. I guess that somewhere in the many megabytes of
> special-cases in the language core there's something that manages to
> optimize bad code.
The key to the difference is x += y versus x = x + y (assuming '+' for
the concatenate operator) and the internals implied by that, not any
smart optimization. The same languages that are fast in this particular
code are slow in any code that involves a lot of simple string assignments.
-- Roberto
- References:
- Perl, Python, Ruby, PHP, C, C++, Lua, tcl, javascript and Java comparison, Daniel Bolgheroni
- Re: Perl, Python, Ruby, PHP, C, C++, Lua, tcl, javascript and Java comparison, Roberto Ierusalimschy
- Re: Perl, Python, Ruby, PHP, C, C++, Lua, tcl, javascript and Java comparison, kamicc olo
- Re: Perl, Python, Ruby, PHP, C, C++, Lua, tcl, javascript and Java comparison, Roberto Ierusalimschy
- Re: Perl, Python, Ruby, PHP, C, C++, Lua, tcl, javascript and Java comparison, Javier Guerra Giraldez
- Prev by Date:
Re: stdout to buffer
- Next by Date:
Re: Perl, Python, Ruby, PHP, C, C++, Lua, tcl, javascript and Java comparison
- Previous by thread:
Re: Perl, Python, Ruby, PHP, C, C++, Lua, tcl, javascript and Java comparison
- Next by thread:
Re: Perl, Python, Ruby, PHP, C, C++, Lua, tcl, javascript and Java comparison
- Index(es):