Will 'free' return the memory Immediately to the OS ?

R

Robert Miles

I doubt that that is true, though. I'd suspect that 4 MB pages
take less than 100 times as long as 4 kB pages to evict and
reload, maybe much less.

I tried to find some measurements online to support this point,
but couldn't quickly find anything relevant.

I'd expect that to depend heavily on the rotation speed of the hard
drive. Eviction and reloading should each take at least an average
of half a rotation, plus however long it takes to read or write that
much data.

The fastest common speed for hard drives for home computers is
7200 RPM, although 10000 RPM is available but not common yet.

Some hard drives have memory caches to help with this if a read
request comes soon enough after a write request for the same data.

Also, SSD drives don't use a rotating disk - they only use a slower
interface to memory chips, and are therefore much faster than hard
drives.
 
S

Stephen Sprunk

I'd expect that to depend heavily on the rotation speed of the hard
drive. Eviction and reloading should each take at least an average
of half a rotation, plus however long it takes to read or write that
much data.

The fastest common speed for hard drives for home computers is
7200 RPM, although 10000 RPM is available but not common yet.

Some hard drives have memory caches to help with this if a read
request comes soon enough after a write request for the same data.

Also, SSD drives don't use a rotating disk - they only use a slower
interface to memory chips, and are therefore much faster than hard
drives.

AFAIK, 10,000rpm drives, 7,200rpm drives, caching drives, and SSD drives
were not available in the consumer x86 market at the time the i386 was
being designed, which is when 4kB/4MB page sizes were chosen.

And, if you study the x86 (and even x64) page table system, there's
really no good way to add an intermediate page size without basically
revamping the entire system--which means OS developers would have to
throw away all of the paging code and experience they've built up over
the last two and a half decades of x86 development.

S
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,754
Messages
2,569,527
Members
44,998
Latest member
MarissaEub

Latest Threads

Top