3 ms·
Or if you do all your work directly on the file in the RAM disk, you have to deal with filesystem overhead constantly. Not so. Take a look at the Linux kernel
by colanderman 12y ago
Or if you do all your work directly on the file in the RAM disk, you have to deal with filesystem overhead constantly.
Not so. Take a look at the Linux kernel implementation of memory-mapped ramdisk files. There is no "filesystem overhead". Zero. The kernel pretty much sets up the page mapping and then is hands-off.
Even if your memory mapping is backed by a file on a block device, the only overhead is occasional paging to disk. This happens on the order of SECONDS… not "constantly"!
- sp332 12y agoThat's assuming you already have a file and know how big it should be. Or does it take the whole space for one file, and every program on the computer shares the space?
- colanderman 12y agoFiles can be both sparsely and dynamically allocated.