Performance and Memory Considerations
All Python objects minimally include an integer reference count, a descriptor defining the type, and the representation of the actual data. Table 3.12 shows the approximate memory requirements of various built-in objects based on the C implementation of Python 2.0 running on a 32-bit machine. The precise values may vary slightly according to the implementation of the interpreter and machine architecture. (For instance, the memory requirements may double on a 64-bit machine.) Although you may never need to think about memory utilization, Python is used in a variety of high-performance and memory-critical applications ranging from supercomputing to mobile computing. The memory footprint of the built-in types ...
Get Python Essential Reference, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.