View Single Post
Posts: 376 | Thanked: 511 times | Joined on Aug 2009 @ Greece
#153
Originally Posted by zimon View Post
The problem is obvious for me, but I know I should prove it with memory prints comparing the same session and tabs and pages after fresh start and after few days of surfing. Also I could show how cache misses will increase over time with Firefox. I've actually sometimes done these observations but not in a scientific way yet.
I really can't blindly accept what the post says. A long time ago, in a version far far away, glibc started using mmap() on /dev/zero instead of brk() to allocate memory. This has the advantage that memory that is freed returns to the OS immediately and Linux is able to handle memory fragmentation better than Firefox itself (memory fragmentation on OS level is a very different thing). This means that there needs to be no free memory handling in any application, unless the app chooses to re-use its freed memory. But even in that case, fragmentation could be reduced by just freeing fragmented memory.

So, no. When judging languages leave the memory fragmentation out of the conversation and surely don't compare the memory handling of Java with the memory handling of Firefox. I'm 100% sure that the Llinux kernel can do much better than JVM since it has actual view of the physical ram and the actual page allocation.