Hacker News new | past | comments | ask | show | jobs | submit login

I was under the impression that modern kernels and memory allocators are clever enough to not initialise memory pages that have been allocated but not used yet, is that not the case? So unless you calloc() or memset() your newly allocated memory, overallocation won't really affect actual memory usage?



That's right. The untouched memory won't be committed, i.e. put into physical memory or swap. But it will take up address space, which can be a problem -- on Windows Firefox is a 32-bit process and running out of address space tends to happen more often than running out of physical memory, ironically enough.


That reminds me (as I now have windows 8.1 on one of my machines again) - does anyone know if there is a roadmap/plan for official 64bit builds of ff on win64?


It's being actively worked on. https://wiki.mozilla.org/Firefox/win64 seems to be an up-to-date planning document.


i think you will find memset 0 after most calls to malloc in the firefox code.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: