A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2013-February/123985.html below:

[Python-Dev] Usage of += on strings in loops in stdlib

[Python-Dev] Usage of += on strings in loops in stdlib [Python-Dev] Usage of += on strings in loops in stdlibAntoine Pitrou solipsis at pitrou.net
Tue Feb 12 22:32:49 CET 2013
On Tue, 12 Feb 2013 13:32:50 -0800
"fwierzbicki at gmail.com" <fwierzbicki at gmail.com> wrote:
> On Tue, Feb 12, 2013 at 1:03 PM, Maciej Fijalkowski <fijall at gmail.com> wrote:
> > Hi
> >
> > We recently encountered a performance issue in stdlib for pypy. It
> > turned out that someone commited a performance "fix" that uses += for
> > strings instead of "".join() that was there before.
> >
> > Now this hurts pypy (we can mitigate it to some degree though) and
> > possible Jython and IronPython too.
> Just to confirm Jython does not have optimizations for += String and
> will do much better with the idiomatic "".join().

For the record, io.StringIO should be quite fast in 3.3.
(except for the method call overhead that Guido is complaining
about :-))

Regards

Antoine.


More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4