Python can use all the memory allocated to it. The OS allocates memory and usually has restrictions on each process, but there are commands to control these restrictions. (for example, "ulimit" on unix). But then most OSs use virtual memory, so the OS and its processes can use more virtual memory than the available physical memory. Thus, it is possible that the python program uses more physical memory. But the OS virtual memory system controls which pages are in physical memory and which pages are unloaded to disk. Thus, you can โuseโ 64 GB of memory, but only a fraction of the most recently used pages are actually in physical memory at any time. And some of this physical memory will contain parts of the operating system that work often, such as virtual memory allocation functions. In addition: the memory allocated for the process is shared and allocated differently (for example, heap and stack space). Thus, you may have a shortage of memory for one, while in memory there is still a lot of unused memory. So it depends on what you mean by โuse,โ and also (as another published one said) โhow much work you are willing to do.โ You can probably get 64 GB, but you are unlikely to be able to โuseโ all of the physical memory unless you are using the embedded system in which you are working as part of the OS.
source share