The idea of Cache.cpp was to track resources in memory. But now we are able to place them in a purgeable memory and also we would like to mmap them on the disk. So we need to track sizes for all those cases separately to clean up the code.
Created attachment 65976 [details] Proposed patch v1.0