Open
Description
We could have the concept of purgeable kernel memory that we can purge at any moment if we get out of memory. This way we could have a PurgeableOnce
which will destroy and free its inner storage on OOM and that way we could get by using a lot less memory. Using this mechanism we could update all of the CACHES to use PurgeableOnce
rather then just Once
to store the inner data. This method can also be applied to userland memory mappings but we will prioritise purgeable kernel memory first since there are a lot of stuff that kernel caches and can be freed on OOM.
:^) big brain 🧠 :^)