As far as i know, the page size is 4k in OS memory management. It can be a advantage when the memory is too small. But the memory in our machine is big enough now, why the page size is still 4k? What is the limit for change it to be like 1M or bigger?
4KB is just default page size supported by many architectures.
However, some architectures support switching to use bigger page sizes. For example, i386 supports switching to huge pages mode with 2MB or 4MB page size, and x86_64 supports 2MB huge pages, and for some newer CPUs it can even support 1GB page size (large pages).
Many filesystems use block size that is exact page size or small multiplier of it (4KB-8KB or so). Also, many operating systems allocate memory only in whole pages. Allocating 2MB page on every memory allocation request would waste a lot of memory.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With