Messages in this thread |  | | Date | Wed, 26 May 1999 10:44:02 -0700 (PDT) | | From | Linus Torvalds <> | | Subject | Re: [PATCH] cache large files in the page cache |
| |
On Wed, 26 May 1999, Jakub Jelinek wrote: > > I have minor suggestion to the patch. Instead of using vm_index << > PAGE_SHIFT and page->key << PAGE_CACHE_SHIFT shifts either choose different > constant names for this shifting (VM_INDEX_SHIFT and PAGE_KEY_SHIFT) or hide > these shifts by some pretty macros (you'll need two for each for both > directions in that case - if you go the macro way, maybe it would be a good > idea to make vm_index and key type some structure with a single member like > mm_segment_t for more strict typechecking).
Indeed. An dI would suggest that the shift be limited to at most 9 anyway: right now I applied the part that disallows non-page-aligned offsets, but I think that we may in the future allow anonymous mappings again at finer granularity (somebody made a really good argument about wine for this).
Thinking that the VM mapping shift has to be the same as the page shift is not necessarily the right thing. With just 9 bits of shift, you still get large files - 41 bits of files on a 32-bit architecture, and by the time you want more you _really_ can say that you had better upgrade your CPU.
Linus
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
|  |