Firefox has gotten very good at safely handling allocation failures, so instead of crashing it keeps your memory snugly at 100% full and renders your system entirely unusable until the kernel figures out (2-20 minutes later) that it really cannot allocate a single kilobyte anymore and it decides to run the OOM killer
but also
it's not cheap? Why should everyone upgrade to 32GB RAM to multitask when all the text, images, and data structures in open programs take only a few megabytes each? How can you not get hung up about the senseless exploding memory usage
It's better not to use 2.4G RAM in the first place. Imagine LinkedIn isn't so hostile to users and instead actually cares about user experience.
MADV_FREE (since Linux 4.5)
The application no longer requires the pages in the range
specified by addr and size. The kernel can thus free these
pages, but the freeing could be delayed until memory
pressure occurs.
and MADV_DONTNEED
Do not expect access in the near future. (For the time
being, the application is finished with the given range, so
the kernel can free resources associated with it.)
After a successful MADV_DONTNEED operation, the semantics
of memory access in the specified region are changed:
subsequent accesses of pages in the range will succeed, but
will result in either repopulating the memory contents from
the up-to-date contents of the underlying mapped file (for
shared file mappings, shared anonymous mappings, and shmem-
based techniques such as System V shared memory segments)
or zero-fill-on-demand pages for anonymous private
mappings.
Does Chrome use it, though?The other day Safari was using over 50GB with only a few tabs open.
Maybe we should also acknowledge that some companies particularly have no compassion for users (and their desires or needs) and see them as hurdles in their way to take money from users.
The websites are jam packed with trackers and ads. I am utterly concerned about Chrome’s memory usage because it’s passively allowing this all to occur.
How about you let me blacklist sites that are using too much memory automatically, all that means is that those website owners FUCKING HATE THE REST OF US.
Any solution to this epic fucking problem would be wonderful.
March is "MARCHintosh" month for retro Macintosh computing, for fun I wrote a networked chat client. It has some creature comfort features like loading in chat history from the server, mentions, user info, background notifications, multiple session. It runs in 128 kilobytes of RAM.
Automatic garbage collection memory management was a mistake. The memory leaks we had when people forgot to free memory was nothing compares to the memory leaks we have now when people don't even consider what memory is.