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/2008-December/084651.html below:

[Python-Dev] extremely slow exit for program having huge (45G) dict (python 2.5.2)

[Python-Dev] extremely slow exit for program having huge (45G) dict (python 2.5.2)Antoine Pitrou solipsis at pitrou.net
Wed Dec 31 01:40:02 CET 2008
Jesus Cea <jcea <at> jcea.es> writes:
> 
> Mike Coleman wrote:
> > I guess if ints are 12 bytes (per Beazley's book, but not sure if that
> > still holds), then that would correspond to a 1GB reduction.
> 
> Python 2.6.1 (r261:67515, Dec 11 2008, 20:28:07)
> [GCC 4.2.3] on sunos5
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import sys
> >>> sys.getsizeof(0)
> 12

On a 32-bit system, sure, but given Mike creates a 45 GB dict, he has a 64-bit
system, where ints are 24 bytes:

>>> sys.getsizeof(0)
24
>>> sys.getsizeof(100000)
24

cheers

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