Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #10742
| References | <prNZp.31508$js7.12436@newsfe01.iad> <4e380d8f$0$29965$c3e8da3$5496439d@news.astraweb.com> |
|---|---|
| Date | 2011-08-02 17:06 +0100 |
| Subject | Re: range() vs xrange() Python2|3 issues for performance |
| From | Chris Angelico <rosuav@gmail.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.1784.1312301183.1164.python-list@python.org> (permalink) |
On Tue, Aug 2, 2011 at 3:45 PM, Steven D'Aprano <steve+comp.lang.python@pearwood.info> wrote: > (But don't make the mistake of doing what I did, which was to attempt to > produce range(290000000) in Python 2. After multiple *hours* of swapping, I > was finally able to kill the Python process and get control of my PC again. > Sigh.) > That is sad. (And, I am only slightly ashamed to admit it, quite funny.) But on the other hand, quite impressive that it didn't bomb anywhere! Whenever I'm about to do something really dangerous, I like to first open an SSH session from another computer - bash running inside there can usually kill any process fairly efficiently, without need for UI interaction. Failing that, good ol' Ctrl-Alt-F1 to get to a console is usually the next best, but sometimes logging in requires a lot of resources. This is actually one place where I'm really glad Python doesn't do much with multiple threads (for instance, it won't gc on another thread). A dual core CPU keeps everything happy! ChrisA
Back to comp.lang.python | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
range() vs xrange() Python2|3 issues for performance harrismh777 <harmar@member.fsf.org> - 2011-08-02 02:12 -0500
Re: range() vs xrange() Python2|3 issues for performance garabik-news-2005-05@kassiopeia.juls.savba.sk - 2011-08-02 07:51 +0000
Re: range() vs xrange() Python2|3 issues for performance Peter Otten <__peter__@web.de> - 2011-08-02 11:05 +0200
Re: range() vs xrange() Python2|3 issues for performance Stefan Behnel <stefan_ml@behnel.de> - 2011-08-02 11:20 +0200
Re: range() vs xrange() Python2|3 issues for performance Thomas Rachel <nutznetz-0c1b6768-bfa9-48d5-a470-7603bd3aa915@spamschutz.glglgl.de> - 2011-08-02 11:26 +0200
Re: range() vs xrange() Python2|3 issues for performance Chris Angelico <rosuav@gmail.com> - 2011-08-02 10:52 +0100
Re: range() vs xrange() Python2|3 issues for performance Chris Angelico <rosuav@gmail.com> - 2011-08-02 11:19 +0100
Re: range() vs xrange() Python2|3 issues for performance Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-08-03 00:45 +1000
Re: range() vs xrange() Python2|3 issues for performance Chris Angelico <rosuav@gmail.com> - 2011-08-02 17:06 +0100
Re: range() vs xrange() Python2|3 issues for performance Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-08-04 13:01 +1000
Re: range() vs xrange() Python2|3 issues for performance Chris Angelico <rosuav@gmail.com> - 2011-08-04 07:59 +0100
Re: range() vs xrange() Python2|3 issues for performance Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-08-04 19:56 +1000
csiph-web