Seems like we're not keeping enough information. Perhaps we could have
something like "streaming rank" at the mapping level and use that as a
hint to prioritize evictions or possibly where to insert in the LRU.
Throw new mappings at the streaming end of the rank list and whenever
they fault behind the r/w pointer, swap them upwards in the list.
If you're playing an MP3, it starts out at the streaming end of the
list and starts dropping pages at the first sign of pressure. Since
this really is streaming, no problem.
Now run Mozilla, which starts out behind the MP3, seeks around
randomly paging in code (which looks like fault behind), says "um,
excused me", and bumps ahead of the MP3..
Let Mozilla idle, start OpenOffice, which bumps in front of the MP3,
and if it hits more pressure, bumps in front of the idling Mozilla as
well.
Then updatedb starts, reads a ton of files in a streaming fashion, but
none of those streaming file mappings push above the idling apps.
-- "Love the dolphins," she advised him. "Write by W.A.S.T.E.." - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/